tags:

views:

54

answers:

1

Hello,

We are writing an application in Java and it needs to be start/stoppable by another application, like a service/daemon. We package it in a .jar which encapsulates everything it needs to run, and put it in a "working directory" which contains configuration files, variable resources, logs, etc.

Is there a good way to be able to start/stop this application from a script or any other application by calling something on it?

Thank you very much for any help!

A: 

Try out Commons Daemon

spektom
It looks good, we succeeded in creating a service from our server application, but we can't get clients to connect to it when it's started as a service. When we just start the .jar manually, we can connect to it from other computers w/o problem... Any experience about this?
M. Joanis
What operating system? Is there a firewall?
spektom
We're principally working on Win7 (though we have many OS X laptops at hand too). We tried disabling every bit of a network security we could find in every computer. The thing is that it works good when we start the JAR manually, but it stops being able to receive connections when it's started as a service.
M. Joanis