[rabbitmq-discuss] Fwd: a few json rpc questions
stammailbox at gmail.com
Mon Jul 18 10:04:03 BST 2011
I find a lot of assistance in your answers.
I do use the RPC the way you mentioned and multiple clients do connect.
but my problem is that sometimes - a new client cannot connect .
While investigating this problem I found that one of the server RPC queues
was deleted. and when the client tries to connect to it, it halts when
I have 2 RPC queues for different services/ I declare them both in the same
way - declaring both queues for the rpcserver with this line
(obviously giving different names in the first parameter for the different
But only the first queue is sometimes deleted.
I have tried to see if it happens when the last client is shut down but it
is not related.
1. When do you think it could happen?
2. Should I declare it in another way? Like changing the third parameter -
autodelete to false?
( though it should never be deleted because the server app is still holding
a handle to it, no?)
Any hints would be highly appreciated.
On Fri, Jul 15, 2011 at 12:27 PM, Emile Joubert <emile at rabbitmq.com> wrote:
> On 14/07/11 07:35, mysurf mail wrote:
> > Hi,
> > Can all the clients be configurated with the same queuename ("") and the
> > same routing key (the same for all)?
> There are two queues required for an RPC call over AMQP. The first is
> the work queue for the service. The request published by the RPC client
> needs to end up in this queue and be consumed by the RPC server. The
> second is the callback queue. This is declared by the RPC client and
> receives the reply from the RPC server.
> When multiple RPC clients are making use of the same RPC service then
> they should all use the same routing key so that all requests for that
> service go to the same work queue. This is called RPC_QUEUE_NAME in the
> relevant Java tutorial:
> When you make use of RpcClient in the Java client (see
> you will see each client declares its own callback queue, so these are
> not shared. If a queue is declared with an empty name then the server
> assigns a random name. (See the "Temporary Queues" explanation in the
> 3rd tutorial.) So even if it looks like all the clients are declaring
> the same queue named "", they are all using different callback queues.
> This is the recommended approach.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rabbitmq-discuss