JMS Message Format

Hi,
I have to set-up a scenario where I have to load messages from a Message Queue system via XI JMS Adapter into R/3. On R/3 side, we are talking about the Invoices IDoc. Now I have to define the XML structure of the message that has to be provided in the message queue of the SonicMQ System. Does anybody have experience with loading XML messages from a message queue system and can tell me how the message structures are defined? Is a XSD or DTD desription enough? Or does a JMS message also contain somehting like Header data like SOAP?
Thanks in advance.
Alex

Hi Alexander,
<i>Or does a JMS message also contain somehting like Header data like SOAP?</i>
The datatype you create for your JMS message will be like any other XMl messsage you craete for a FILE.
If the application posting the message to the JMS queue is not posting an XML message or in a format that you want, you can always do content conbersion in the Sender JMS adapter.
Take a look at this,
http://help.sap.com/saphelp_nw04/helpdata/en/4d/a3bc97ff55c742af7faed661635baf/content.htm
<a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/f02d12a7-0201-0010-5780-8bfc7d12f891">How to use Content Coneversion Module of JMS adapters</a>
Regards,
Bhavesh

Similar Messages

  • Jms message format - object format ?

    hi all,
              there are a few messasges formats for messages i'm familier with from
              MQ : MQHRF2, MQFMT_STRING ...
              is there any way to send a message from JMS with MQFMT_STRING format?
              is the default MQHRF2 ?
              is there a way/browser to send/view an object i'm sending as xml ?
              

    You need to find the IBM manual called "WebSphere MQ Using Java". It moves
              around, so I'd suggest going to http://www.ibm.com/software/mqseries/ and
              searching from there. This describes in great detail how messages are
              constructed using the MQSeries JMS API.
              But the short answer is "yes", and the way you do it is that when you use
              the IBM "JMSAdmin" tool to create the JMS "Q" object in JNDI, you specify
              parameters that tell the MQSeries JMS API what format message to create...
              greg
              "hagai" <[email protected]> wrote in message
              news:[email protected]..
              > hi all,
              > there are a few messasges formats for messages i'm familier with from
              > MQ : MQHRF2, MQFMT_STRING ...
              > is there any way to send a message from JMS with MQFMT_STRING format?
              > is the default MQHRF2 ?
              > is there a way/browser to send/view an object i'm sending as xml ?
              

  • Format of "JMS Message Destination Parameter" for JMS Sender Adapter

    Hi,
    I am trying to use the JMS Sender Communication Channel for several Interfaces by using the "JMS Message Destination Parameter". Currently, the Comm.Channel is reading the message and puts it back on the queue with the following error:
    Fehler bei der XI-Eingangsverarbeitung für Message am bzw. um 2007-07-25|09:34:12.057+0200. JMS- und XI-Identifikatoren für die Message sind ID:414d512051535749515441302020202046a4e892201c4d04 bzw. 701ec850-3a81-11dc-8176-00306e2c36a3. Der JMS-Adapter führt einen Rollback der Datenbank und der JMS-Sitzungtransaktionen durch. Wird die Sitzung ausgeführt, geht die Message nicht verloren und wird später erneut durchgeführt. Der Ausnahme-Stack-Trace ist java.lang.RuntimeException: MQJMS0003: Destination not understood or no longer valid: UserCreateRequest
    at com.ibm.mq.jms.MQDestination.createDestination(MQDestination.java:790)
    at com.ibm.mq.jms.MQSession.createDestination(MQSession.java:1092)
    at com.ibm.jms.JMSMessage.getJMSDestination(JMSMessage.java:4127)
    What is the format I will have to fill this parameter with in order for XI to understand it? I have tried the following so far which did not work:
    1.   (as in error message above)
    Help much appreciated.
    KR,
    Colin.

    One option in BPEL is to have a mid process receive, but this would require you to handle the Correlation of the message with BPEL process instance.
    Please refer the following section in SOA Guide for the same.
    Using Correlation Sets and Message Aggregation - 11g Release 1 (11.1.1.7)
    Please note the example is with File adapter but the same can be achieved for Any Adapter.

  • PI JMS Adapter MQ Message Format

    Hi,
    I know that if you change the target client in the JMS adapter properties il will change the message format for MQSTR (Websphere MQ Non-JMS) or MQRFH2 (JMS-Compliant).
    But is there a way to force the MQ Message format to NONE or an empty string? The MQSTR is causing some unwanted conversion in legacy systems.
    PI 7.1 EHP1.
    Thanks,
    Martin

    Hi Martin - I relize you've already answered, but as an fyi, my somewhat related requirement was to have the mqmd.format=MQIMS, instead of the value MQSTR that PI seems to default to. 
    I was able to achieve this by
    (1) setting that Module JMSMessageType=bytes parm like you did, and
    (2) set an additional parameter entry (i.e. on your 'Advanced' tab) of
    JMS.Message.method.setStringProperty java.lang.String JMS_IBM_Format, java.lang.String MQIMS
    (I think you need MQ7 libraries for this).
    Keith

  • What is the format for a Client Request JMS message.

    I am trying to send directly to the JMS queue to start a WLI process. From the Workshop browser, the message is received. However, when sending my own JMS message, WebLogic complains with an "Unexpected message format" onMessageException.
    What is the correct format for a WLI Client Request node? A text message? Please help. Thanks - Frank.

    Kai,
    Thanks for the info. I have created a MB channel and a JMS event generator. But now it seems that my problem has simply been moved further out. Case in point: If I send a simple XML text message to the JMS event queue, the WebLogic JPD throws a MBConnectorException ("Could not determine channel type").
    So I am wondering if this is still not the best practice to accomplish what I want. Should I be using a MDB which then simply calls a JCX control that knows how to talk to the WLI start node? The whole idea is that I want to start the workflow with a simple JMS message.
    Thanks in advance,
    Frank

  • Adapter Status Error :  Error in creating message ID map for JMS message:

    Currently in the SAP XI 3.0 JMS Adapter, I am receiving the following error
    Error in creating message ID map for JMS message:
    ie. Error while processing message 'de8265f6-c864-4479-1137-9bab17b78b3b';  detailed error description: com.sap.aii.adapter.jms.api.channel.filter.MessageFilterException: Error in creating message ID map for JMS message: ID:c3e2d840d8d4d7f14040404040404040c44f8e2213630b01 at com.sap.aii.adapter.jms.core.channel.filter.InboundDuplicateCheckFilter.filter(InboundDuplicateCheckFilter.java:103)
    Although I am receivng this error, when I check the details of the message processing, all steps are successful and the message is set to status : DLVD
    Audit Log for Message: de8265f6-c864-4479-1137-9bab17b78b3b
    Time Stamp     Status     Description
    09.06.2009 13:27:24     Success     New JMS message with JMS message ID ID:c3e2d840d8d4d7f14040404040404040c44f8e2213630b01 received. The XI message ID for this message is de8265f6-c864-4479-1137-9bab17b78b3b
    09.06.2009 13:27:24     Success     JMS message converted to XI message format successfully
    09.06.2009 13:27:24     Success     RRB: entering RequestResponseBean
    09.06.2009 13:27:24     Success     RRB: suspending the transaction
    09.06.2009 13:27:24     Success     RRB: passing through ...
    09.06.2009 13:27:24     Success     RRB: leaving RequestResponseBean
    09.06.2009 13:27:24     Success     Transform: using Transform.Class: com.sap.aii.messaging.adapter.Conversion
    09.06.2009 13:27:24     Success     Transform: transforming the payload ...
    09.06.2009 13:27:24     Success     Transform: successfully transformed
    09.06.2009 13:27:24     Success     Application attempting to send an XI message synchronously using connection JMS_http://sap.com/xi/XI/System.
    09.06.2009 13:27:24     Success     Trying to put the message into the call queue.
    09.06.2009 13:27:24     Success     Message successfully put into the queue.
    09.06.2009 13:27:24     Success     The message was successfully retrieved from the call queue.
    09.06.2009 13:27:24     Success     The message status set to DLNG.
    09.06.2009 13:27:25     Success     The application sent the message synchronously using connection JMS_http://sap.com/xi/XI/System. Returning to application.
    09.06.2009 13:27:25     Success     The message was successfully transmitted to endpoint http://sapxia.swets.nl:8000/sap/xi/engine?type=entry using connection JMS_http://sap.com/xi/XI/System.
    09.06.2009 13:27:25     Success     The message status set to DLVD.
    Not sure why this is occurring.......

    No, not using correlation id.
    I was able to resolve the issue on this queue by changing the following setting
    Under the PROCESSING tab, under XI SETTINGS
    Time period for Duplicate Check for EO(IO) (secs) it was set to 86400
    I have changed this to 300 seconds and the adapter has now gone green.
    BUT......
    That said, I have the exact scenario on another sender JMS channel set to 300 seconds and it exhibits the same issue.
    correlation settings:
    Set XI message id  to  = GUID
    Set Xi conversation

  • How To Set JMS Message ID

    Hi,
    I am working for a client that uses a MQ Series as their interface routing infrastructure.  They have written some custom tools that log MQ messages.  Their tools expect the MQ message ID to be in a specific format YYYY_MM_DD_HHMMSS_AAAAAA where AAAAAA is a unique set of characters based on the millisecond.
    Is it possible to set the JMS message ID on a JMS receiver adapter?
    Thanks in advance for your help,
    Craig

    Hi Craig,
    as it looks you have to set the Message Id in a special format. I am not sure if this is possible at all. I didn't find a way to influence how XI sets the JMS Message Id.
    Maybe you could work with the JMS Correlation ID instead and have your client adapt his tools. You can use either a User-Defined Function or a Java Mapping, setting the so-called Adapter-specific attribute DCJMSCorreleationId
    Here you can find an example how to do this in the User-Defined Function:
    http://help.sap.com/saphelp_nw04/helpdata/en/43/03612cdecc6e76e10000000a422035/frameset.htm
    In a Java Mapping it is similar:
    http://help.sap.com/saphelp_nw04/helpdata/en/43/09b16006526e72e10000000a422035/frameset.htm
    This example uses the File Adapter, but the same applies for the JMS Adapter.
    The JMS Adapter has the namespace http://sap.com/xi/XI/System/JMS
    Have a look at this one to find out more about the Adapter-specific attributes of the Receiver JMS Adapter:
    http://help.sap.com/saphelp_nw04/helpdata/en/10/b1b4c8575a6e47954ad63438d303e4/frameset.htm
    I hope that this information is of some help for you.
    regards,
    Peter

  • How to set user ID in JMS message

    I am looking for ways to set the user ID in a JMS message over MQ series. I have looked at various way of doing it including:
    1) setting the appropriate environment variable in MQEnvironment
    2) setting provider specific properties (of the format "JMS_IBM_xxxx")
    3) in desperation, setting any likely looking property, e.g. "JMSXUserId"
    None of these work, consequently the default user ID "mqm" is propagated. Rather than getting an error message back (with, I think, a 2059 code) when host authentication fails, I simply get nothing back.
    I'd be grateful for any suggestions
    Hugh Ferguson

    3) in desperation, setting any likely looking
    property, e.g. "JMSXUserId"I believe these properties are case-sensitive. We don't set the user id property in our JMS messages, but I can tell you that when we receive messages from apps on our mainframe host (which do not use JMS - they use the COBOL api), the user id is in a property called UserID (note that "ID" is capitalized). In raw form, it's JMSXUserID.
    Hope this helps,
    -Scott

  • How to do service callout with the incoming JMS message in OSB 11g

    Hello All,
    I have a specific requirement for which I am creating a kind of POC where I need some help in OSB, however am new to OSB.
    My Environment:
    1> I have a request queue (deployed on a WLS domain) - WFReq_WS
    2> I have a response queue (deployed on a WLS domain) - WFRes_WS
    3> I have created a ProxyService (request/response type) in OSB 11g which is simply mapping the incoming message in WFReq_WS to WFRes_WS
    4> I have a WebService (it is currently a simple hello WebService for testing) which takes a string and returns the same string with an added 'Hi' in front of it (e.g. If you send Jack, it will return 'Hi Jack')
    My Requirement:
    1> I have to do some mechanism in OSB, by which while mapping the message from WFReq_WS to WFRes_WS (through the proxy service I have), it will pick the JMS message (which will be a string/text) and will make a service callout to the Webservice I mentioned using the message as the input parameter of the WebService.
    2>Now when the response of the WebService will come, OSB should send this response as the message in the response queue (WFRes_WS) I mentioned above.
    To simplify the requirement using an example:
    A> I will send a text/String message (say Jack) to the request queue (WFReq_WS)
    B> OSB should pick the message (Jack) and make a service callout to the webservice
    C> webservice will return 'Hi Jack'
    D> OSB should send this to the response queue (WFRes_WS)
    I know the above might look very basic question to the PROs, but please elaborate (step by step) what need to be done, since I do not know OSB.
    Thanks a lot for your help !

    Your example points A and D are easily done by having a "Proxy Service" which has the following details:
    Service Type = Messaging Service
    Request and Response type = Text
    Protocol = jms
    Endpoint URI = your request queue (format like 'jms://localhost:7013/weblogic.jms.XAConnectionFactory/QueueJNDIName')
    Checkmark "response" so that the proxy service automatically delivers the response to another queue - your response queue
    Response URI = jms://localhost:7013/weblogic.jms.XAConnectionFactory/QueueResponse
    Now since your "Hello" webservice is (probably) a SOAP xml service you need to "convert" your text based JMS message to xml before sending it on to the "Hello" service.
    Your JMS proxy can do that by just doing a "Assign <whom>{$body/text()}</whom>" to a variable (lets call it 'reqHello')
    Now your JMS proxy should actually call the Hello service and since your JMS proxy is text and the Hello service is SOAP you cannot just "pass" on to the Hello service in a "Route to". Instead you can do a Service Callout where you can specify your "reqHello" variable as payload and a "respHello" as response variable.
    Now you have the "<whom>Hi jack</whom>" in the response variable and since the JMS response needs to be text format you can "extract" the text value into the body variable of the JMS proxy (use "replace /* in body with $respHello/text()" - replace node contents)
    The actual Hello service is a simple "SOAP" based Proxy Service. Add a pipeline and add a stage in the reponse pipeline. Do a ...
    Assign fn:concat("Hi ",$body/whom/text()) to $whomVar
    Replace whom in body with $whomVar (replace node contents)

  • Incoming JMS message

    Folks
    I am new to JMS Adapter and have a scenario which sounds difficult
    I have a Mesage arriving in JMS queue which will be a collection of invoices , again to be posted onto IDOCS in ECC
    Is  the Queue message format  XML, usually or does it come as a file ?
    The structure of the message will be such that few of the nodes will be present  if it comes from one source and will not be present when it comes from the others,
    Is there a standard way to differentiate on the basis of the incoming message, in JMS adapter functionality or a code has to be written ?
    Do i need to be a Core Java coder to use JMS adapter ??
    please help

    If you want to use JMS adapter to pick up particular messages from one queue, please reference my wiki:
    Usage of Message Selector for JMS Sender Adapter
    https://www.sdn.sap.com/irj/scn/wiki?path=/display/xi/usage%252bof%252bmessage%252bselector%252bfor%252bjms%252bsender%252badapter
    If you want to use receiver adatpers to route different message to different receivers, then you can use conditional routing as Aamir replied you.
    Regards.
    Liang

  • Setting JMS Selector as JMS Message ID

    Does anyone knows how to set the JMS Selector as JMS Message id, i tried using JMSMessageID=P<720374.1242857046478.0> but i keep getting exception stating
    javax.jms.InvalidSelectorException: weblogic.messaging.kernel.InvalidExpressionException: Expression : "JMSMessageID=P<720374.1242857046478.0>"
         at weblogic.rjvm.BasicOutboundRequest.sendReceive(BasicOutboundRequest.java:108)
         at weblogic.rmi.internal.BasicRemoteRef.invoke(BasicRemoteRef.java:164)

    Hi Tom,
    Do you know any general solution for the situation you mentioned in your last post on this thread? Unfortunatelly one of our customers have an architecture which mixes a weblogic 8 domain with a weblogic 10 one. The JMS server is in the weblogic 10 domain but they have an OOB IGW application which runs on weblogic 8 and uses the JMS API of it. The IGW application applies the JMS Message Id model for correlating the request and response messages, but the consumer, on the weblogic 10 side, cannot find the response message because the JMS Message Id changed. The JMS of webloigc 8 - I guess - put an 'N' char after 'ID:' into the msgId and paste the whole id into the correlationId field. But on the weblogic 10 side, the consumer have the original msgId without 'N' and, of course, it doesn't find the response msg.
    So do you have any general solution to convert between these different msgId formats?
    Thanks in advance,
    Andras

  • JMS message segmentation

    I am new to JMS and I would like to know how to segmentize a large JMS message.?
    I have seen how to break down a message in multiple segments using the MQ native API , but my client application uses JMS API
    Thanks in advance

    Its certainly not in the spec.
    Some providers will give you a sensible output from toString(), others will not.
    If you just want to dump it to a string for debug its a pretty easy task to dump the header and payload programmatically in some nice format - take you an hour or so to write.
    Regards,
    Colin
    http://hermesjms.com

  • WLI/JMS Message problem

    I have written a WLI client program that has JMS listeners for assigned, update,
    and remove WLI Notify messages. The basic format for each selector is simple:
    orgId = 'ORG1' and action = 'assigned'
    I've noticed an inconsistency when it comes to the JMS messages sent to my application.
    Say Task A is configured to be assigned to Joe when it's activated. When the
    task is actually activated, my client program receives an update message followed
    by an assign message (both for that task).
    Okay, here's where it gets tricky. Say the workflow returns to Task A later on
    in the same instance of the workflow. This time my client only gets an update
    JMS message. I have to account for this inconsistency in my code, which is not
    good.
    Is this a bug, or is there a reason that this is behaving like this?

    David
    Please open a case or provide your demo code to me, I will take a look
    when I get some free time
    Tony
    "David Mrozek" <[email protected]> wrote in message
    news:3b852200$[email protected]..
    >
    I have written a WLI client program that has JMS listeners for assigned,update,
    and remove WLI Notify messages. The basic format for each selector issimple:
    >
    orgId = 'ORG1' and action = 'assigned'
    I've noticed an inconsistency when it comes to the JMS messages sent to myapplication.
    >
    Say Task A is configured to be assigned to Joe when it's activated. Whenthe
    task is actually activated, my client program receives an update messagefollowed
    by an assign message (both for that task).
    Okay, here's where it gets tricky. Say the workflow returns to Task Alater on
    in the same instance of the workflow. This time my client only gets anupdate
    JMS message. I have to account for this inconsistency in my code, whichis not
    good.
    Is this a bug, or is there a reason that this is behaving like this?

  • JMS Message Export/Import XML on command line

    I need a command line (JAVA or WLST) to reproduce the Weblogic consol JMS message export and import to migrate manually message from a queue to another (online without filestore).
    There is an entry on the Weblogic console that export one or all message to an XML format file and the import command to reload this XML file.
    any idea of a java code used by the console or a jython fonction ?

    The following might be enough to get you started:
    For scripting and tracing examples, see the July 29th and August 10th 2009 newsgroup post with subject "Example using of getMessage(s) with JMS error queues?" [ here | http://forums.oracle.com/forums/thread.jspa?messageID=3657916] and the June 10th 2009 newsgroup post with subject "JMSDestinationRuntimeMBean - possible STATE values " [ here | http://forums.oracle.com/forums/thread.jspa?messageID=3531603 ]. Also take a look at the +Sept 23 2009 newsgroup posts with subject "Enable JMS - Queue/Topic Trace on console"+ [ here | http://forums.oracle.com/forums/thread.jspa?messageID=3782486].
    +WARNING: Exporting too many messages at a time can cause out-of-memory errors.+
    Tom

  • Unzipping a gz file that's in a JMS Message

    Could anyone please help me figure out how to unzip a message from a JMS Message. I have tried all sorts of things and I just can't get it to work.
    Jeremy

    Hi I can just help you out how to extract file from
    zip format and hope it will help you out and i am
    giving you it by showing you one example.
    import java.util.*;
    import java.io.*;
    import java.text.*;
    import java.util.zip.*;
    public class sandyzip
         public static void main(String[] args)
         {     try{
                   Enumeration entries;
                   ZipFile zipFile;
                   ZipEntry entry =null;
                   byte[] buffer = new byte[10000];
                   int len;
                   InputStream in=null;
                   OutputStream zout=null;
    zipFile = new
    new ZipFile("D:\\JavaPractice\\04-04-2007data.zip");
                   System.out.println(zipFile);
                   entries = zipFile.entries();
                   System.out.println(entries);
    while(entries.hasMoreElements()) {
    ry = (ZipEntry)entries.nextElement();
                   in=zipFile.getInputStream(entry);
    zout=new BufferedOutputStream(new
    new
    FileOutputStream(""+"D:\\JavaPractice\\"+entry.getName
                   System.out.println("**************"+entry.getName()
                   System.out.println(zout);
                   while((len = in.read(buffer)) >= 0)
                   zout.write(buffer, 0, len);
                   System.out.println("Unzip done");
              catch (Exception ex) {
                   ex.printStackTrace();
    Hope it will server your purpose.
    Cheers
    Sandyand where did JMS fit into the equation?

Maybe you are looking for