Microsoft Azure Service Bus - 40400:找不到端点

时间:2018-01-23 23:29:27

标签: .net windows azure azureservicebus servicebus

我有一个Azure Service Bus主题,我能够在本地发送和检索,但是在我们的VM环境中进行测试时会发生上述错误。有没有人遇到过这个问题?

消息使用的示例代码:

        try
        {
            while (!stopFlag)
            {
                BrokeredMessage msg = null;
                try
                {
                    msg = client.Receive();
                }
                catch (Exception x)
                {
                    continue;
                }
                if (msg == null)
                {
                    continue;
                }

                try
                {
                    Handler.handleMessage(msg);
                }
                catch (Exception x)
                {
                    EventLog.WriteEntry("Spently.Listener",
                        Handler.Name + " ERROR " + x.Message + " " + x.StackTrace, EventLogEntryType.Error);
                }
            }
        }
        finally
        {
            if (client != null)
            {
                client.Close();
                client = null;
            }
        }

1 个答案:

答案 0 :(得分:0)

看起来nuget管理我们的软件包存在问题。版本与我们的服务项目不匹配。