Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > browser/applet hanging on close-down - how to debug

Reply
Thread Tools

browser/applet hanging on close-down - how to debug

 
 
Ed
Guest
Posts: n/a
 
      05-26-2004
Guys,

We have an applet "application" which runs within IE5.5. This
application can spawn another browser window which itself has an
embedded applet.

Often, when we close the second browser window it just hangs - the
only way to get rid of it is to kill the task.

The obvious question is has anyone seen this before.

I am talking about the Sun plug-in by the way. If we run this in
console (debug) mode the problem NEVER happens. So I assume that
either it is a timing issue and the console slows the JVM down or the
console option runs Java in a different way.

Does anyone have any ideas?

TIA

Ed

PS You will see a related message about debugging the plug-in and also
passing start-up parameters.
 
Reply With Quote
 
 
 
 
Andrew Thompson
Guest
Posts: n/a
 
      05-26-2004
On 26 May 2004 01:56:36 -0700, Ed wrote:

> We have an applet


URL?

> The obvious question is has anyone seen this before.


You have. Give an URL and that
might make (at least) two of us.

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
 
Reply With Quote
 
 
 
 
Roedy Green
Guest
Posts: n/a
 
      05-26-2004
On 26 May 2004 01:56:36 -0700, http://www.velocityreviews.com/forums/(E-Mail Removed) (Ed) wrote or
quoted :

>We have an applet "application" which runs within IE5.5. This
>application can spawn another browser window which itself has an
>embedded applet.


You can open a simple frame. There in no need to spawn an entire
second browser. At the very least you can just open another page in
the same browser, using

--
Canadian Mind Products, Roedy Green.
Coaching, problem solving, economical contract programming.
See http://mindprod.com/jgloss/jgloss.html for The Java Glossary.
 
Reply With Quote
 
Roedy Green
Guest
Posts: n/a
 
      05-26-2004
On 26 May 2004 01:56:36 -0700, (E-Mail Removed) (Ed) wrote or
quoted :

>We have an applet "application" which runs within IE5.5. This
>application can spawn another browser window which itself has an
>embedded applet.


You can open a simple frame. There in no need to spawn an entire
second browser. At the very least you can just open another page in
the same browser, using

getAppletContext().showDocument( url, window );

--
Canadian Mind Products, Roedy Green.
Coaching, problem solving, economical contract programming.
See http://mindprod.com/jgloss/jgloss.html for The Java Glossary.
 
Reply With Quote
 
Andrew Thompson
Guest
Posts: n/a
 
      05-26-2004
On Wed, 26 May 2004 09:35:39 GMT, Roedy Green wrote:

> getAppletContext().showDocument( url, window );


See the source of the JavaVersionApplet
for an example..
<http://www.physci.org/codes/display.jsp?fl=/codes/java/JavaVersionApplet.java#62>

(Used here..)
<http://www.physci.org/codes/jre.jsp>

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
 
Reply With Quote
 
Ed
Guest
Posts: n/a
 
      05-27-2004
Guys,

I forgot to say that I do not have the source code for this
application; the supplier says they have not seen it elsewhere (how do
I know whether this is true or not!) ....

The environment is NT running IE5.5 and Plug_in 1.4.2.

Sounds like no-one recognises the problem so the main question is can
I debug an applet running in IE using say Eclipse's debugger?

cheers

Ed


Roedy Green <(E-Mail Removed)> wrote in message news:<(E-Mail Removed)>. ..
> On 26 May 2004 01:56:36 -0700, (E-Mail Removed) (Ed) wrote or
> quoted :
>
> >We have an applet "application" which runs within IE5.5. This
> >application can spawn another browser window which itself has an
> >embedded applet.

>
> You can open a simple frame. There in no need to spawn an entire
> second browser. At the very least you can just open another page in
> the same browser, using
>
> getAppletContext().showDocument( url, window );

 
Reply With Quote
 
Andrew Thompson
Guest
Posts: n/a
 
      05-27-2004
On 27 May 2004 08:30:27 -0700, Ed wrote:
> Roedy Green <(E-Mail Removed)> wrote in message news:...
>>(E-Mail Removed) (Ed) wrote or quoted :
>>
>>>We have an applet "application" which runs within IE5.5. This
>>>application can spawn another browser window which itself has an
>>>embedded applet.

...
> I forgot to say that I do not have the source code for this
> application; the supplier says they have not seen it elsewhere (how do
> I know whether this is true or not!) ....


What does that mean? The supplier of the
app. does not have the source?

> The environment is NT running IE5.5 and Plug_in 1.4.2.


...you do know where the Java Console is, don't you?

> Sounds like no-one recognises the problem so the main question is can
> I debug an applet running in IE using say Eclipse's debugger?


I don't know Eclipse.

And, ..could I ask you not to top-post?
It makes threads difficult for me to understand.
<http://www.physci.org/codes/javafaq.jsp#netiquette>

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
 
Reply With Quote
 
Pedro
Guest
Posts: n/a
 
      05-31-2004
On 27-5-2004 17:30, Ed wrote:

> Guys,
>
> I forgot to say that I do not have the source code for this
> application; the supplier says they have not seen it elsewhere (how do
> I know whether this is true or not!) ....
>
> The environment is NT running IE5.5 and Plug_in 1.4.2.
>
> Sounds like no-one recognises the problem so the main question is can
> I debug an applet running in IE using say Eclipse's debugger?
>
> cheers
>
> Ed
>

I have not tried debugging the Java plugin myself, but I remember from debugging Tomcat within
Eclipse, you must add -Xrunjdwp=transport=dt_socket,server=y,address=loca lhost:8000 as runtime
parameter to the Tomcat java executable. In Eclipse, you must use a "Remote Java application" run
configuration (menu Run->Debug..., select "Remote Java application", press New) with Host and Port
matching the address given in -Xrunjdwp (localhost:8000).

In the Java control panel you can specify Java runtime parameters. I'm currently running 1.5.0b2,
but I'm fairly sure in 1.4.2 you can too. In the 1.5.0 control panel, select "Java" tab and press
"View" of "Java applet runtime settings" and add the -Xrunjdwp parameter.

I'll try it out myself in a moment.

Regards,
Pedro



 
Reply With Quote
 
Pedro
Guest
Posts: n/a
 
      05-31-2004
On 31-5-2004 17:10, Pedro wrote:

> On 27-5-2004 17:30, Ed wrote:
>
>> Guys,
>> The environment is NT running IE5.5 and Plug_in 1.4.2.
>>
>> Sounds like no-one recognises the problem so the main question is can
>> I debug an applet running in IE using say Eclipse's debugger?
>>
>> cheers
>>
>> Ed
>>

> I have not tried debugging the Java plugin myself, but I remember from
> debugging Tomcat within
> Eclipse, you must add
> -Xrunjdwp=transport=dt_socket,server=y,address=loca lhost:8000 as runtime
> parameter to the Tomcat java executable. In Eclipse, you must use a
> "Remote Java application" run configuration (menu Run->Debug..., select
> "Remote Java application", press New) with Host and Port matching the
> address given in -Xrunjdwp (localhost:8000).
>
> In the Java control panel you can specify Java runtime parameters. I'm
> currently running 1.5.0b2, but I'm fairly sure in 1.4.2 you can too. In
> the 1.5.0 control panel, select "Java" tab and press "View" of "Java
> applet runtime settings" and add the -Xrunjdwp parameter.
>
> I'll try it out myself in a moment.
>

OK, I've just tried it, and it works like a charm (Win2000, Java 1.5.0b2, Eclipse 2.1.2, Mozilla 1.6
& IE6). I could add breakpoints and single step through an applet I once wrote.


One *important* thing: use -Xrunjdwp:transport=dt_socket,server=y,address=loca lhost:8000 instead of
-Xrunjdwp=transport... (i.e. use ':' after -Xrunjdwp, '=' caused a crash of my browser ).

Further I added ',suspend=n' so the applet/browser does not wait until Eclipse establishes the debug
session. The plugin runtime parameter I used was
-Xrunjdwp:transport=dt_socket,server=y,address=loca lhost:9999,suspend=n

See http://java.sun.com/j2se/1.4.2/docs/...tml#Invocation for more details on
-Xrunjdwp parameters.

P.S.: Remember to remove the parameter from the Java control panel after you're done with debugging.
Otherwise the browser/plugin keeps listenening for debug sessions on the specified port (might be a
security risk).

Regards,
Pedro
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Config Mgr Debug/Release and Web.config Compilation debug=true RonL ASP .Net 0 04-08-2006 03:50 PM
Perl debug hanging jennykelly@gmail.com Perl Misc 2 09-06-2005 08:41 PM
Debug (DLL MFC) -> Debug (Static MFC) ringos75 C++ 0 04-14-2005 01:50 PM
ZoneAlarm hanging ASPX page in debug mode VB Programmer ASP .Net 3 01-19-2005 07:44 PM
[Howto] Compiling debug Python extensions for non-debug Python Mike C. Fletcher Python 3 10-12-2003 09:37 PM



Advertisments