Author |
Message
|
ucbus1 |
Posted: Wed Apr 23, 2008 6:05 am Post subject: Design question |
|
|
Knight
Joined: 30 Jan 2002 Posts: 560
|
I have been tasked to develop a router application and would like to see best options.
Here are the requirements:
Application A and application B posts messages to QA1 and QB1. The router needs to read the queues
QA and QB and put the messages received in the queues to QC1 as and when messages are received
Queue QC2 is read by an outside application which I do not have contronl. Once the outside application
done with the processing, it posts the messages back to queue QD. My router application needs to read the
queue QD and decide whether the message needs to go to app A or app B and then send the messages to QA2 or QB2
depending on the application.
There is a contract between the outside app and our applications so that the outside application and our applications
have a common data part as part of the message load. Use the common data part to populate a flag that would let me know
which application has sent a particular message, so that the reply message/unsolicited message when received can be sent
to appropriate system.
Here is the schematic:
Quote: |
App A-->QA1---|
. |-Router-->QC1--- outside app
App B-->QB1---| |
Quote: |
. |--QA2-->App A
outside-app-->QC2---Router-- |
. |--QB2-- App B
|
1. Have a stand alone Java program to act as a router read the queues qa1 and qa2 at regular intervals
or
2. Have a MDB on Weblogic to listen to QA1,QB1 and QC2 to act as a router read the queues qa1 and qa2 at regular intervals
Which one is better? Have you come across similar situation? how to handle so that it can be scalable
Thanks |
|
Back to top |
|
 |
fjb_saper |
Posted: Wed Apr 23, 2008 3:27 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
You could as well just use multihop with a default route and a request reply pattern...
No inspection of message content...
Enjoy  _________________ MQ & Broker admin |
|
Back to top |
|
 |
ucbus1 |
Posted: Fri Apr 25, 2008 8:24 am Post subject: |
|
|
Knight
Joined: 30 Jan 2002 Posts: 560
|
fjb_saper wrote: |
You could as well just use multihop with a default route and a request reply pattern...
No inspection of message content...
Enjoy  |
Thanks. Could you please point a book/document that discusses the approach you have suggested?
Thanks |
|
Back to top |
|
 |
bower5932 |
Posted: Fri Apr 25, 2008 8:45 am Post subject: |
|
|
 Jedi Knight
Joined: 27 Aug 2001 Posts: 3023 Location: Dallas, TX, USA
|
I'm sure there is something in the Intercommunication Manual. |
|
Back to top |
|
 |
ucbus1 |
Posted: Thu May 01, 2008 6:16 am Post subject: |
|
|
Knight
Joined: 30 Jan 2002 Posts: 560
|
I have searched GOOGLE and intercommunication manual. But could not find a relevant answer. May be that I am searching with a wrong query. Please let me know if you have a any links for
Quote: |
You could as well just use multihop with a default route and a request reply pattern...
No inspection of message content... |
All:
I find this is a case for ESB. But the idea to install a separate product ESB( either as a open source product or IBM specific). Building an MDB option been out of picture now. So I would like to know if there is any application that can route the MQ messages. If some one has already built one such application, please share your ideas. More helpful if it is already there as open source. I am familiar with writing a program to get message and put messages. What I am looking for is a more generic solution which can be extended as needed. Please let me know. |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu May 01, 2008 6:20 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
|
Back to top |
|
 |
ucbus1 |
Posted: Thu May 01, 2008 9:11 am Post subject: |
|
|
Knight
Joined: 30 Jan 2002 Posts: 560
|
Thanks Jeff;
The document talks about hopping multiple QM. In my case it is different. I have one queue manager with multiple queues. Please see my initial post I can clarify further if needed.
Thanks |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu May 01, 2008 9:23 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Your original post asks "Which is better, a standalone Java program that does X or a Java message-driven-bean that runs in a server to do X".
My answer to this question is always "Message Broker is a better choice than either".
I may be a bit biased, however.
it's not clear, however, that you are thinking about this problem correctly?
It seems like you have two individual request/reply flows, that happen to pass through a single application. The two flows are QA1->(request)->QC1->(reply)->QB1, and QA2->(request)->QC1->(reply)->QB2. As a pure request/reply, there should be no need for "routing", as the ReplyToQ and ReplyToQmgr should handle the routing from QC1 to the appropriate QB* queue.
However, if these are not really request/reply flows, then your task is correct - this is a router pattern. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
ucbus1 |
Posted: Thu May 01, 2008 9:43 am Post subject: |
|
|
Knight
Joined: 30 Jan 2002 Posts: 560
|
Quote: |
if these are not really request/reply flows, then your task is correct - this is a router pattern |
Yes that is correct. My next question is has any one built a MQ router application so generic that one could use it . I think I am too lazy ( or may that I do not want to re-invent) |
|
Back to top |
|
 |
|