Xerces parser performance degraded for first use in EAP 7.4 with java 17
Issue
- After moving to java 17, we see requests spend an increased amount of time in Xerces parser validation with full schema checking only the first time a parser is used:
"default task-32" #411 prio=5 os_prio=0 cpu=2067.47ms elapsed=43.00s tid=0x00005587c1fe4ef0 nid=0x2a2895 runnable [0x00007f19914a7000]
java.lang.Thread.State: RUNNABLE
at org.apache.xerces.impl.xs.models.XSDFACM.checkUniqueParticleAttribution(XSDFACM.java:1045)
at org.apache.xerces.impl.xs.XSConstraints.fullSchemaChecking(XSConstraints.java:493)
at org.apache.xerces.impl.xs.XMLSchemaValidator.handleEndElement(XMLSchemaValidator.java:2473)
at org.apache.xerces.impl.xs.XMLSchemaValidator.endElement(XMLSchemaValidator.java:895)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(XMLNSDocumentScannerImpl.java:673)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1645)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:324)
at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:515)
at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:571)
Environment
- JBoss Enterprise Application Platform (EAP) 7.4.x
- Java 17
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.