Announcing CHService, a new open source Windows service framework!

I'm pleased to announce that CHService v1.0 has just been published at Github!

CHService is a small open source project, born out of my irritation at writing essentially the same Windows Service over and over. Standard service types in my applications included services that fired a particular method every x minutes (facilitating cleanup or DB synchronization, usually) and services that listened on ports for signals, or to respond to communications. Each time I was forced to rewrite the same basic code to facilitate threading, service stoppage, tcp listeners, timing loops, etc. With CHService, I have made a new windows service base class that loads and runs any number of worker classes, configurable in an app.config file. I have pushed all of the common functionality into worker base classes, so that a timed method worker, for example, can be created by merely inheriting the TimedWorkerBase class and overloading the Fire() method with the operation to perform each time the service fires. The second worker base class currently included creates a worker that listens on a specified port for communication, requiring only an overload of the AcceptSocket() method.

Many varied types of worker processes can be added to a single CHService project. The set of workers to be invoked can be configured in the app.config file of a CHService project, parsed at run-time using reflection in an effort to make service configuration and repurposing as simple and seamless as possible.

The project is currently small, but includes the necessary base classes, an example windows service project created using the framework, and a small unit test project for demonstration.

I would greatly appreciate any feedback or thoughts on the project, which I hope will be of use to some of you out there.