Swing Based Application Will Not Terminate
3 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Nicholas_Whitehead
Posted On:   Tuesday, July 24, 2001 05:12 AM

We are building a Swing based Java application. we have this problem in that the JVM will not terminate. The GUI disappears, but users think it is gone and eventually all memory on the box is consumed by non-terminated JVMs. We do know that the problem is that some threads are still running, but we have not had any success in finding them. We do run many threads that perform different work such as client synchronization, JMS Messaging, talking to WebSphere etc. I have tried using JProbe's Thread Analyzer 3.0 but it crashes after launch so it is fairly useless. I am quite certain that the JMS threads are being shut down, but there are so many others. I am looking for some good suggestions.... Thanks. //Nich   More>>

We are building a Swing based Java application. we have this problem in that the JVM will not terminate. The GUI disappears, but users think it is gone and eventually all memory on the box is consumed by non-terminated JVMs.

We do know that the problem is that some threads are still running, but we have not had any success in finding them. We do run many threads that perform different work such as client synchronization, JMS Messaging, talking to WebSphere etc. I have tried using JProbe's Thread Analyzer 3.0 but it crashes after launch so it is fairly useless.

I am quite certain that the JMS threads are being shut down, but there are so many others. I am looking for some good suggestions....

Thanks.

//Nicholas

   <<Less

Re: Swing Based Application Will Not Terminate

Posted By:   Alex_Chaffee  
Posted On:   Thursday, August 2, 2001 10:35 AM

Re: Swing Based Application Will Not Terminate

Posted By:   Christopher_Schultz  
Posted On:   Tuesday, July 24, 2001 06:53 AM

You need to explicitly call System.exit(exit_value) to exit a Swing application. This is because the event dispatcher thread is not a Daemon thread, and won't allow the JVM to shut down when other threads are dead.



-chris

Re: Swing Based Application Will Not Terminate

Posted By:   Felker_Robert  
Posted On:   Tuesday, July 24, 2001 05:46 AM

There several ways to close a frame. Are you sure that your frame is not in HIDE_ON_EXIT mode ( it must be CLOSE_ON_EXIT).
About | Sitemap | Contact