-
1. Re: Is there any way of preventing anyone to create any new consumers on the queue, while still service existing consumers?
clebert.suconic Nov 5, 2012 4:49 PM (in response to sudovenko)With durable subscriptions, you can set the clientID, what will only allow a single connection with that ID.
-
2. Re: Is there any way of preventing anyone to create any new consumers on the queue, while still service existing consumers?
jbertram Nov 5, 2012 4:54 PM (in response to sudovenko)1 of 1 people found this helpfulThat's an interesting idea, Steve. To my knowledge, there is no way to do this currently.
I'm curious what your use-case for this is.
-
3. Re: Is there any way of preventing anyone to create any new consumers on the queue, while still service existing consumers?
sudovenko Nov 6, 2012 11:37 AM (in response to jbertram)Thank you Justin and Clebert for your replies.
The use case is the following.
I have multiple client communitacting to the server, hornetq is used as a transport, it doesn't know what it carries.
all communication is non durable and async.
1. client comes in and gets from the server a session id (that later used as replyto address) using clientRequestor
2. then client creates a producer to server addres,
3 then client creates a temporary queue on the address of session id and creates a consumer.
4. from that moment on client never uses clientRequestor, all communication goes through producer/consumer in async manner. every message to server supplied with the message id and replyto address(session id).
I want to limit the number of queues and consumers that can be registered on the address to one and only.
So far I cannot find any way to do that.
1. I can workaround creation of the queue, by passing this function tho the server, which is not as clean but that is the only way I see I can limit the number of the queues on the address.
2. Even with the workaround above, I do not know any way to limit the number of consumers that can be registered, so I cannot 100% guarantee that there is only one listener to the server's response.
I just started using hornetq recently, thus, I would appreciate any helpful input form more experienced peers.
Best regards,
Steve