Working with JMS Palettes In TibcoBW Process

Here, I would brief on JMS palettes used for connecting to Queues and Topics. Queues are for point-to-point communication model and Topics are for Publish and Subscribe model.
Lets first create a JMS connections using JMS Connection as shown below.
In JMS connection, configure the appropriate username and password details and then test connection to verify the connectivity.
Create a new process and drag and drop a JMS Queue Sender activity from JMS Palette. Lets send a simple text information to queue by passing a text data in JMS body as shown.
Configure the JMS connections and destination queue name in the configuration tab of JMS Queue Sender. Choose message type as text, as we are sending text messages to the queue.
Lets build another process that receives the message from the queue and logs the message. Bring a JMS Queue Receiver activity from JMS palette. This a starter activity.
In JMS Queue Receiver, configure the connection and destination queue. Mapping of JMS Queue receiver to WriteToLog is shown below.
From tester tab, run the process and Create a job for sender and immediate you notice, JMS queue receiver processes the message from queue.
Lets now, develop a publisher and subscriber process with JMS Topic Publisher and Subscriber. Create new publisher process, as shown below.
Here is the subscriber process, which receives the message and logs it using WriteToLog. Similarly, there is another subscriber process having same functionality.
Run and test the process. For every instance of publisher,two subscribers A and B are initiated as shown below.
Now, we will build process using JMS Requestor activity, activity can be used to both Topics and Queues activities.
Below screen shots show a processing invoking JMS Queue Requestor activity and there is implementation for using JMS Queue Receiver and Reply to JMS Message.
Run and verify the process as shown below.
Similar to queue requestor, below screen shot shows the topic requestor implementation.
The video demonstration is available on the Youtube, here is the embedded video.



No comments:

Post a Comment

Note: only a member of this blog may post a comment.