use of org.springframework.boot.system.ApplicationPidFileWriter in project ontrack by nemerosa.
the class Application method main.
/**
* Start-up point
*
* @param args Arguments passed to the program, they may contain configuration variables.
*/
public static void main(String[] args) {
// PID file
File pid = new File("ontrack.pid");
// Runs the application
SpringApplication application = new SpringApplication(Application.class);
application.addListeners(new ApplicationPidFileWriter(pid));
application.run(args);
}
use of org.springframework.boot.system.ApplicationPidFileWriter in project FarmCloud by vratsasg.
the class FarmCloudApplication method main.
public static void main(String[] args) {
SpringApplication farmCloudApp = new SpringApplication(FarmCloudApplication.class);
farmCloudApp.addListeners(new ApplicationPidFileWriter());
farmCloudApp.run(args);
}
use of org.springframework.boot.system.ApplicationPidFileWriter in project tutorials by eugenp.
the class Application method writePID.
private static void writePID() {
SpringApplicationBuilder app = new SpringApplicationBuilder(Application.class).web(false);
app.build().addListeners(new ApplicationPidFileWriter("./bin/shutdown.pid"));
app.run();
}
Aggregations