title: how to gracefully stop worker role with service bus queue
body: <p>Hi we have a requirement we are using service bus to read message and process some data based on that message and we are using workerrole for better performance.</p>
  
  <p>The issue is when we try to deploy the workerrole any service bus message listener which is processing the request which is in action gets terminated by onStop() method and my data get's corrupted. and I have to again push a message for the ongoing request.</p>
  
  <p>What I want is a mechanism to gracefully stopping the worker role so that it process the existing message request before exiting and stop listening to new message. How do I do that.   </p>