【发布时间】:2016-03-10 10:06:34
【问题描述】:
我们在项目中使用 Azure ServiceBus 将消息传递给不同的组件。目前我们有 7 个主题和这些主题中的 45 个订阅。 最近我们开始收到 Microsoft.ServiceBus.Messaging.QuotaExceededException: ConnectionsQuotaExceeded for namespace。
根据Azure ServiceBus Quotas and Limits,每个命名空间的并发连接数限制为 1000。我们绝对不会超过 200。有人遇到类似问题吗?
下面是堆栈跟踪:
Microsoft.ServiceBus.Messaging.QuotaExceededException:命名空间 testtrlsb 的 ConnectionsQuotaExceeded。 d2759061-962d-436b-980d-1b901019d569_G51 ---> System.ServiceModel.FaultException1[System.ServiceModel.ExceptionDetail]: ConnectionsQuotaExceeded for namespace testtrlsb. d2759061-962d-436b-980d-1b901019d569_G51Server stack trace:
at Microsoft.ServiceBus.Messaging.Sbmp.DuplexRequestBindingElement.DuplexRequestSessionChannel.ThrowIfFaultMessage(Message wcfMessage)
at Microsoft.ServiceBus.Messaging.Sbmp.DuplexRequestBindingElement.DuplexRequestSessionChannel.HandleMessageReceived(IAsyncResult result)Exception rethrown at[0]:
at Microsoft.ServiceBus.Common.AsyncResult.End[TAsyncResult](IAsyncResult result)
at Microsoft.ServiceBus.Messaging.Sbmp.DuplexRequestBindingElement.DuplexRequestSessionChannel.DuplexCorrelationAsyncResult.End(IAsyncResult result)
at Microsoft.ServiceBus.Messaging.Channels.ReconnectBindingElement.ReconnectChannelFactory1.RequestSessionChannel.RequestAsyncResult.b__4(RequestAsyncResult thisPtr, IAsyncResult r)
在 Microsoft.ServiceBus.Messaging.IteratorAsyncResult1.StepCallback(IAsyncResult result)Exception rethrown at[1]:
at Microsoft.ServiceBus.Common.AsyncResult.End[TAsyncResult](IAsyncResult result)
at Microsoft.ServiceBus.Messaging.Channels.ReconnectBindingElement.ReconnectChannelFactory1.RequestSessionChannel.EndRequest(IAsyncResult 结果)
在 Microsoft.ServiceBus.Messaging.Sbmp.RedirectBindingElement.RedirectContainerChannelFactory1.RedirectContainerSessionChannel.RequestAsyncResult.<>c__DisplayClass17.<GetAsyncSteps>b__a(RequestAsyncResult thisPtr, IAsyncResult r)
at Microsoft.ServiceBus.Messaging.IteratorAsyncResult1.StepCallback(IAsyncResult 结果)在 [2] 处重新抛出异常:
在 Microsoft.ServiceBus.Common.AsyncResult.End[TAsyncResult](IAsyncResult 结果)
在 Microsoft.ServiceBus.Messaging.Sbmp.RedirectBindingElement.RedirectContainerChannelFactory1.RedirectContainerSessionChannel.EndRequest(IAsyncResult result)
at Microsoft.ServiceBus.Messaging.Channels.ReconnectBindingElement.ReconnectChannelFactory1.RequestSessionChannel.RequestAsyncResult.b__4(RequestAsyncResult thisPtr,IAsyncResult r)
在 Microsoft.ServiceBus.Messaging.IteratorAsyncResult1.StepCallback(IAsyncResult result)Exception rethrown at[3]:
at Microsoft.ServiceBus.Common.AsyncResult.End[TAsyncResult](IAsyncResult result)
at Microsoft.ServiceBus.Messaging.Channels.ReconnectBindingElement.ReconnectChannelFactory1.RequestSessionChannel.EndRequest(IAsyncResult 结果)
在 Microsoft.ServiceBus.Messaging.Sbmp.SbmpMessageReceiver.EndReceiveCommand(IAsyncResult 结果,IEnumerable1& messages) --- End of inner exception stack trace ---
at Microsoft.ServiceBus.Common.AsyncResult.End[TAsyncResult](IAsyncResult result)
at Microsoft.ServiceBus.Messaging.MessageReceiver.RetryReceiveAsyncResult.TryReceiveEnd(IAsyncResult r, IEnumerable1& 消息)
在 Microsoft.ServiceBus.Messaging.MessageReceiver.EndReceive(IAsyncResult 结果)
在 System.Threading.Tasks.TaskFactory1.FromAsyncCoreLogic(IAsyncResult iar, Func2 endFunction, Action1 endAction, Task1 promise, Boolean requiresSynchronization)--- 从之前抛出异常的位置结束堆栈跟踪---
在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(任务任务)
在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(任务任务)
在 Microsoft.ServiceBus.Messaging.SubscriptionClient.ReceiveAsync()
【问题讨论】:
-
连接没有被关闭?
-
您使用的是基本层吗?我认为使用 Basic 会更低。
标签: azure azureservicebus servicebus