Many thanks for BeanShell - I'm using it for years and
very satisfied.
A problem that bugs me for ages is that JConsole
doesn't terminates gracefully. The inpipe watcher
thread is hanging there and prevents the application
termination. System.exit() is required to force
termination.
Attached is a source with a fix to the problem:
In constructor JConsole#JConsole(InputStream,
OutputStream) just before the end, there is thread
allocation.
Before:
// Start the inpipe watcher
new Thread( this ).start();
After:
// Start the inpipe watcher
Thread thread = new Thread( this );
thread.setDaemon(true);
thread.start();
As daemon thread, the inPipe Watcher doesnt get in the
way when all other threads are ready to terminate.
regards,
Barak Naveh
Ticket has been migrated to github.
Please follow up on this over here: https://github.com/beanshell/beanshell/issues/110