What is the easiest way to ping/notify a .NET Windows Service? Do I have to use WCF for this? Or is there an easier way? I would like to be able to wake up the service using a Python (or an Iron Python) script from anywhere. Also is there a way I can be notified (by email) if that the service has stopped?
+1
A:
- There is a command line tool SC which can be used start stop and query the service.
- I don't know if there is an easy way to use WMI from python but WMI provides the ability to control services remotely as well.
- If you want to use .net use the ServiceController Class.
rerun
2010-03-13 01:57:42
+1
A:
If you want to go to the low level .NET socket stuff, you could use the framework's TcpListener class. See an involved tutorial here. To host it in a Windows Service, check out this article.
James Kolpack
2010-03-13 02:10:17
A:
I had to host a WCF in the windows service to allow it to be notified remotely. Just to keep deploying the solution as simple as possible. using the ServiceController would require the correct setup of permissions
a b
2010-03-29 15:54:47