Implementing a JMS Service that Returns Information Based on Zip Codes
This sample uses the JMS service to return information about a city given a zip code. The sample also provides the distance between two cities as defined by their zip codes.
Before you begin
- TIBCO Enterprise Message Service must be running.
- Procedure
- In the samples directory, select
and double-click
tibco.bw.sample.binding.soap.jms.ZipCodeLookup.
For more information, see Accesing Samples.
- In Project Explorer expand the tibco.bw.sample.binding.soap.jms.ZipCodeLookup project.
- Fully expand the Processes directory and double-click ZipInfoService.bwp.
- Verify your TIBCO Enterprise Message Service connection.
- Fully expand the Resources directory.
- Double-click JMSConnectionResource.jmsConnResource.
- In the Basic Configuration dialog, click the Test Connection button to verify the connection.
- Click .
- At the left hand tree of Debug Configuration wizard, expand BusinessWorks Application and select BWApplication.
- Click the Applications tab and then click the Deselect All button if you have multiple applications. Select the checkbox next to tibco.bw.sample.binding.soap.jms.ZipCodeLookup.application.
- Click
Debug.
This runs the sample in Debug mode.
- In
TIBCO Business Studio for BusinessWorks, click the Terminate icon
to stop the process.
ResultFor the getCityInfo service, information corresponding to the zip code defined in the zip field is returned. The default value is 61801, which returns information about Urbana, IL.
For the getCityDistance service, information corresponding to the distance between two zip codes is returned. The default values are 61801 for Urbana IL and 61820 for Champaign IL.
Subtopics