This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
When trying to launch Web browser IDE hangs up for about 30 seconds and then ICE Browser appears.
Created attachment 1585 [details] Full Thread Dump when IDE is freezed
Assigning to radim. Not sure where is the bug. Problem can be, that following code runs in AWT: ... at org.openide.awt.SwingBrowserImpl.setURL(SwingBrowserImpl.java:75) at org.openide.awt.HtmlBrowser$1.run(HtmlBrowser.java:401) ...
It is not the ICEBrowser what grabs your AWTThread. It is JEditorPane from Swing. Namely the implementation of setPage that read URL content from AWT thread.
One way how to fix this bug is to make browser window non-persistent. Similarly if IDE display URLs in external browser they are not reopened when IDE is restarted so can cancel deserialization of internal browser too. Moreover the internal browser is not deserialized in current version if we can't connect to URL. This handles cases when there was browser showing executed/debugged JSP or servlet page.
this bug is not JDK 1.4 specific. Radim's evaluation is right: the root of trouble is JEditorPane.setPage(URL) which runs in AWT thread and runs asynchronously. javadoc of this method says you can make JEditorPane.setPage async by calling setAsynchronousLoadPriority on the AbstractDocument associated with the JEditorPane. I fixed the bug by doing so iff the URL's protocol is http or ftp, otherwise do it synchronously (http and ftp are the only two network protocols, JDK/NB understands). There is a cost attached with async loading of the URL (one more thread), so I don't want to enable it in all cases
Adame, can you verify this issue, thanks.
verified
Resolved for 3.4.x or earlier, no new info since then -> closing.