Author |
Message
|
MQFard |
Posted: Mon Mar 01, 2010 9:34 am Post subject: AMQSSET or MQSET |
|
|
Novice
Joined: 07 Oct 2004 Posts: 17 Location: VSP.COM
|
Gentleman and/or Ladies:
We have successfully tested MQ Depth triggering using ESP. As you know when triggering occurs MQ Inhibits the queue GET’s. I have been reviewing the manuals, searching MQSeries and the Web and cannot find any information on how to automate the “Enable” process for the queue GET’s when the ESP job has completed. I have been testing with the AMQSSET or MQSET commands and can’t seem to make it work. The documentation is a little ambiguous, for example:
MQSET: Use this call to set some of the attributes of a queue. You cannot set the
attributes of other types of object.
Setting queue attributes: You can set only the following queue attributes using the MQSET call:
InhibitGet (but not for remote queues), DistList, InhibitPut, TriggerControl, TriggerType, TriggerDepth, TriggerMsgPriority, TriggerData
MQOO_SET
Open queue to set attributes.
The queue is opened for use with subsequent MQSET calls.
This option is valid for all types of queue other than distribution lists.
It is not valid if ObjectQMgrName is the name of a local definition of a
remote queue; this is true even if the value of the RemoteQMgrName
attribute in the local definition of a remote queue used for
queue-manager aliasing is the name of the local queue manager.
Syntax: MQSET (Hconn, Hobj, SelectorCount, Selectors, IntAttrCount,
IntAttrs, CharAttrLength, CharAttrs, CompCode, Reason)
Using the MQSET call amqsseta amqmsetx amqisetx amqvsetx amqsset amqssetc
For example here it shows UNIX sample programs but no examples!
http://publib.boulder.ibm.com/infocenter/wmqv6/v6r0/index.jsp?topic=/com.ibm.mq.csqzal.doc/fg17010_.htm
And so on and so forth!
My question is that I have not found any code example or command examples for AMQSSET in DOS on Windows 2003 or application code in JAVA or C.
For example this is what I receive from a DOS command:
D:\>amqsset VSP.TEST
Sample AMQSSETA start
Invalid input trigger message provided
VSP.TEST = queue name
I cannot find example of valid input trigger – what’s the syntax or sample code?
All we want to do is automate the GET’s parameter on a queue. Does anyone have any ideas’ or I’m I truly being ignorant?  _________________ To Fard
WebSphere MQ Administrator |
|
Back to top |
|
 |
Vitor |
Posted: Mon Mar 01, 2010 9:46 am Post subject: Re: AMQSSET or MQSET |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
MQFard wrote: |
As you know when triggering occurs MQ Inhibits the queue GET’s. |
No it doesn't! That must be an ESP thing (whatever ESP happens to be)
What does happen (and why your question is still valid) is that the depth trigger will disable once it's been fired, and must be re-enabled by MQSET or equivalent.
MQFard wrote: |
I have been reviewing the manuals, searching MQSeries and the Web and cannot find any information on how to automate the “Enable” process for the queue GET’s when the ESP job has completed. |
Ok, still not getting this ESP thing. Perhaps I call it something different? Post a link to a manual & see if it jogs my memory.
MQFard wrote: |
My question is that I have not found any code example or command examples for AMQSSET in DOS on Windows 2003 or application code in JAVA or C. |
The sample code should work the same on Unix, Windows or DOS if compiled properly. Failing that, there's a link to sample code (including Windows) at the top of this page.
MQFard wrote: |
For example this is what I receive from a DOS command:
D:\>amqsset VSP.TEST
Sample AMQSSETA start
Invalid input trigger message provided
VSP.TEST = queue name |
Yes, because that sample isn't written to run like that.
MQFard wrote: |
I cannot find example of valid input trigger – what’s the syntax or sample code? |
The sample (including the one you're using) is supplied with the product. See also the link I mentioned.
MQFard wrote: |
All we want to do is automate the GET’s parameter on a queue. Does anyone have any ideas’ or I’m I truly being ignorant?  |
I remain unconvinced it's the GET parameter you need to change. But in a TRIGGER(DEPTH) typically whatever application resolves the depth situatation by reading the messages issues an MQSET to reset the trigger. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
MQFard |
Posted: Mon Mar 01, 2010 11:57 am Post subject: I'm bad!! |
|
|
Novice
Joined: 07 Oct 2004 Posts: 17 Location: VSP.COM
|
Thanks for your response – I have been working on so many things that I got my issues mixed up. Please disregard anything I said about inhibiting the GET’s, that is not what is happening. Sorry for the confusion.
Execution Scheduling Processor (ESP) is CA’s Mainframe scheduling software. We have an application running on AIX that feeds messages to a queue that lives on a WIN2003 server. When the queue hits the triggered depth, it triggers a process that submits an ESP job on the Mainframe or zOS. When the queue is triggered the trigger control is set to off. When the Job ends we need to set the trigger control to on. This is the issue.
 _________________ To Fard
WebSphere MQ Administrator |
|
Back to top |
|
 |
Vitor |
Posted: Mon Mar 01, 2010 12:02 pm Post subject: Re: I'm bad!! |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
MQFard wrote: |
When the queue hits the triggered depth, it triggers a process that submits an ESP job on the Mainframe or zOS. When the queue is triggered the trigger control is set to off. When the Job ends we need to set the trigger control to on. This is the issue.
 |
Why not have the job on trigger first, and process the messages as they arrive?
As I indicated above, the mainframe application reading the queue should issue an MQSET call in this instance to "signal" that the queue depth has been noted. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
bruce2359 |
Posted: Mon Mar 01, 2010 2:00 pm Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
Quote: |
When the queue hits the triggered depth, it triggers a process ... |
The process that gets triggered that gets the application messages from the queue and sends them to the mainframe needs to be modified to do an MQSET to enable triggering. Why?
It is well-documented (WMQ Application Programming Reference) that when a queue is triggered with TRIGTYPE(DEPTH), triggering is turned off; and must be turned on by an application or by a system admin. Why?
The assumption here is that the application understands the business requirement for the depth of the queue. For example: if it takes 5 messages to comprise a business transaction, TRIGTYPE(DEPTH) may make sense. At 5 messages, the trigger fires and triggering is turned off. If triggering was left on, the next 1 message (not 5) would incorrectly trigger the consuming application.
An alternative to depth (in a prior post) is to trigger(first), and let the application do an MQGET with WAIT (and waitinterval), and continuously watch for messages to arrive. TRIGTYPE(FIRST) usually satisfies most triggering requirements. _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
MQFard |
Posted: Mon Mar 01, 2010 2:12 pm Post subject: An alternative to depth is to trigger(first) |
|
|
Novice
Joined: 07 Oct 2004 Posts: 17 Location: VSP.COM
|
Yes, I have read this documentation and here is the issue. It is presently set to trigger first with an application doing an MQGET. The issue is that we are moving millions of messages through this queue and were trying to limit the job execution to keep the spool down on the Mainframe. If we limit job execution to a depth of 100,000 messages then we only have one job on the spool, not 100,000 jobs.
Again all I want to do is find some code that will change trigger control back to on after the ESP job ends. Any ideas? _________________ To Fard
WebSphere MQ Administrator |
|
Back to top |
|
 |
bruce2359 |
Posted: Mon Mar 01, 2010 2:27 pm Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
Quote: |
The issue is that we are moving millions of messages through this queue and we're trying to limit the job execution to keep the spool down on the Mainframe. |
Are you saying that the you print sysout from millions of batch jobs? Does anyone really look at all of this paper?
Or are you saying that the job output sits in the queue, and someone/something manually purges them? If this is the case, use a jobclass that discards the sysout.
Disk space is a cheap resource; and adding spool space on z/OS is a snap.
I can't imagine that your company has a business requirement to minimize spool space. _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
bruce2359 |
Posted: Mon Mar 01, 2010 2:40 pm Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
Quote: |
Execution Scheduling Processor (ESP) is CA’s Mainframe scheduling software. |
So far, so good.
Quote: |
We have an application running on AIX that feeds messages to a queue that lives on a WIN2003 server. When the queue hits the triggered depth, it triggers a process that submits an ESP job on the Mainframe or zOS. |
Again, so far, so good.
Quote: |
When the queue is triggered the trigger control is set to off. |
Working as designed and documented.
Quote: |
When the Job ends we need to set the trigger control to on. |
Do you mean when the mainframe job ends? Isn't the triggered queue on the WIN2003 server qmgr? Or do you mean when the triggered job on WIN2003 ends?
(Note my confusion here.)
If you need to turn triggering on for the queue on WIN2003 server qmgr, write an application that
1. connects to the qmgr
2. opens the queue for SET
3. MQSETs triggering on
4. closes the queue
5. disconnects from the qmgr
Quote: |
This is the issue. |
Please correct me if I've misunderstood your issue. _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
MQFard |
Posted: Mon Mar 01, 2010 2:42 pm Post subject: |
|
|
Novice
Joined: 07 Oct 2004 Posts: 17 Location: VSP.COM
|
Thanks that's what we will do! _________________ To Fard
WebSphere MQ Administrator |
|
Back to top |
|
 |
Vitor |
Posted: Mon Mar 01, 2010 2:51 pm Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
MQFard wrote: |
Thanks that's what we will do! |
I thought I suggested that a few posts back....  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
bruce2359 |
Posted: Mon Mar 01, 2010 2:55 pm Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
(I was paraphrasing...) _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
Vitor |
Posted: Mon Mar 01, 2010 3:10 pm Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
bruce2359 wrote: |
(I was paraphrasing...) |
I was just checking. It's been an odd day.....  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
bruce2359 |
Posted: Mon Mar 01, 2010 3:51 pm Post subject: |
|
|
 Poobah
Joined: 05 Jan 2008 Posts: 9469 Location: US: west coast, almost. Otherwise, enroute.
|
Perhaps my post sounded more authoritative or worldly... _________________ I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live. |
|
Back to top |
|
 |
Vitor |
Posted: Mon Mar 01, 2010 6:11 pm Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
bruce2359 wrote: |
Perhaps my post sounded more authoritative or worldly... |
And so starts my slow decline, which ends at the St Barnard's Home for The Bewildered, sitting in the sun room giving the potted plant advice on building an ESB.  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
fjb_saper |
Posted: Mon Mar 01, 2010 7:38 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Vitor wrote: |
bruce2359 wrote: |
Perhaps my post sounded more authoritative or worldly... |
And so starts my slow decline, which ends at the St Barnard's Home for The Bewildered, sitting in the sun room giving the potted plant advice on building an ESB.  |
What are you babbling about a potted plant? This was a former rocket scientist!  _________________ MQ & Broker admin |
|
Back to top |
|
 |
|