Implement window service and other improvements