Posted: Thu May 11, 2006 9:16 am Post subject: Finding the MQ Queue depth using ESQL
Apprentice
Joined: 30 Jun 2005 Posts: 37
Hi,
My Environment is WMB v6.0,WMQ v6.0,Broker on AIX.
I have a situation where i will get no. of messages on input queue of a message flow and i need to read all those messages in a single execution of flow and insert into a database.
For this i need to find the depth of input queue as i don't know how many messages will be put on input queue.Is there any way to find the depth a queue using ESQL but not with JAVA COMPUTE NODE or JAVA PROCEDURE.
Every time an MQ message appears on a queue monitored by an MQInput node, a new instance of the message flow is started up by that message.
You can use the MQGet node to load more than one message into a single instance of a flow, if you use some looping and know what you are doing.
In no case is it ever good MQ design or Message Broker design to ask for the current depth of a queue and then loop that many times getting messsages.
You should re-examine your requirements very carefully. It sounds like you are going down a road that is poorly thought out both from an MQ architectural standpoint and from a Broker architectural standpoint.
Among other things, why exactly do you have to read "all those messages" and do a single insert? Why can't you do an insert for each of those messages? _________________ I am *not* the model of the modern major general.
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