You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm change a local process to use activemq via stomp.
There is a process that happens when I enqueue a message that I need to be able to check the status of. I have verified but manually sending a message to the input queue, that if I set a correlation id, that it kept for the reply which is on an output queue. So where there might be lots of messages I can tie these together.
The problem is, my program will be stateless. It will be run upon a new file arriving, and that file name will be given to the input queue, and if there are problems a message will end up on the output queue within a second. I would like for my program to wait for a response on the output queue, but only where the correlation ids match....so if there are other messages on the queue I'd like to ignore those as another instance of the program is most likely waiting for that.
Is this possible? or by using unique client names, or any other property where my subscription can only wait for messages from itself.
I can't alter the queue names as they are used by an external process.
I have by using your tests, figure out how to get my method to wait for a response message via listener.wait_for_message - and for 90% of the time, the number of messages are slow enough that this shouldn't be an issue. But I'd prefer to process any messages in the queue, and if not my correlation id, not pull them off the queue.
The text was updated successfully, but these errors were encountered:
I think I managed to work it out. But setting subscribe to client ack. And I can test correlation id on each message. If they don't match I can nack the message else ack it, and process it.
I'm change a local process to use activemq via stomp.
There is a process that happens when I enqueue a message that I need to be able to check the status of. I have verified but manually sending a message to the input queue, that if I set a correlation id, that it kept for the reply which is on an output queue. So where there might be lots of messages I can tie these together.
The problem is, my program will be stateless. It will be run upon a new file arriving, and that file name will be given to the input queue, and if there are problems a message will end up on the output queue within a second. I would like for my program to wait for a response on the output queue, but only where the correlation ids match....so if there are other messages on the queue I'd like to ignore those as another instance of the program is most likely waiting for that.
Is this possible? or by using unique client names, or any other property where my subscription can only wait for messages from itself.
I can't alter the queue names as they are used by an external process.
I have by using your tests, figure out how to get my method to wait for a response message via listener.wait_for_message - and for 90% of the time, the number of messages are slow enough that this shouldn't be an issue. But I'd prefer to process any messages in the queue, and if not my correlation id, not pull them off the queue.
The text was updated successfully, but these errors were encountered: