Problem facing in Dynamic configuration in SAP PI 7.3

Hello,
I am doing dynamic configuration in sap pi 7.3. I am using the following UDF.
String devFileName="'a.vc'";
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
conf.put(FileName, devFilename);
I am using this UDF in message mapping and mapped this UDF in the message header.
I have selected the adapter specific message attribute in receiver communication channel also.
Still I am getting the folowing error.
MP: exception caught with cause com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.aii.adapter.file.configuration.DynamicConfigurationException: The Adapter Message Property 'FileName' was configured as mandatory element, but was not supplied in the XI Message header
Exception caught by adapter framework: The Adapter Message Property 'FileName' was configured as mandatory element, but was not supplied in the XI Message header
'Transmitting the message to endpoint using connection File_http://sap.com/xi/XI/System failed, due to: com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.aii.adapter.file.configuration.DynamicConfigurationException:  The Adapter Message Property 'FileName' was configured as mandatory element, but was not supplied in the XI Message header.
Please help me what to do.
Thanks & Regards,
Moumita

Hi, try this code:
String devFileName="a.vc";
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
conf.put(FileName, devFilename);
ASMA checkbox and respective parameter should be enabled in the required Adapter.
Best Regards

Similar Messages

  • Dynamic Configuration in SAP PI 7.3

    Hello,
    I am doing one file to file scenario in PI 7.3 (Java Stack only).
    There is one requirement i.e. The output file name will change according to Development, Quality and Production. Prefix will be added to the outputput file name according to Development, Quality & production.
    I am new in SAP PI . Please suggest me what to do for the above requirement.
    Thanks & Regards,
    Moumita

    Hi Moumita,
    Please find the details
    1) read the source directory and based on source directory name set the file name in dynamic configuration
    In sender communication channel select the ASMA parameter Directory and read the dynamic configuration as below
    String devFileName = "DEV_out.txt";
    String qaFileName = "QA_out.txt";
    String regFileName = "Reg_out.txt";
    String directory= "";
    DynamicConfiguration conf1 = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key1 = DynamicConfigurationKey.create( "http:/"+"/sap.com/xi/XI/System/File","Directory");
    directory= conf1.get(key1);
    If (directory.equals("DEV"))
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
    conf.put(FileName, devFileName);
    return "";
    else
    If (directory.equals("QA"))
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
    conf.put(FileName, qaFileName);
    return "";
    else
    If (directory.equals("Reg"))
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
    conf.put(FileName, regFileName);
    return "";
    2) read the system id and based on that set the file name in dynamic configuration.
    String System = System.getProperty("SAPSYSTEMNAME");
    String devFileName = "DEV_out.txt";
    String qaFileName = "QA_out.txt";
    String regFileName = "Reg_out.txt";
    If (System.equals("DEV"))
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
    conf.put(FileName, devFileName);
    return "";
    else
    If (System.equals("QA"))
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
    conf.put(FileName, qaFileName);
    return "";
    else
    If (System.equals("Reg"))
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransf
    ormationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
    conf.put(FileName, regFileName);
    return "";
    regards,
    Harish

  • Problem facing when changing configuration characterstic values in SO

    Hi Experts,
    I am facing a problem when i am chaging sales order configuration characterstic values they are updating perfectly. But when i am creating purchase order with reference to sales order then the sales order configuration currency characterstic values are picking as 0 which are already updated perfectly in sales order.
    I am using cl_cbase-> set_configuration method for to update the characterstic currency values.
                    cl_cbase->set_mark_for_saving after the above method
                    cl_cbase->save_and_free after the above method.
    Would request your suggestions if you have come across this situation.
    Advance Thanks
    Regards,
    Chandra.

    Hi,
    Can do it using Union All is prompt SQL and presentation variable in report.
    Refer : http://www.varanasisaichand.com/2010/01/editing-all-choices-in-dashboard.html
    Regards,
    Srikanth

  • Problems faced with VL10D transaction in sap

    Hi,
       I am using BADI to generate error message for VL10D transaction.The error message is generated properly.But it is exiting the transaction.The user wants that it should come back to the initial screen of the VL10D transaction.
       I have tried to do this with warning messages displayed as error message.But it is not working properly.The delivery is getting
    created with errors.
        Please help me out. <removed by moderator>
    Thanks and regards,
    Raka.
    Edited by: Thomas Zloch on Sep 28, 2011 1:06 PM

    Hi
    Combine your BADI as a warning message and with older userexits (see Note 198137 - VL10: Customer-specific enhancements / user exits). Use the include LV50R_VIEWG06 and set cf_subrc = 1 for the deliveries that you must not create because they hava an error.
    I hope this helps you
    Regards
    Eduardo

  • Problem "Unable to find resource" in SAP PI 7.0 Sp12

    Hi Experts - We are experiencing below problem in SAP PI 7.0 SP 12.
    Objects are available in the system and cache notifications are green. Even after multiple attemps messages are not processing.
    Is there any resolution action we can take? Details below.
    THanks, Mathias.
    <Trace level="1" type="B" name="CL_RD_PLSRV-ENTER_PLSRV">
    <Trace level="1" type="T">R E C E I V E R - D E T E R M I N A T I O N</Trace>
    <Trace level="1" type="T">Cache Content is up to date</Trace>
    <Trace level="2" type="T">Start without given receiver</Trace>
    <Trace level="2" type="T">Dynamic Receiver Determination via Mapping.</Trace>
    <Trace level="2" type="T">......attachment XI_Context not found</Trace>
    <Trace level="3" type="T">Object ID of Interface Mapping 721735504F3735BB885E49DD430ACFB0</Trace>
    <Trace level="3" type="T">Version ID of Interface Mapping 4E0CDFA06AAB11DBBE41EACA91374078</Trace>
    <Trace level="1" type="T">Interface Mapping http://eu.Company.com/SC/Mak/Pack/ProdRec/xi NAME_WMTORD_TO_SAP_BASIS_Receivers</Trace>
    <Trace level="3" type="T">Mapping Steps 1 JAVA com/sap/xi/tf/_NAME_WMTORD_TO_SAP_BASIS_Receivers_</Trace>
    <Trace level="3" type="T">Dynamic Configuration ( http://sap.com/xi/XI/System/IDoc SNDPOR SAPSXX ) ( http://sap.com/xi/XI/System/IDoc SNDPRN SXXCLNT010 ) ( http://sap.com/xi/XI/System/IDoc SNDPRT LS ) ( http://sap.com/xi/XI/System/IDoc RCVPOR XXXCLNT010 ) ( http://sap.com/xi/XI/System/IDoc RCVPRN X1295_LWHA ) ( http://sap.com/xi/XI/System/IDoc RCVPRT LS ) ( http://sap.com/xi/XI/System/IDoc MESTYP WMTORD ) ( http://sap.com/xi/XI/System/IDoc IDOCTYP WMTOID01 ) ( http://sap.com/xi/XI/System/IDoc CIMTYP )</Trace>
    <Trace level="2" type="T">Mode 0</Trace>
    <Trace level="3" type="T">Creating Java mapping com/sap/xi/tf/_NAME_WMTORD_TO_SAP_BASIS_Receivers_.</Trace>
    <Trace level="3" type="T">Load 4e0cdfa0-6aab-11db-be41-eaca91374078, http://eu.Company.com/SC/Mak/Pack/ProdRec/xi, -1, com/sap/xi/tf/_NAME_WMTORD_TO_SAP_BASIS_Receivers_.class.</Trace>
    <Trace level="3" type="T">Search com/sap/xi/tf/_NAME_WMTORD_TO_SAP_BASIS_Receivers_.class (http://eu.Company.com/SC/Mak/Pack/ProdRec/xi, -1) in swcv 4e0cdfa0-6aab-11db-be41-eaca91374078.</Trace>
    <Trace level="3" type="T">Does not found exact entry. Search in other namspaces.</Trace>
    <Trace level="3" type="T">Search com/sap/xi/tf/_NAME_WMTORD_TO_SAP_BASIS_Receivers_.class (-1) in swcv 4e0cdfa0-6aab-11db-be41-eaca91374078 without namespace.</Trace>
    <Trace level="1" type="T">Class not found: com.sap.xi.tf._NAME_WMTORD_TO_SAP_BASIS_Receivers_</Trace>
    <Trace level="1" type="T">com.sap.aii.ibrun.server.mapping.persist.ResourceNotFoundException: Unable to find resource com/sap/xi/tf/_NAME_WMTORD_TO_SAP_BASIS_Receivers_.class (http://eu.Company.com/SC/Mak/Pack/ProdRec/xi, 4e0cdfa0-6aab-11db-be41-eaca91374078, -1) at com.sap.aii.ibrun.server.mapping.persist.DBSwcvMappingPersistor.getInputStream(DBSwcvMappingPersistor.java:325) at com.sap.aii.ibrun.server.mapping.persist.DBSwcvMappingPersistor.readFile(DBSwcvMappingPersistor.java:203) at com.sap.aii.ibrun.server.mapping.persist.DBSwcvMappingPersistor.readClass(DBSwcvMappingPersistor.java:195) at com.sap.aii.ibrun.server.mapping.MappingLoader.findClass(MappingLoader.java:138) at java.lang.ClassLoader.loadClass(ClassLoader.java:627) at java.lang.ClassLoader.loadClass(ClassLoader.java:593) at com.sap.aii.ibrun.server.mapping.JavaMapping.load(JavaMapping.java:95) at com.sap.aii.ibrun.server.mapping.JavaMapping.executeStep(JavaMapping.java:45) at com.sap.aii.ibrun.server.mapping.Mapping.execute(Mapping.java:92) at com.sap.aii.ibrun.server.mapping.MappingHandler.run(MappingHandler.java:90) at com.sap.aii.ibrun.sbeans.mapping.MappingRequestHandler.handleMappingRequest(MappingRequestHandler.java:95) at com.sap.aii.ibrun.sbeans.mapping.MappingRequestHandler.handleRequest(MappingRequestHandler.java:68) at com.sap.aii.ibrun.sbeans.mapping.MappingServiceImpl.processFunction(MappingServiceImpl.java:79) at com.sap.aii.ibrun.sbeans.mapping.MappingServiceObjectImpl0_0.processFunction(MappingServiceObjectImpl0_0.java:131) at sun.reflect.GeneratedMethodAccessor329.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:62) at java.lang.reflect.Method.invoke(Method.java:391) at com.sap.engine.services.ejb.session.stateless_sp5.ObjectStubProxyImpl.invoke(ObjectStubProxyImpl.java:187) at $Proxy252.processFunction(Unknown Source) at sun.reflect.GeneratedMethodAccessor328.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:62) at java.lang.reflect.Method.invoke(Method.java:391) at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:275) at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:217) at com.sap.engine.services.rfcengine.RFCJCOServer.handleRequest(RFCJCOServer.java:156) at com.sap.mw.jco.JCO$Server.dispatchRequest(JCO.java:7803) at com.sap.mw.jco.MiddlewareJRfc$Server.dispatchRequest(MiddlewareJRfc.java:2405) at com.sap.mw.jco.MiddlewareJRfc$Server.listen(MiddlewareJRfc.java:1728) at com.sap.mw.jco.JCO$Server.listen(JCO.java:8164) at com.sap.mw.jco.JCO$Server.work(JCO.java:8284) at com.sap.mw.jco.JCO$Server.loop(JCO.java:8231) at com.sap.mw.jco.JCO$Server.run(JCO.java:8147) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:219) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)</Trace>
    <Trace level="1" type="T">java.lang.ClassNotFoundException at JavaMapping.load(): Could not load class: com/sap/xi/tf/_NAME_WMTORD_TO_SAP_BASIS_Receivers_</Trace>

    Hi - We have executed the re-transport which resolved the situation described above.
    However we have not been able to fully close the topic and understand the root cause.
    Our current understanding is as follows:
    At the time of a transport activation, a cache notification is created and the information is transmitted from the Integration Directory to the different caches using user XIDIRUSER. After the successful notification, the cache update is triggered. This is initiated by the IE ABAP Runtime via user XIISUSER. This user is calling the Integration Directory which than takes user XIDIRUSER to retrieve the required objects, e.g. message mappings, from the Integration Repository. If at this stage, the user XIDIRUSER does not receive an available Work-Process, the action is not completed. This means also the cache notification stays green, as the negative feedback cannot be transmitted either, since the user XIDIRUSER 'died out'.
    This was confirmed to happen in an overload situation for our system.
    Please comment if you have any further experiences or different explanation.
    Mathias

  • Reg:Dynamic Configuration

    Hi....
           I am having one problem while using Dynamic Configuration.
    In Dynamic Configuration, i am using the below code.
    DynamicConfiguration conf = (DynamicConfiguration) container
        .getTransformationParameters()
        .get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","Directory");
        conf.put(key, a);
    return "";
    I am having the condition like, if the Product code="DD" and Server Name =" A", then the file should be places in "Disb" directory else it should be places in the "Power" directory.
    Can you please help in this issue.
    I have executed the scenario, but both the files are going to the same folder.

    Hi...
      Check the below code whther it is correct or not.
    public String DynamicDirectory(String code,String server,Container container)
    DynamicConfiguration conf = (DynamicConfiguration) container
        .getTransformationParameters()
        .get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","Directory");
    if(code.equals("DD") && server.equals("DISB"))
    dir = "/home/corpuser/Disbursement/DD";
    else(code.equals("CC") && server.equals("DISB"))
    dir = "/home/corpuser/Disbursement/CC";
    config.put(key,dir);
    return "";
    While activating, i am getting the below error.
    usr/sap/APD/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Map1354a56019d011debb16002264977f6e/source/com/sap/xi/tf/_MM_MTO_Payment_DB_To_MTI_Payment_DD_CC_.java:301: not a statement else(code.equals("CC") && server.equals("DISB")) ^ /usr/sap/APD/DVEBMGS00/j2ee/cluster/server0/./temp/classpath_resolver/Map1354a56019d011debb16002264977f6e/source/com/sap/xi/tf/_MM_MTO_Payment_DB_To_MTI_Payment_DD_CC_.java:302: ';' expected dir = "/home/corpuser/Disbursement/CC"; ^ 2 errors
    Can you please in this issue.
    Regards,
    Leela

  • Error Message through Dynamic Configuration length problem

    HI All,
    We are trying to raise an error message with the help of Dynamic configuration in the Message mapping.
    The need is to populate the message with certain variables.
    However we are facing the problem that the message is getting truncated beyond a certain length.(Around 60 characters)
    Similar custom messages in other interfaces are working fine for messages up to 100 characters.
    Question:
    1. What could be the maximum length for an error message in case of mapping failure?
    2. What could be limiting the length of the message in our case?
    Thank you for looking into this.
    Regards,
    Ankesh

    hi Ankesh,
    yes, there is limit length, see this oss [Note 974481 - XI Adapter Framework DynamicConfiguration Module|https://service.sap.com/sap/support/notes/974481]
    regards.
    Mickale

  • Problem in Dynamic Configuration bean

    Hi
    I am trying to dynamically change the filename using Dynamic Configuration bean with some constant value but target file is having same name as source.  In communication channel logs I can see the successul pro

    Hi,
    M not sure what will be the error with this when u r using dynamic configuration bean.But same functionality can be better achieved by using this dyanamic configuartion UDF :
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create( "http://sap.com/xi/XI/System/File", "FileName");
    conf.put(key, a);
    return value;
    Regards,
    Anoop

  • Dynamic configuration of Adpater in SAP PI

    Hi,
    I have a requirement where in I have to dynamically configure connection adpater in SAP PI 7.1 EHP 1,  the configuration data will be pulled form database on the bases of the message content.
    Thanks in advance.
    Gautam

    Not sure if you are lookingg for dynamic configuration as mention in the below blog..
    <a href="/people/william.li/blog/2006/04/18/dynamic-configuration-of-some-communication-channel-parameters-using-message-mapping Configuration of Some Communication Channel Parameters using Message Mapping</a>
    <a href="/people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14: The same filename from a sender to a receiver file adapter - SP14</a>
    <a href="/people/daniel.graversen/blog/2006/10/05/dynamic-configuration-in-adapter-modules Configuration In Adapter Modules</a> <a href="/people/michal.krawczyk2/blog/2006/10/09/xi-dynamic-configuration-in-adapter-modules--one-step-further Configuration In Adapter Modules</a>
    ~SaNv...

  • Problem with dynamic configuration in PI 7.0 (SP 21)

    We're trying to set a dynamically configurable parameter (UrlParam in plain http adapter) in a java mapping and when calling,   via proxy, getting the following error returned<br />
    <p />
    <br />
    &lt;?xml version="1.0" encoding="utf-8" ?&gt;<br />
    - &lt;asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0"&gt;<br />
    - &lt;asx:values&gt;<br />
      &lt;SYSTEMFAULT href="#o284" /&gt;<br />
      &lt;/asx:values&gt;<br />
    - &lt;asx:heap xmlns:xsd="http://www.w3.org/2001/XMLSchema"<br />
    xmlns:abap="http://www.sap.com/abapxml/types/built-in" <br />
    xmlns:cls="http://www.sap.com/abapxml/classes/global" <br />
    xmlns:dic="http://www.sap.com/abapxml/types/dictionary"&gt;<br />
    <br />
    - &lt;cls:CX_AI_SYSTEM_FAULT id="o284"&gt;<br />
    - &lt;CX_ROOT&gt;<br />
      &lt;TEXTID&gt;F63AFF63DBE4BB4786A7F52CC4167145&lt;/TEXTID&gt;<br />
      &lt;PREVIOUS /&gt;<br />
      &lt;KERNEL_ERRID /&gt;<br />
    - &lt;INTERNAL_SOURCE_POS&gt;<br />
      &lt;PROGID&gt;95&lt;/PROGID&gt;<br />
      &lt;CONTID&gt;3304&lt;/CONTID&gt;<br />
      &lt;/INTERNAL_SOURCE_POS&gt;<br />
      &lt;/CX_ROOT&gt;<br />
      &lt;CX_STATIC_CHECK /&gt;<br />
    - &lt;CX_AI_SYSTEM_FAULT&gt;<br />
      &lt;CODECONTEXT /&gt;<br />
      &lt;CODE&gt;PLAINHTTP_ADAPTER.ATTRIBUTE_MISSING_PARAMS&lt;/CODE&gt;<br />
      &lt;ERRORTEXT /&gt;<br />
      &lt;LANGUAGE /&gt;<br />
      &lt;/CX_AI_SYSTEM_FAULT&gt;<br />
      &lt;/cls:CX_AI_SYSTEM_FAULT&gt;<br />
      &lt;/asx:heap&gt;<br />
      &lt;/asx:abap&gt; <br />
    <p />
    <br />
    The java code in the mapping is as follows:<br />
    <br />
    The java code in the mapping is as follows:<br />
    /*<br />
    Created on 07-Jun-2010<br />
    *<br />
    To change the template for this generated file go to<br />
    Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments<br />
    */<br />
    package uk.gov.communities.finance; <br />
    <br />
            import java.io.InputStream;<br />
    import java.io.OutputStream;<br />
    import java.util.Map;<br />
    <br />
    import com.sap.aii.mapping.api.DynamicConfiguration;<br />
    import com.sap.aii.mapping.api.DynamicConfigurationKey;<br />
    import com.sap.aii.mapping.api.StreamTransformation;<br />
    import com.sap.aii.mapping.api.StreamTransformationException; <br />
    <br />
    /**<br />
    @author Mark<br />
    *<br />
    To change the template for this generated type comment go to<br />
    Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments<br />
    */ <br />
    <br />
    public class PaymentGatewayRequestMap implements StreamTransformation {<br />
            /** This Map parameter is for the Method setParameter() */<br />
            Map param=null;<br />
            /** This method should be used while the Class implements<br />
    StreamTransformation interface<br />
             *<br />
    @param param - A Map object<br />
             */<br />
            public void setParameter(Map param){<br />
                    this.param=param;<br />
            }<br />
    <br />
    /**<br />
    This method will be called by XI to execute Java Mapping. <br />
    @param in - The InputStream which has the source message from CRM <br />
    @param out - The OutputStream which has the target message to ProFinance <br />
    */ <br />
    public  void execute (InputStream in, OutputStream out) throws
    StreamTransformationException { <br />
    String urlParamOne = null; <br />
    try{ <br />
    DynamicConfiguration dynCon = (DynamicConfiguration)param.get("DynamicConfiguration");  <br />
    DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/HTTP","myValueHere"); <br />
    String response = ""; out.write(response.getBytes()); <br />
    } <br />
    catch(Exception e){<br />
                            throw new RuntimeException(e.getMessage());<br />
                    }<br />
            }<br />
    }<br />
    <p />
    <p />
    <p />
    Looking at the call in SXMB_MONI there's no sign of the dynamic configuration stage anywhere but we are seeing the following in the response message:
    <p />
    <br />
    &lt?xml version="1.0" encoding="UTF-8" standalone="yes" ?&gt;<br />
    -&lt !--  Call Adapter <br />
      --&gt;<br />
    - &lt;SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1"&gt;<br />
    &lt;SAP:Category>XIAdapter&lt;/SAP:Category&gt;<br />
      &lt;SAP:Code area="PLAINHTTP_ADAPTER"&gt;ATTRIBUTE_MISSING_PARAMS&lt;/SAP:Code&gt;<br />
      &lt;SAP:P1 /&gt;<br />
      &lt;SAP:P2 /&gt;<br />
      &lt;SAP:P3 /&gt;<br />
      &lt;SAP:P4 /&gt;<br />
      &lt;SAP:AdditionalText /&gt;<br />
      &lt;SAP:ApplicationFaultMessage namespace="" /&gt;<br />
      &lt;SAP:Stack>Dynamic Header - Missing Message Attributes: Fields/Parameters&lt;/SAP:Stack&gt;<br />
      &lt;SAP:Retry>N&lt;/SAP:Retry&gt;<br />
      &lt;/SAP:Error&gt;<br />
    <p />
    <br />
    Please note, we have set this up on another PI system (7.0 sp 12) and it works as required.
    <p />
    <br />
    Many thanks
    <p />
    <br />
    Andreas

    Hello , let me clarify:
    - There's a graphical mapping which has a user defined function with the following code:
    DynamicConfigurationKey dynKey =DynamicConfigurationKey.create(
    "http://sap.com/xi/XI/System/HTTP",paramName);
    DynamicConfiguration dynCon =(DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    dynCon.put(dynKey, paramValue);
    return paramValue;
    - The above UDF has paramName set to UrlParamOne via a constant and paramValue set a per an element in the incoming structure.
    - Incidentally, a Java mapping is then called (although not relevent) to clear the xml produced from the mapping. This is a requirement for our customer who don't want the HTTP body set. The code is as follows:
    Created on 07-Jun-2010
    To change the template for this generated file go to
    Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
    package uk.gov.communities.finance;
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.util.Map;
    import com.sap.aii.mapping.api.StreamTransformation;
    import com.sap.aii.mapping.api.StreamTransformationException;
    @author Mark
    To change the template for this generated type comment go to
    Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
    public class PaymentGatewayRequestMap implements StreamTransformation {
    /** This Map parameter is for the Method setParameter() */
    Map param=null;
    /** This method should be used while the Class implements
    StreamTransformation interface
    @param param - A Map object
    public void setParameter(Map param){
    this.param=param;
    This method will be called by XI to execute Java Mapping.
    @param in - The InputStream which has the source message from CRM
    @param out - The OutputStream which has the target message to ProFinance
    public void execute(InputStream in, OutputStream out) throws StreamTransformationException {
    try{
    String response = "";
    out.write(response.getBytes());
    catch(Exception e){
    throw new RuntimeException(e.getMessage());
    Many thanks
    Andreas

  • Problem with Dynamic Configuration in XSLT mapping..!!

    Hi friends,
    Working first time with xslt map.I am doing a Idoc to File scenario in which I need to pass Idoc number as the file name dynamically. Right now I am just trying to send some constant value 'ABCD' to go in dynamic attribute filename.
    I used the code which has been provided over here.
    [http://help.sap.com/saphelp_nw04/helpdata/en/43/03fe1bdc7821ade10000000a1553f6/frameset.htm|http://help.sap.com/saphelp_nw04/helpdata/en/43/03fe1bdc7821ade10000000a1553f6/frameset.htm]
    I just changed the "Directory" with "FileName" in the code. It is not generating the dynamic attribute http://sap.com/xi/XI/System/File
    This is my xsl code. Please suggest me If iam doing anything wrong.
    <?xml version="1.0" encoding="utf-8"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:map="java:java.util.Map" xmlns:dyn="java:com.sap.aii.mapping.api.DynamicConfiguration" xmlns:key="java:com.sap.aii.mapping.api.DynamicConfigurationKey">
         <xsl:output indent="no"/>
         *<xsl:param name="inputparam" select = "ABCD"/>*
         <xsl:output method="text" encoding="utf-8"/>
         <xsl:template match="/">
              <!-- change dynamic configuration -->
              <xsl:variable name="dynamic-conf" select="map:get($inputparam, 'DynamicConfiguration')"/>
              *<xsl:variable name="dynamic-key" select="key:create('http://sap.com/xi/XI/System/File', 'FileName')"/>*
              <xsl:variable name="dynamic-value" select="dyn:get($dynamic-conf, $dynamic-key)"/>
              <xsl:variable name="new-value" select="concat($dynamic-value, 'subfolder\')"/>
              <xsl:variable name="dummy" select="dyn:put($dynamic-conf, $dynamic-key, $new-value)"/>
              <!-- copy payload -->
              <xsl:copy-of select="."/>
         </xsl:template>
         <xsl:template match="/">
    Waiting for your answers.
    Thank you.
    Deepthi.

    Hi Stefen,
    I tried the way you suggest but still I couldn't able to see the Dynamic Configuration attribute in SOAP document. I tried for Idoc number and even tried by passing just a value 'abcd' like below.
    <?xml version="1.0" encoding="utf-8"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:map="java:java.util.Map" xmlns:dyn="java:com.sap.aii.mapping.api.DynamicConfiguration" xmlns:key="java:com.sap.aii.mapping.api.DynamicConfigurationKey">
         <xsl:output indent="no"/>
         <xsl:output method="text" encoding="utf-8"/>
         *<xsl:param name="inputparam"/>*
                    *<xsl:param name="new-value">*
      *<xsl:value-of select="/WMMBID01/IDOC/EDI_DC40/DOCNUM" />*
      *</xsl:param>*     
         <xsl:template match="/">
              <!-- change dynamic configuration -->
              <xsl:variable name="dynamic-conf" select="map:get($inputparam, 'DynamicConfiguration')"/>
              <xsl:variable name="dynamic-key" select="key:create('http://sap.com/xi/XI/System/File', 'FileName')"/>
              <xsl:variable name="dummy" select="dyn:put($dynamic-conf, $dynamic-key, $new-value)"/>
    <?xml version="1.0" encoding="utf-8"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:map="java:java.util.Map" xmlns:dyn="java:com.sap.aii.mapping.api.DynamicConfiguration" xmlns:key="java:com.sap.aii.mapping.api.DynamicConfigurationKey">
         <xsl:output indent="no"/>
         <xsl:output method="text" encoding="utf-8"/>
         *<xsl:param name="inputparam"/>*
                    *<xsl:param name="new-value" select="abcd">*
       *</xsl:param>*     
         <xsl:template match="/">
              <!-- change dynamic configuration -->
              <xsl:variable name="dynamic-conf" select="map:get($inputparam, 'DynamicConfiguration')"/>
              <xsl:variable name="dynamic-key" select="key:create('http://sap.com/xi/XI/System/File', 'FileName')"/>
              <xsl:variable name="dummy" select="dyn:put($dynamic-conf, $dynamic-key, $new-value)"/>
    Any suggestions please.
    Thanks
    Deepthi.

  • Can i get some live problems faced on support for sap hr

    Can i get some live problems faced on support for sap hr and how were they resolved? Please give a step by step detail of the sol.
    Dear
    Member,  of all the  Issues raised in the forum some of the issues are support issues you can have a look at all these threads
    Please read the forum rules before Posting the Query

    Hi,
    Please be with this SDN.SAP Forum, you will get solutions of all types of queris.
    Regards,
    Ram Aware

  • Problem:obtaing file name using Dynamic configuration of file adapter

    hi all
    I am using Dynamic configuration for getting file name.
    I am getting Dynamic configuration in SXMB_MONI containg file name, but payload is empty unlike file i am sending.

    Hi All,
    Basically my requirement to get Filename in idoc segments in order to validate the posting at month end.
    Its an File to idoc scenario- GL Posting.
    Please check attached UDF and it gives error. Kindly help. Thanks

  • XSLT Mapping with Dynamic Configuration for Mail Adapter

    Hi Guys,
    I am wondering if somebody can help me please.
    I have a requirement in which I need to pick up the file from FTP and email it to the user as an attachment with the same file name and content.
    I know it is possible via 3 method either by deploying adapter module or via XSLT or JAVA Mapping.
    I preferred XSLT Mapping because it is easier to use and we don't need to compile the code like JAVA Mapping.
    I have done the XSLT Mapping but the only problem I am facing is that how to copy the file name which we get it from Dynamic Configuration to the Mail ContentDisposition.
    <?xml version="1.0" encoding="UTF-8"?>
    <xsl:stylesheet version="1.0"
      xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
      xmlns:map="java:java.util.Map"
      xmlns:dyn="java:com.sap.aii.mapping.api.DynamicConfiguration"
      xmlns:key="java:com.sap.aii.mapping.api.DynamicConfigurationKey">
    <xsl:output indent="no" />
    <xsl:param name="inputparam"/>
    <xsl:template match="/">
    <!-- change dynamic configuration -->
        <xsl:variable name="dynamic-conf" 
            select="map:get($inputparam, 'DynamicConfiguration')" />
        <xsl:variable name="dynamic-key"  
            select="key:create('http://sap.com/xi/XI/System/File', 'FileName')" />
        <xsl:variable name="dynamic-value"
            select="dyn:get($dynamic-conf, $dynamic-key)" />
        <xsl:variable name="dummy"
            select="dyn:put($dynamic-conf, $dynamic-key, $new-value)" />
        <!-- copy payload -->
    I tried many option but unfortunately none of them worked.
    <Content_Disposition>attachment;filename="$inputparam"</Content_Disposition>
    <Content_Disposition>attachment;filename="$dynamic-conf"</Content_Disposition>
    <Content_Disposition>attachment;filename="$dynamic-key"</Content_Disposition>
    <Content_Disposition>attachment;filename="$dynamic-value"</Content_Disposition>
    <Content_Disposition>attachment;filename="$dummy"</Content_Disposition>
             <Content_Disposition>
                attachment;filename=
                <xsl:value-of select="dynamic-key"/>
             </Content_Disposition>
    I really appreciate if someone can please provide some guidance.
    Thanks,

    Hi,
    Yes u r correct it will show error in operation mapping.. bcoz u cannot check the DynamicConfiguration in Operation mapping...
    It will throw Exception..
    The parameter to UDF depends on ur requirement.... Let us know ur requirements exactly...
    If u r doing for file to file means no UDF required,, just check ASMA on both sides....
    Babu

  • Dynamic Configuration File Names

    Hi,
    I have a RFC->XI->File scenario.
    I have to put the target files names based on the calculation of values in 2 fields in the input.
    I tried using Dynamic Configuration in my message mapping for this.
    This is the code:
    DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create(u201Chttp://sap.com/xi/XI/System/Fileu201D,u201CFileNameu201D);
    String MyFileName = a + "_" + b +".xml";
    conf.put(key, myFileName);
    I checked ASMA in both the sender RFC adapter as well as the receiver file adapter.
    But it never works.
    I saw the dynamic configuration tab in SXMB_MONI but i can see only the RFC destination parameter.
    Cant see the file filename parameter.
    What is the problem here?

    No need enable ASMA on RFC sender adapter.
    See if the file channel is activated after selecting ASMA with FileName.
    The UDF might not be use in the mapping. Check this.
    Edited by: Praveen Gujjeti on Feb 23, 2010 1:05 AM

Maybe you are looking for