[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.platform] Re: Strange behavior when trying to debug my application within eclipse

Hi,



I tried that

All threads are seem to be "running"



Any other idea?

Thanks

/Yaron





"Alexandros Karypidis" <akarypid@xxxxxxxx> wrote in message 
news:<fhi3rb$odp$1@xxxxxxxxxxxxxxxxx>...

> Here's an idea: use thread.setName() to provide names for your "SIP"

> thread as well as the main thread.

>

> While the application is stuck, look at these threads in the Debug

> perspective. Select them and press the "interrupt them to see where

> they're blocked.

>

> Yaron Reinharts wrote:

>

> > Hi,

> >

> > I'm struggling a strange behavior when trying to debug my application 
> > within

> > eclipse

> >

> > When running outside Eclipse, the application runs without any problem

> >

> > When running within Eclipse I can not see the UI, it seems that the

> > application hangs while trying to create the first UI component

> >

> > I'm using a third party SipStack with no UI

> >

> > Here is a snippet of the code:

> >

> > ****************************************************************************************

> >

> > // Create the SIP stack and initialize it from a separate thread

> >

> > Thread thread = new Thread()

> >

> > {

> >

> > public void run()

> >

> > {

> >

> > SipStack client = new SipStack();

> >

> > client.initialize();

> >

> > }

> >

> > };

> >

> > thread.start();

> >

> > System.out.println("Trying to create a JFrame");

> >

> > JFrame frame = new JFrame("SipStack");

> >

> > System.out.println("JFrame created");

> >

> > frame.setVisible(true)

> >

> > ****************************************************************************************

> >

> > When running outside Eclipse (using the same JRE and the same classpath) 
> > the

> > program runs well and I can see all the logs and the JFrame

> >

> > When running the code within Eclipse (same behavior for Debug and Run) I 
> > can

> > see the "Trying to create a JFrame" log but not the "JFrame created",

> > neither the JFrame itself.

> >

> > When I create another JFrame before initiating the SipStack, I can see 
> > all

> > the logs and the JFrame, however the UI is not responding

> >

> > I saw this behavior with JDK 5.0 and JDK 6.0

> >

> > Any clue?

> >

> > Thanks in advance

> >

> > /Yaron