ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » General IBM MQ Support » Trigger type First, Question

Post new topic  Reply to topic
 Trigger type First, Question « View previous topic :: View next topic » 
Author Message
ovasquez
PostPosted: Fri Aug 08, 2008 3:57 pm    Post subject: Trigger type First, Question Reply with quote

Centurion

Joined: 09 Dec 2005
Posts: 141
Location: Lima, Peru

IBM Documentation:

******************
Trigger interval (TRGITV)
Specifies the trigger time interval, expressed in milliseconds, for use with queues that have TRGTYPE(*FIRST) specified.


When the arrival of a message on a queue causes a trigger message to be put on the initiation queue, then any message that arrives on the same queue within the specified interval does not cause another trigger message to be put on the initiation queue.
¿?

The possible values are:

999999999
The trigger time interval is 999 999 999 milliseconds.
interval-value
Specify a value ranging from 0 through 999 999 999.
*******************

But is ok?, because when i put messages, all generated trigger messages.

INFO
*****
WMQ 6.0.2.24
s.o. Windows XP sp2
qmgr have TRGITV=999999999
queue have trigger on, and type first
**********
_________________
Oscar Vásquez Flores
Back to top
View user's profile Send private message Send e-mail
tkane
PostPosted: Fri Aug 08, 2008 7:20 pm    Post subject: Reply with quote

Voyager

Joined: 23 Dec 2002
Posts: 82
Location: Kansas City

trigint will control generating an EXTRA trigger message. Most of the time you don't need one. And that's what you probably see. Trigtype first is designed to trigger an application that will drain the queue. And if I remember my MQ Application Programming Class (it was in the 1990's), it triggers when the queue goes from empty to non-empty.
If for some reason you get a message on the queue and the triggered application didn't get the message off the queue. Then you'll be stuck with a message on the queue and no way to trigger it.

Trigint will get you out of that problem. It will generate an extra trigger message after trigint has expired.
Back to top
View user's profile Send private message
PeterPotkay
PostPosted: Sat Aug 09, 2008 6:59 am    Post subject: Reply with quote

Poobah

Joined: 15 May 2001
Posts: 7722

tkane wrote:
It will generate an extra trigger message after trigint has expired.

On z/OS as of MQ 6.0 it works this way. On distributed, you need Trigger Interval to Expire AND another message to be put,


ovasquez wrote:

But is ok?, because when i put messages, all generated trigger messages.

INFO
*****
WMQ 6.0.2.24
s.o. Windows XP sp2
qmgr have TRGITV=999999999
queue have trigger on, and type first
**********

Why do you say all generate trigger messages? How do you know more than one trigger message was generated?

If your app is written to pull just one message, close the queue, and end, and you put 10 messages and you are wondering why your app started 10 times, its a feature of MQ's Trigger On First. When a trigger on first q is closed and there are more that 0 messages on the queue, another trigger event will be generated by the QM automatically, assuming all other trigger events are satisfied. Trigger Interval does not come into play in this scenario.
_________________
Peter Potkay
Keep Calm and MQ On
Back to top
View user's profile Send private message
ovasquez
PostPosted: Mon Aug 11, 2008 7:26 am    Post subject: Reply with quote

Centurion

Joined: 09 Dec 2005
Posts: 141
Location: Lima, Peru

Quote:

Why do you say all generate trigger messages? How do you know more than one trigger message was generated?

because is necessary trigger message for running trigger application, or not?
QMGR put trigger message in init.q and trigger monitor get message off init.q, right?
this flow is ok for trigger type first?
1. Program A puts a message on an application queue which is enabled for triggering.
2. If the conditions for triggering are met, a trigger event occurs, and the queue manager
examines the process object referenced by the application queue. The process object
identifies the application to be started, viz Program B.
3. The queue manager creates a trigger message whose fields contain information copied
from certain attributes of the process object and the application queue. The queue
manager puts the trigger message on an initiation queue.
4. A long-running program called a trigger monitor gets the trigger message, examines its
contents, and ...
5. ... starts Program B, passing the entire trigger message as a parameter.
6. Program B opens the application queue and gets messages from it.[/quote]
_________________
Oscar Vásquez Flores
Back to top
View user's profile Send private message Send e-mail
sami.stormrage
PostPosted: Mon Aug 11, 2008 7:38 am    Post subject: Reply with quote

Disciple

Joined: 25 Jun 2008
Posts: 186
Location: Bangalore/Singapore

Read Peter's post carefully and then reply back.
_________________
*forgetting everything *
Back to top
View user's profile Send private message Yahoo Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General IBM MQ Support » Trigger type First, Question
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.