c# – RabbitMQ:没有指定的端点可达

我的rabbitmq应用程序在Windows 2012服务器上运行,我随机使用它来获取此错误.

Exception Type: RabbitMQ.Client.Exceptions.BrokerUnreachableException



None of the specified endpoints were reachable

   at RabbitMQ.Client.ConnectionFactory.CreateConnection()

   at Program.Main(String[] args)

Stream does not support writing.

   at System.IO.BufferedStream.EnsureCanWrite()

   at System.IO.BufferedStream.Write(Byte[] array, Int32 offset, Int32 count)

   at RabbitMQ.Client.Impl.SocketFrameHandler.SendHeader()

   at RabbitMQ.Client.Framing.Impl.Connection.StartAndTune()

   at RabbitMQ.Client.Framing.Impl.Connection.Open(Boolean insist)

   at RabbitMQ.Client.Framing.Impl.Connection..ctor(IConnectionFactory factory, Boolean insist, IFrameHandler frameHandler)

   at RabbitMQ.Client.Framing.Impl.ProtocolBase.CreateConnection(IConnectionFactory factory, Boolean insist, IFrameHandler frameHandler)

   at RabbitMQ.Client.ConnectionFactory.CreateConnection()

可能是随机连接失败的原因,并自动开始连接.

任何人都可以帮助我.

最佳答案
似乎有几种情况可以使“没有指定的端点可以访问”错误.

当RabbitMQ服务未运行,或RabbitMQ服务正在运行但处于错误状态时,以及当客户端无法连接时,我已经看到了这一点.用户无权访问它尝试连接的虚拟主机.

转载注明原文:c# – RabbitMQ:没有指定的端点可达 - 代码日志