Community
Loading...
Posted inService Bus
Microsoft
11 years ago

Provide gracefull shutdown feature to Message Pump in Queue and Subscription Clients

There is not a good way to deal with a graceful shutdown of a Worker role using the OnMessage approach of processing queue messages off the service bus. It would be nice if you could call StopProcessing, or something similar on the QueueClient or SubscriptionClient so that they would stop their internal receive loop, but finish processing the messages they may already be processing. A count property of active processing messages would also be helpful so that in an OnStop method on the worker role you could call the StopProcessing and enter a loop till the active processing messages was zero.Perhaps actually creating a new class called a MessagePump which accepted a QueueClient or SubscriptionClient as part of the constructor would be a good route to provide a better break down of responsibilities.
Completed
All Ideas
Company Response
Eldert Grootenboer
Company Response
3 years ago
This is already supported in our latest SDK. Please switch to microsoft.azure.servicebus to use this functionality.
Loading...
You must to comment