Hi there,
my JavaFX 21.0.2 app experienced a very weird regression when switching from Temurin
OpenJDK21U-jdk_x64_windows_hotspot_21.0.1_12
to
OpenJDK21U-jdk_x64_windows_hotspot_21.0.2_13

I use this method to restart my app.

public void restart() {
    // path to my exe app plus one string argument
    String[] cmdToRunUsingArgs = {"C:\Users\sblantipodi\AppData\Local\Firefly 
Luciferin\Firefly Luciferin.exe","string argument"};
    try {
        Runtime.getRuntime().exec(cmdToRunUsingArgs);
    }catch (SecurityException | IOException e) {
        log.error(e.getMessage());
    }
    javafx.application.Platform.exit();
    System.exit(0);
}


It worked well since years until JDK 21.0.2_13.
If I revert back to 21.0.1_12 it works well.

That method should start a new instance of the app, and close the "old instance".

With JDK 21.0.2_13, it closed the running instance but does not open a new instance.

I don't know if open a bugreport to JDK but before opening the bug report I would like to ask you if that method to restart the app is correct or if you think that I can use a better way.

Thanks
Davide





Reply via email to