I've been doing a bit of testing on the .NET and java clients, and got a bit confused about the current behavior around virtual host names and connection urls.
Basically, my question is this: When sending a connection.open command, does a virtual host name of "/test" supposed to be interpreted exactly as "test" (i.e. ignore the leading slash)? I looked through the AMQP spec and didn't find anything that explicitly stated anything to this effect (closest I found was the characters allowed in a virtual host name, of which '/' is certainly one). What seems to me that it's happening is this: In both the Java and .NET Client, creating a connection from a connection URL will always cause the virtual host to be specified with the leading '/' (i.e. "/test"). As far as I can see, the Java broker, at least, treats "/test" and "test" as if they meant the same (explicit check for this is ConnectionOpenMethodHandler, line 65). However, other AMQP brokers certainly do not (like RabbitMQ, for example). So, if "/test" and "test" are not supposed to be treated as equivalent, then we have two bugs here: one in the broker, that treats them the same, and one in the client, that incorrectly parses connection URLs. If they are allowed to be treated the same, then I'd still say the bug in the client still exists. Any opinions? Tomas Restrepo http://www.winterdom.com/weblog/
