We're having trouble connecting to a RabbitMQ virtual host under mono. If we connect to the root virtual host (/) everything works fine. Any insight into what we might be doing wrong? We're using v1.6.0 client driver.<br>
<br>Thanks,<br>Bryan<br><br><br><br><br>[2009-10-05 08:57:04,516] [INFO ] Establishing Message Bus Connection<br>[2009-10-05 08:57:04,517] [INFO ] Protocol: 0-8<br>[2009-10-05 08:57:04,517] [INFO ] Host: 10.255.203.226<br>
[2009-10-05 08:57:04,518] [INFO ] Port: 5672<br>[2009-10-05 08:57:04,518] [INFO ] Virtual Host: /publisher<br><br>Unhandled Exception: None of the specified endpoints were reachable<br>Endpoints attempted:<br> endpoint=amqp-0-8://<a href="http://10.255.203.226:5672">10.255.203.226:5672</a>, attempts=1, outcome=The AMQP operation was interrupted: AMQP close-reason, initiated by Library, code=0, text="End of stream", classId=0, methodId=0, cause=System.IO.EndOfStreamException: Failed to read past end of stream.<br>
at System.IO.BinaryReader.ReadByte () [0x00047] in /home/bmurphy/src/mono/mcs/class/corlib/System.IO/BinaryReader.cs:293<br> at RabbitMQ.Client.Impl.Frame.ReadFrom (RabbitMQ.Util.NetworkBinaryReader reader) [0x00000]<br>
at RabbitMQ.Client.Impl.SocketFrameHandler_0_9.ReadFrame () [0x00000]<br> at RabbitMQ.Client.Impl.ConnectionBase.MainLoopIteration () [0x00000]<br> at RabbitMQ.Client.Impl.ConnectionBase.MainLoop () [0x00000]<br>Stack trace:<br>
at RabbitMQ.Client.ConnectionFactory.CreateConnection (Int32 maxRedirects, RabbitMQ.Client.AmqpTcpEndpoint[] endpoints) [0x00000]<br> at RabbitMQ.Client.ConnectionFactory.CreateConnection (RabbitMQ.Client.AmqpTcpEndpoint[] endpoints) [0x00000]<br>
at RabbitMQ.Client.ConnectionFactory.CreateConnection (IProtocol version, System.String hostName, Int32 portNumber) [0x00000]<br><br><br><br><br>rabbitmqctl status<br>Status of node 'rabbit@domU-12-31-39-01-C4-14' ...<br>
[{running_applications,[{rabbit,"RabbitMQ","1.6.0"},<br> {mnesia,"MNESIA CXC 138 12","4.4.3"},<br> {os_mon,"CPO CXC 138 46","2.1.6"},<br>
{sasl,"SASL CXC 138 11","2.1.5.3"},<br> {stdlib,"ERTS CXC 138 10","1.15.3"},<br> {kernel,"ERTS CXC 138 10","2.12.3"}]},<br>
{nodes,['rabbit@domU-12-31-39-01-C4-14']},<br> {running_nodes,['rabbit@domU-12-31-39-01-C4-14']}]<br>...done.<br><br><br><br><br>rabbitmqctl list_vhosts<br>Listing vhosts ...<br>/<br>/publisher<br>...done.<br>
<br><br><br><br>mono --version<br>Mono JIT compiler version 2.5 (/trunk/mono r142445 Tue Sep 22 18:25:08 PDT 2009)<br>Copyright (C) 2002-2008 Novell, Inc and Contributors. <a href="http://www.mono-project.com">www.mono-project.com</a><br>
TLS: __thread<br> GC: Included Boehm (with typed GC and Parallel Mark)<br> SIGSEGV: altstack<br> Notifications: epoll<br> Architecture: x86<br> Disabled: none<br>
<br><br><br><br>Relevant code:<br><br> using RabbitMQConnectionFactory = RabbitMQ.Client.ConnectionFactory;<br><br> public ConnectionFactory(MessageBusConnectionConfig config)<br> {<br> Contract.ArgumentNotNull("config", config);<br>
this.Config = config;<br> this.ProviderConnectionFactory = new RabbitMQConnectionFactory();<br><br> if (!string.IsNullOrEmpty(config.VirtualHost))<br> this.ProviderConnectionFactory.Parameters.VirtualHost = config.VirtualHost;<br>
}<br><br> public IConnection GetConnection()<br> {<br> if (_log.IsInfoEnabled)<br> {<br> _log.Info("Establishing Message Bus Connection");<br> _log.Info("Protocol: " + Protocols.DefaultProtocol);<br>
_log.Info("Host: " + this.Config.ServerName);<br> _log.Info("Port: " + (this.Config.ServerPort ?? 5672));<br> _log.Info("Virtual Host: " + this.ProviderConnectionFactory.Parameters.VirtualHost);<br>
}<br><br> return new Connection(<br> this.ProviderConnectionFactory.CreateConnection(<br> Protocols.DefaultProtocol,<br> this.Config.ServerName,<br>
this.Config.ServerPort ?? 5672<br> ));<br> }<br><br>