I want to make my application single instance application. While launching a new instance i want to check for already running instance. My application is written in java.
Asked
Active
Viewed 102 times
-1
-
Why not use a `Singleton` bean? – ares Sep 29 '14 at 12:00
-
or here : http://stackoverflow.com/questions/177189/how-to-implement-a-single-instance-java-application – xlecoustillier Sep 29 '14 at 12:01
1 Answers
0
Your application can listen to messages on a port. You can send a ping and if it is timed out, then it is not running and if it responds, it is running.

Lajos Arpad
- 64,414
- 37
- 100
- 175