Activation script hangs and cannot exit

I have implemented SQL Server Service Broker with error handling as per this Remus Resanu article.

When I started the process and the activation script was started but never stopped processing. According to the SQL Server log file, it looks like I have a typo in my error handling and now it is stuck in an infinite loop.

I tried to kill the process using kill <pid>

but I get the message Only user processes can be killed

. I also tried restarting the server, but the script activation will start again.

How can I kill the escape activation process?

+3


source to share


2 answers


I was unable to find a solution using google / bing search. I eventually remembered that we had enabled the service broker via the SQL command, so I tried to disable it and it seemed to work:



ALTER DATABASE dbname SET DISABLE_BROKER;

      

+3


source


It looks like an undocumented feature. If the activated procedure does not output END CONVERSATION, it continues to restart in an infinite loop. Thus, to stop it, you need to make it successfully run END CONVERSATION of any dialog. If the queue is disabled due to poison message detection, you need to drop it in order to stop the activation process - no need for a reset broker. I haven't found any solution to this problem, so played around with it a bit and hope this gives you a hint.



+1


source







All Articles