Reputation: 237
If process terminated due to any reason other than exit code 0, is it possible to restart automatically using install4j Multi-platform launcher?
Basted on the launcher script com.install4j.runtime.launcher.Launcher
is launching the process. Is there any way to customize the behavior of this class?
Upvotes: 1
Views: 408
Reputation: 48035
As of install4j 5.1.12, no restart functionality based on the exit code is available.
Instead, you can add a custom installer application that shuts down the launcher with a "Shut down calling launcher" action and starts the launcher again with an "Execute launcher" action. For that to work, you have to start the custom installer application via the com.install4j.api.launcher.ApplicationLauncher
API. If no GUI should be displayed, the "Default execution mode" property of the custom installer application should be set to "Unattended mode".
In that way you also have the opportunity to replace jar files or other locked files in between.
Upvotes: 2