2 Replies Latest reply on May 19, 2009 12:15 PM by kurt steele

    Confusion over first Hello World quickstart documentation

    kurt steele Newbie

      I've successfully run the first quickstart and think I understand the flow. But the Getting Started 'sequence of events' section makes no sense to me. It says:

      1. ESB Unaware JMS Client endpoint puts an ESB Unaware Hello World
      Message into JMS Queue queue/quickstart_helloworld_Request_gw

      2. The JMS Gateway Listener receives the ESB Unaware message. The
      Gateways Job is to adapt this message by making it an ESB Aware Message
      for consumption by an ESB Aware Endpoint.

      this seems a bit strange since the client program SendJmsMessage manually creates the Message object BEFORE sending it to the queue. Here's the code:

      ObjectMessage tm = session.createObjectMessage(msg);

      I do understand that the message object is being created from text by a method on the QueueSession object.

      In addition, #2 states that the JMS Gateway Listener is creating the message object. How can this be if it entered the queue as a message object already?

      I also assumed:

      1. the JMS Queue connection was obtained from JBossMQ via JBossNS in the JBossAS

      2. the JMS Gateway Listener was something different inside the ESB. But I see that it is really the same queue as above.

      Can someone clarify, thanks.


        • 1. Re: Confusion over first Hello World quickstart documentatio
          Scott Dawson Apprentice

          There are two different types of messages used in the helloworld quickstart. The SendJMSMessage client creates a JMS message -- a javax.jms.Message. The JmsGatewayListener transforms the JMS message into an ESB message -- an org.jboss.soa.esb.message.Message -- and sends it on down the pipeline. The JMS message is defined by the JMS spec; it's ESB-unaware. The message that the JmsGatewayListener creates is ESB-specific.


          • 2. Re: Confusion over first Hello World quickstart documentatio
            kurt steele Newbie

            That helped, thanks. Related question:

            I am running ESB archive mode, as suggested in the Getting Started guide (ant deploy, ant runtest). The readme states:

            "A .esb package is self-contained and has queue definitions that it needs in the esb archive."

            ...so even though 'queue/quickstart_helloworld_Request_gw' is being looked up in the JAS naming service, the queue itself resides in 'Quickstart_helloworld.esb', inside the ESB.

            Why then do the architecture diagrams show the client sending messages to 'queue/quickstart_helloworld_Request_gw' residing in the JAS?

            Maybe I don't understand the relationship between JAS and ESB. Is the ESB normally deployed as a set of archives UNDER JAS? Why?