Before .net , writing a windows service (NT Service) used to be a messy C++ job. .Net made writing a
windows service simple and straight forward.
What process is a good candidate to be written as a Windows service?
A long running process or a repeating process that requires no user interaction, no
user interface, not even a console – just sit and do some work kind of process – you write it as a
windows service. Just make sure that you document your service well and publish, so that every one
knows the existence of it. Because for the server ops people, when they take inventory of stuff running
in a server, a custom windows service is not the first one makes the list. This might result in your
service not started after a server re-start and so on.
So it is a good practice to setup your service to start automatically, also if your service does not
require any special permissiona run it under local account. If it requires special permissions like
accessing a file share, create a service account with least required access and run service under that
Next post I will discuss writing a simple service…