logo       
Google Custom Search

Related Msgs: audio.musicbrai...    enbd.general/20...    ietf.idr/2002-0...    java.ant-contri...    gnu.make.genera...    qplus.devel/200...    video.freevo.cv...    os.netbsd.ports...    yellowdog.gener...    xfree86.cvs/200...    search.nutch.us...    freedesktop.xse...    programming.swi...    capabilities.ge...    telephony.pbx.a...    mail.sylpheed.c...    db.firebase.por...    boot-loaders.u-...    recreation.radi...    netbsd.bugs/200...    web.zope.plone....    user-groups.lin...   

Re: Performance problem under load - Xerces with Weblogic 9.x: msg#00067

Subject: Re: Performance problem under load - Xerces with Weblogic 9.x
Hi Rajesh,

If the documents you're parsing refer to the same schema documents you can 
significantly improve the performance by doing grammar caching. The JAXP 
1.3 validation API [1] provides a standard mechanism for doing this.

Thanks.

[1] 
http://xerces.apache.org/xerces2-j/javadocs/api/javax/xml/validation/package-summary.html

Michael Glavassevich
XML Parser Development
IBM Toronto Lab
E-mail: mrglavas@xxxxxxxxxx
E-mail: mrglavas@xxxxxxxxxx

"Rajesh Balamohan" <rajesh.balamohan@xxxxxxxxx> wrote on 06/29/2007 
04:57:13 AM:

> Hello Folks,
> 
> We are using xerces parser for creating DOM objects. The size of the
> xml is very small in the order or 1 or 2kb. Under load, most of the 
> threads in weblogic are blocked like the following.
> 
> And the CPU of the box is at 98% in a 4 way box. Looking at the 
> stacktrace below, I find that most of the time is spent in schema 
> loading. There are lots of threads with similar stack trace. Are 
> there any known workarounds for this problem?. 
> 
> Is there a way to improve the XMLSchemaLoader?
> 
> The options we use during XML parser creation is as follows.. (Any 
> help on this issue would be of great help folks).
> 
>         // Build a parser to order. 
>                     p = new DOMParser();
>                     p.setFeature("http://xml.org/sax/features/validation
> ", true);
>                     p.setFeature ("http://apache.
> org/xml/features/validation/schema", true);
>                     p.setFeature(" http://apache.
> org/xml/features/validation/schema/normalized-value", false);
>                     p.setFeature("http://apache.
> org/xml/features/dom/defer-node-expansion ", false);
> 
>                     p.setEntityResolver(this);
>                     p.setErrorHandler(this);
> 
> "[ACTIVE] ExecuteThread: '12' for queue: 'weblogic.kernel.Default 
> (self-tuning)'" daemon prio=6 tid=0x54777e60 nid=0x138 
> 0 waiting for monitor entry [0x544bf000..0x544bfb9c]
>         at java.util.Hashtable.get(Hashtable.java:335)
>         - waiting to lock <0x0c54f0f8> (a java.util.Hashtable)
>         at org.apache.xerces.impl.xs.traversers.XSAttributeChecker.
> checkAttributes (Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.XSAttributeChecker.
> checkAttributes(Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.
> XSDWildcardTraverser.traverseAny(Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.
> XSDAbstractParticleTraverser.traverseSeqChoice(Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.
> XSDAbstractParticleTraverser.traverseSequence(Unknown Source) 
>         at org.apache.xerces.impl.xs.traversers.
> XSDComplexTypeTraverser.processComplexContent(Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.
> XSDComplexTypeTraverser.traverseComplexTypeDecl(Unknown Source) 
>         at org.apache.xerces.impl.xs.traversers.
> XSDComplexTypeTraverser.traverseGlobal(Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.XSDHandler.
> getGlobalDecl(Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.XSDElementTraverser.
> traverseNamedElement (Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.XSDElementTraverser.
> traverseGlobal(Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.XSDHandler.
> traverseSchemas(Unknown Source)
>         at org.apache.xerces.impl.xs.traversers.XSDHandler.
> parseSchema(Unknown Source)
>         at org.apache.xerces.impl.xs.XMLSchemaLoader.
> loadSchema(Unknown Source)
>         at org.apache.xerces.impl.xs.XMLSchemaValidator.
> findSchemaGrammar (Unknown Source)
>         at org.apache.xerces.impl.xs.XMLSchemaValidator.
> handleStartElement(Unknown Source)
>         at org.apache.xerces.impl.xs.XMLSchemaValidator.
> startElement(Unknown Source)
>         at org.apache.xerces.impl.XMLNSDocumentScannerImpl.
> scanStartElement (Unknown Source)
>         at org.apache.xerces.impl.
> XMLNSDocumentScannerImpl$NSContentDispatcher.
> scanRootElementHook(Unknown Source)
>         at org.apache.xerces.impl.
> XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch 
> (Unknown Source)
>         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.
> scanDocument(Unknown Source)
>         at org.apache.xerces.parsers.XML11Configuration.parse(Unknown 
Source)
>         at org.apache.xerces.parsers.XML11Configuration.parse (Unknown 
Source)
>         at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
>         at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
> 
> -- 
> ~Rajesh.B 



Try Searching:
servers, voip, java, networking, microsoft ...
<Prev in Thread] Current Thread [Next in Thread>