javaterminal / TerminalFX

Java FX Terminal Emulator
MIT License
274 stars 51 forks source link

Ensure ExecutorService is shutdown when app stops #45

Closed dustinkredmond closed 3 years ago

dustinkredmond commented 3 years ago

ThreadHelper's ExecutorService does not get shutdown when the application is stopped.

I created a new public static utility method in ThreadHelper that calls executorService.shutdown(). I called this new method in the TerminalAppStarter in the overridden JavaFX Application.stop() method. This will ensure the ExecutorService is shutdown when JavaFX exits.