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.

Bug 56899 - dtd validation takes way too long...
Summary: dtd validation takes way too long...
Status: CLOSED FIXED
Alias: None
Product: xml
Classification: Unclassified
Component: Code (show other bugs)
Version: 4.x
Hardware: All All
: P2 blocker (vote)
Assignee: Milan Kuchtiak
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-24 04:44 UTC by _ ludo
Modified: 2006-03-24 12:49 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ ludo 2005-03-24 04:44:12 UTC
It seems that  sun-web.xml or sun-ejb-jar.xml  XML validation takes forever for
me on my vpn system at home: the locally registered dtds or schemas do not seem
to be used. They are registered in the xml catalog.
Open these files in xml editor (popup menu edit). Make sure the AS 8.1 is
registered to get the DTDs. This was not happening before, I think, so it's a
regression imo, unless the plugin has to do somethinfI do not know.

Here is the dump thread when it takes a long time before validation ends:

"OpenIDE-request-processor-0" daemon prio=2 tid=0x0c38a498 nid=0xfe0 runnable [e
76f000..e76fd8c]
        at java.net.Inet4AddressImpl.lookupAllHostAddr(Native Method)
        at java.net.InetAddress$1.lookupAllHostAddr(InetAddress.java:770)
        at java.net.InetAddress.getAddressFromNameService(InetAddress.java:1059)

        at java.net.InetAddress.getAllByName0(InetAddress.java:1009)
        at java.net.InetAddress.getAllByName0(InetAddress.java:981)
        at java.net.InetAddress.getAllByName(InetAddress.java:975)
        at java.net.InetAddress.getByName(InetAddress.java:889)
        at java.net.InetSocketAddress.<init>(InetSocketAddress.java:114)
        at sun.net.NetworkClient.doConnect(NetworkClient.java:139)
        at sun.net.www.http.HttpClient.openServer(HttpClient.java:402)
        at sun.net.www.http.HttpClient$3.run(HttpClient.java:451)
        at java.security.AccessController.doPrivileged(Native Method)
        at sun.net.www.http.HttpClient.privilegedOpenServer(HttpClient.java:448)

        - locked <0x14e2ba68> (a sun.net.www.http.HttpClient)
        at sun.net.www.http.HttpClient.openServer(HttpClient.java:608)
        - locked <0x14e2ba68> (a sun.net.www.http.HttpClient)
        at sun.net.www.http.HttpClient.<init>(HttpClient.java:306)
        at sun.net.www.http.HttpClient.<init>(HttpClient.java:267)
        at sun.net.www.http.HttpClient.New(HttpClient.java:339)
        at sun.net.www.http.HttpClient.New(HttpClient.java:320)
        at sun.net.www.http.HttpClient.New(HttpClient.java:315)
        at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConne
ction.java:521)
        at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection
.java:498)
        at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon
nection.java:626)
        - locked <0x14e2b7e0> (a sun.net.www.protocol.http.HttpURLConnection)
        at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLCon
nection.java:1465)
        at java.net.URLConnection.getContentType(URLConnection.java:382)
        at org.apache.crimson.parser.Resolver.resolveEntity(Resolver.java:388)
        at org.apache.crimson.parser.ExternalEntity.getInputSource(ExternalEntit
y.java:89)
        at org.apache.crimson.parser.Parser2.pushReader(Parser2.java:3327)
        at org.apache.crimson.parser.Parser2.externalParameterEntity(Parser2.jav
a:3062)
        at org.apache.crimson.parser.Parser2.maybeDoctypeDecl(Parser2.java:1347)

        at org.apache.crimson.parser.Parser2.parseInternal(Parser2.java:656)
        at org.apache.crimson.parser.Parser2.parse(Parser2.java:337)
        at org.apache.crimson.parser.XMLReaderImpl.parse(XMLReaderImpl.java:448)

        at org.netbeans.spi.xml.cookies.SharedXMLSupport.getNamespaces(SharedXML
Support.java:473)
        at org.netbeans.spi.xml.cookies.SharedXMLSupport.getSchemaLocations(Shar
edXMLSupport.java:449)
        at org.netbeans.spi.xml.cookies.SharedXMLSupport.parse(SharedXMLSupport.
java:170)
        at org.netbeans.spi.xml.cookies.SharedXMLSupport.validateXML(SharedXMLSu
pport.java:128)
        at org.netbeans.spi.xml.cookies.ValidateXMLSupport.validateXML(ValidateX
MLSupport.java:50)
        at org.netbeans.modules.xml.tools.actions.ValidateAction$RunAction.run(V
alidateAction.java:96)
        at org.openide.util.Task.run(Task.java:189)
        at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:330)

        at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java
:721)
Comment 1 Petr Jiricka 2005-03-24 08:01:32 UTC
Could be related to the upgrade of the old Sun XML resolver to the Apache
version. Milan, can you please look at this? Thanks.
Comment 2 Milan Kuchtiak 2005-03-24 15:55:21 UTC
Petr(Kuzel), it seems that internet resource has bigger priority than local
resource (mounted in catalog) when proxy is setup.

Don't you know what has changed ?
Comment 3 _ pkuzel 2005-03-25 14:20:54 UTC
I suspect either 
 
org.apache.crimson.parser.Resolver.resolveEntity(Resolver.java:388) 
 
or 
 
org.netbeans.spi.xml.cookies.SharedXMLSupport.getNamespaces(SharedXML 
Support.java:473) 
Comment 4 _ pkuzel 2005-03-25 14:24:52 UTC
Yes, SharedXMLSupport.getNamespaces(SharedXMLSupport.java:473) does not set 
any EntityResover.  
Comment 5 _ pkuzel 2005-03-25 14:36:29 UTC
FIXED  
 
Checking in src/org/netbeans/spi/xml/cookies/SharedXMLSupport.java; 
/cvs/xml/api/src/org/netbeans/spi/xml/cookies/SharedXMLSupport.java,v  <--  
SharedXMLSupport.java 
new revision: 1.9; previous revision: 1.8 
done 
 
Comment 6 _ ludo 2005-03-25 19:57:03 UTC
verified.
Thanks