How to re-start an application remotely

C

Chris Berg

I have a Java App that is packed in a .jar file. To run it, I do:

java -jar MyApp.jar

which is running from a Windows command file, installed as a System
Service. The service it set to re-start if it stops.

Now, I want to be able to install a new version remotely. In an
earlier version of the VM (I believe it was 1.2) it was possible to
delere the jar file and replace it with a new one, while the app was
still running. Re-starting could then be done by exiting from the app,
and then Windows would start it again, now using the new version.

The nice thing about this was that it could be done remotely, without
physical access to the PC.

The trouble is, that the present VM version apparently keeps the jar
file open! So, I can't delete it and replace it with the new one,
without stopping the app. But once it is stopped (with the Service not
set to re-start), I can't start it again without physical access to
the pc, OR maybe via a Remote Desktop Connection, which I consider to
be unsafe when running on the public Internet. Or am I too paranoid?

Any ideas?

Chris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,813
Latest member
lawrwtwinkle111

Latest Threads

Top