I have a Java program that should run as a service. How can I do this easily?
Good explanations in this article - including a pointer to Java Service Wrapperan open source component that simplifies it.
Java Service Wrapper
Write a service in C / C ++ and load the JVM. Or you can use some tool that binds your Java application to the service.