Skip to content

Commit ce39edd

Browse files
author
Ashish Chhabria
committed
adding refined troubleshooting documentation
1 parent d83fd0e commit ce39edd

File tree

1 file changed

+37
-0
lines changed

1 file changed

+37
-0
lines changed

articles/service-bus-messaging/service-bus-messaging-exceptions.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,43 @@ You should check the value of the [ServicePointManager.DefaultConnectionLimit](h
101101
### Queues and topics
102102
For queues and topics, the timeout is specified either in the [MessagingFactorySettings.OperationTimeout](/dotnet/api/microsoft.servicebus.messaging.messagingfactorysettings) property, as part of the connection string, or through [ServiceBusConnectionStringBuilder](/dotnet/api/microsoft.azure.servicebus.servicebusconnectionstringbuilder). The error message itself might vary, but it always contains the timeout value specified for the current operation.
103103

104+
## MessageLockLostException
105+
106+
### Cause
107+
108+
The **MessageLockLostException** is thrown when a message is received using the [PeekLock](message-transfers-locks-settlement.md#peeklock) Receive mode and the lock held by the client expires on the service side.
109+
110+
The lock on a message may expire due to various reasons -
111+
112+
* The lock timer has expired before it was renewed by the client application.
113+
* The client application acquired the lock, saved it to a persistent store and then restarted. Once it restarted, the client application looked at the inflight messages and tried to complete these.
114+
115+
### Resolution
116+
117+
In the event of a **MessageLockLostException**, the client application can no longer process the message. The client application may optionally consider logging the exception for analysis, but *must* dispose off the message.
118+
119+
Since the lock on the message has expired, it would go back on the Queue (or Subscription) and can be processed by the next client application which calls receive.
120+
121+
If the **MaxDeliveryCount** has exceeded then the message may be moved to the **DeadLetterQueue**.
122+
123+
## SessionLockLostException
124+
125+
### Cause
126+
127+
### Resolution
128+
129+
## SocketException
130+
131+
### Cause
132+
133+
### Resolution
134+
135+
## MessagingException
136+
137+
### Cause
138+
139+
### Resolution
140+
104141
## Next steps
105142
For the complete Service Bus .NET API reference, see the [Azure .NET API reference](/dotnet/api/overview/azure/service-bus).
106143
For troubleshooting tips, see the [Troubleshooting guide](service-bus-troubleshooting-guide.md)

0 commit comments

Comments
 (0)