all groups > dotnet myservices > october 2007 >
You're in the

dotnet myservices

group:

Force my service to 'crash'


Force my service to 'crash' Roger
10/9/2007 11:43:11 AM
dotnet myservices:
I need to be able to cause my vb.net windows service to crash and terminate
'illegally'.

I have my service set to restart 3 time if it stops. This hasn't been
happening. I have a theory about why it isn't starting again (I get a
timeout error, I am connecting to a clients web-service for db access).

I can't test to see if I have fixed the problem unless I can cause the
service to stop 'illegally'. If I just stop it of course the server won't
try to re-start it. I need to be able to crash it so that it will re-start
and I can prove it worked. I figured if there is some code that will make it
past the compiler that will not just cause an error, but an actual stopping
of the service I could then prove I was right (or not).

Anyone know of some code that could cause the service to stop, but which the
compiler would let past?

Thanks.

Re: Force my service to 'crash' Barry Flynn
10/11/2007 12:00:00 AM
Have a function which just keeps on calling itself until you blow the stack?

Barry

--
Barry Flynn
Complete Solutions DG


[quoted text, click to view]

Re: Force my service to 'crash' Roger
10/17/2007 1:30:49 PM
Thanks.

I will give that a try.

[quoted text, click to view]

AddThis Social Bookmark Button