Using a SOAP Connection to Publish Messages to Multiple Endpoints

This sample shows how to publish messages to multiple endpoints over HTTP and JMS.

Prerequisites

TIBCO Enterprise Message Service must be running.

Procedure

  1. In the samples directory, select binding > soap > http > HTTPJMSMultiEndpoint and double-click tibco.bw.sample.binding.soap.http.HTTPJMSMultiEndpoint. For more information, see Accessing Samples.
  2. In Project Explorer expand the tibco.bw.sample.binding.soap.http.HTTPJMSMultiEndpoint project.
  3. Set the default ApplicationProfile to match the OS you are running on. For more information, see Setting the Default Application Profile.
  4. Verify your TIBCO Enterprise Message Service connection. To verify:
    1. Fully expand the Resources directory.
    2. Double-click JMSConnectionResource.jmsConnResource.
    3. Click the Test Connection button to verify the connection.
  5. Fully expand the Processes directory and double-click TestService.bwp.
  6. Click Run > Debug Configurations.
  7. At the left hand tree of the Debug Configuration wizard, expand BusinessWorks Application and select BWApplication.
  8. Click the Applications tab and then click the Deselect All button if you have multiple applications. Select the check box next to tibco.bw.sample.binding.soap.http.HTTPJMSMultiEndpoint.application.

  9. Click Debug.
    This executes the sample in Debug mode.
  10. Click the Terminate icon to stop the process.

Result

The file provided for the OUTPUT_FILE property is written with the following content:

JMS : Output of getCityInfo : 61801 Urbana Illinois Urbana, Illinois, United States 40.11 88.207

JMS : Output of getCityDistance : Distance between two cities is : 4 miles. 61801 61820 Urbana Champaign Illinois Illinois Urbana, Illinois, United States Champaign, Illinois, United States

HTTP : Output of getCityInfo : 61801 Urbana Illinois Urbana, Illinois, United States 40.11 88.207

HTTP : Output of getCityDistance : Distance between two cities is : 4 miles. 61801 61820 Urbana Champaign Illinois Illinois Urbana, Illinois, United States Champaign, Illinois, United States