|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Put messages to a queue at regular intervals |
« View previous topic :: View next topic » |
Author |
Message
|
anya_tannia |
Posted: Thu May 26, 2016 9:12 pm Post subject: Put messages to a queue at regular intervals |
|
|
Newbie
Joined: 26 May 2016 Posts: 3
|
I am dynamically providing the queuename to a GET node which am using for clearing messages. I need to now clear the queue at regular time intervals. Is there a way to automatically put the message containing queuename in the input queue at regular intervals?
I am new to wmb..Sorry if its a silly question |
|
Back to top |
|
 |
maurito |
Posted: Thu May 26, 2016 9:41 pm Post subject: Re: Put messages to a queue at regular intervals |
|
|
Partisan
Joined: 17 Apr 2014 Posts: 358
|
anya_tannia wrote: |
I am dynamically providing the queuename to a GET node which am using for clearing messages. I need to now clear the queue at regular time intervals. Is there a way to automatically put the message containing queuename in the input queue at regular intervals?
I am new to wmb..Sorry if its a silly question |
look at the timer nodes in the Knowledge Center. There is also a DevelopmentWorks article with examples. |
|
Back to top |
|
 |
zpat |
Posted: Thu May 26, 2016 11:39 pm Post subject: |
|
|
 Jedi Council
Joined: 19 May 2001 Posts: 5866 Location: UK
|
This suggests that you are dealing with symptoms rather than cause.
Why not prevent the unwanted messages being put to the queue?
Why not put the messages with expiry values (or use MQ v8 to force expiry on that queue)?
If you prefer to maintain your schedule outside the broker, you can use your scheduling product to run a script (which puts to the queue) at intervals, or just use the script to clear the queue directly (with commands like q or qload).
Last edited by zpat on Fri May 27, 2016 6:11 am; edited 1 time in total |
|
Back to top |
|
 |
mqjeff |
Posted: Fri May 27, 2016 3:59 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
So you have a single flow. It reads from different queues, based on the message it's given - where the message that starts it contains the name of the queue.
Are you doing anything with the messages on this queue? or just removing them?
If you're processing these messages, you can hopefully use the data in them to allow DFDL/XMLNSC to know what kind of message it is, and allow your code to know how to process ti.
Then you could read from only *one* queue.
If you're just looking to clear them, this is a job much better suited for a modified version of amqsgetc and a script or other triggered OS level job.
Also, yes, expiry is a really good idea. Your method of clearing messages only works when the rate at which you are reading messages is faster than the rate at which you are putting messages... _________________ chmod -R ugo-wx / |
|
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
|
|
|
|