|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Topic issue - Using ASF for JMS |
« View previous topic :: View next topic » |
Author |
Message
|
nayanan |
Posted: Thu May 09, 2002 8:25 am Post subject: |
|
|
Newbie
Joined: 08 May 2002 Posts: 5
|
We are utilizing the Application Server Facility defined by the JMS Specification and supported by MQSeries. To correctly use this facility, MQ Supplied class must communicate with user supplied classes. The following summary the ownership.
MQ/JMS provided implementation
------------------------------------------------------
javax.jms.ConnectionConsumer
javax.jms.Session
User provieded implementations
---------------------------------------------------
javax.jms.ServerSession
javax.jms.ServerSessionPool
We provide two implemenations for each interface for queue and topic connection consumers. respectively.
We successfully use the Queue ConnectionConsumer model and pools without any issues.
We were also successful in using the Topic ConnectionConsumer model and pool when a single TopicConnectionConsumer for a particular Topic was registered. The flow of control was
. public message on topic
- [MQ] Topic ConnectionConsumer detects message
- [MQ]Topic ConnectionConsumer call getServerSession on our TopicServerSessionPool
- [OUR] TopicServerSessionPool return a TopicServerSession
- [MQ] Topic ConnectionConsumer call getSever on TopicServerSession
- [OUR] Topic Server Session return the MQ TopicSession
- [MQ] Topic ConnectionConsumer loads the TopicSession with the message
- [MQ] Topic ConnectionConsumer calls start on TopicServerSession
- [OUR] TopicServerSession call run on MQ TopicSession (in another thread)
- [OUR] MessageHandler.onMessage() get called with the message
- WE ARE HAPPY
However, under situations we do not completely understand, when another Topic ConnectionConsumer connects to the same topic everything occurs fine EXCEPT for the calling of out MessageHandler.onMessage(). The MQ Topic ConnectionConsumer seems to detect the message, request a ServerSession from our pool and call start(), but our message handler is never invoked.
Any pointers, tips or suggestions ??
|
|
Back to top |
|
 |
prabuk |
Posted: Tue Mar 30, 2004 2:50 pm Post subject: |
|
|
 Novice
Joined: 14 Mar 2003 Posts: 19 Location: JerseyCity, NJ
|
Nayanan or anybody, I saw that latest MQ/JMS library allows for app server implementation of concurrent consuming messages. I have a question of how the ServerSession to be implemented, according to the JMS documentation -
Quote: |
ServerSession associates a thread with JMS Session. |
Theoriticaly a JMS session itself a separate thread isn't it. That's how it calls the application onMessage method automatically on message arrival (basically it polls (optimised) the queue for the message on a thread). My question is whether we need to create a another thread and associate the ServerSession, or just need to create ServerSession and pool them in ServerSessionPool. There after the ConnectionConsumer will take care of using the ServerSession from the Pool wheneevr necessary and release them when not necessary.
From application side we just have to code the onMessage method with concureency code handling, as the same code would be called by many sessions ( message listener threads).
Please answer my question and correct me if my understanding is correct.
Thanks for your help
-Prabu[/quote] |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|