public void start(Props props) {
if (props.valueAsBoolean(ProcessConstants.ENABLE_STOP_COMMAND, false)) {
// stop application when file <temp>/app.stop is created
File tempDir = props.nonNullValueAsFile(ProcessConstants.PATH_TEMP);
ProcessCommands commands = new ProcessCommands(tempDir, "app");
stopWatcher = new StopWatcher(commands, this);
stopWatcher.start();
}
monitor.start(createCommands(props));
monitor.awaitTermination();
}