9 Replies Latest reply on Apr 19, 2010 9:38 AM by jlentz

    Recommended Approach for Publishing to Topics in ESB 4.7?

    jlentz

      Running JBoss 5.1.0 GA with JBoss ESB 4.7

       

      I'm trying to use NotifyTopics to send a message from one JBossESB service to other JBossESB services. Initially, I'm starting with one subscriber.
      The message is successfully received by the subscriber, but the message payload is missing.  The JBoss ESB 4.7 Programmer's Guide states that NotifyTopic will translate the ESB message into a JMS message and publish the JMS message to the list of TOpics.  I am using a Gateway listener and ESB listener on the subscriber.  I expected the JMSMessage to be converted to an ESB message and for my payload to be found in the location where it was originally stored.  Is this a proper application of NotifyTopics?  If so, do you see anything amiss with my service setup?

       

      Publishing service jboss-esb.xml snippet:

       

      <service category="PublishService" name="publishData"
          description="publish data">
      <listeners>
        <jms-listener busidref="receiveStatusGwChannel" is-gateway="true" name="jmsResponseGwListener" />
        <jms-listener busidref="receiveStatusEsbChannel" name="jmsResponseEsbListener" />
      </listeners>
      <actions mep="OneWay">
        <action name="publishData" />
        <action name="notificationAction">   
          <property name="okMethod" value="notifyOK" />
          <property name="notification-details">
                <NotificationList type="ok">
              <target/>
            <target>
             <topic jndiName="topic/publish_data_gw"/>
            </target>   
          </NotificationList>
          </property>
        </action>
      </actions>
      </service>

       

      Subscriber service jboss-esb.xml snippet:
      <providers>
        <jms-provider connection-factory="ClusteredConnectionFactory" name="JBossMessaging">
          <jms-bus busid="applyAdjustmentsGwChannel">
          <jms-message-filter dest-name="topic/publish_data_gw" dest-type="TOPIC" />
          </jms-bus>
          <jms-bus busid="applyAdjustmentsEsbChannel">
              <jms-message-filter dest-name="queue/apply_adjustments_esb" dest-type="QUEUE" />
          </jms-bus>
        </jms-provider>
      </providers>
      <services>
        <service category="SubscribingService" name="subscribe"
          description="subscribe to topic and process data on message">
         <listeners>
           <jms-listener busidref="applyAdjustmentsGwChannel" is-gateway="true" name="jmsApplyAdjustmentsGwListener" />
           <jms-listener busidref="applyAdjustmentsEsbChannel" name="jmsApplyAdjustmentsEsbListener" />
         </listeners>
         <actions mep="RequestResponse">
           <action name="adjBusinessAction" />
         </actions>
        </service>
      </services>

       

      If this is not a proper application of NotifyTopics, what is the preferred approach to publish to a topic in JBoss ESB? 

       

      Any assistance would be most appreciated!

       

      Thanks,
      Jennifer