Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

about Listeners

Status
Not open for further replies.

lecmns

Programmer
Sep 11, 2001
19
0
0
IN
folks..

it's about listeners..

how do we set time out for a message listener?
can we do that?
if not, will a message listener ever time out?

I want one message listener getting any message from a queue but then routing it to different message processors. Hope you got my requirement. So, I don't want this master listener to time out at any cost.

another scenario is that I want a listener to look for one particular message and if that's not found in say 1 hour, I want this message listener to time out.

does that happen automatically? How do I go about doing that?

folks, help me out..

thankx in advance
MNS
lecMns
B'lore
 
Some clarification of terminology here - a 'Listener' is an MQ process which waits for incoming connection requests from sender-type channels and starts the corresponding receiver channel process on the local machine. You generally want this to run permanently (unless your OS supplies inetd or alternative such as APPC) and, apart from specifying the TCP port to listen to you don't ever touch it.

From your description however, I think you are referring to a trigger monitor (TM). This can either run permanently or be started as a consequence of messages arriving onto a target queue. The trigger monitor then typically processes the messages itself or starts another program to process the messages.

Once your trigger monitor has been started it would typically MQGET the message(s) from the input queue in a loop until there are none left. To keep the TM active for one hour say, simply specify a wait interval of 60 minutes in the MQGET. If further messages arrive in this time they will be processed otherwise the TM will end and can be started again by the arrival of new messages.

Hope this helps,
Paul
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top