[rabbitmq-discuss] amqp_login -> AMQP_RESPONSE_NONE (RabbitMQ C Client)

Matthew Sackman matthew at lshift.net
Thu Jan 28 11:49:24 GMT 2010


Hi Frank,

The RabbitMQ C client was written by Tony. He's currently on leave but
should be able to help out again soon. None of the rest of us have ever
looked at the C client and it is marked highly experimental.

On Mon, Jan 25, 2010 at 02:39:21PM +0100, Frank Goenninger - Consequor Consulting AG wrote:
> Being new to RabbitMQ I am using the C client to write an abstraction  
> layer on top of RabbitMQ. I am trying to do an amqp_login call but  
> always get a AMQP_RESPONSE_NONE in amqp_rpc_reply.
> 
> Is this normal, i.e. this is NOT an error? Do I get a server error if  
> the login fails or do I get this AMQP_RESPONSE_NONE if the login fails?

We were hoping some of the other users of the C client might be able to
help out with this one. Digging around the Java client though reveals
the following pattern.

The server will send a Start, the client replies with a StartOK which
contains the username and password. Upon sending that, you should get
back a connection tune method back from the server, if all is well.

Now, if the user details are wrong, the server will shut the connection.
So I guess, unless there's something smarted going on in the C client,
simply checking that the connection is still open might work, but in
general, if you get as far as receiving the connection.tune method, you
can trust that the authentication details you provided have been
accepted.

I hope that's of some help.

Matthew




More information about the rabbitmq-discuss mailing list