[ 
https://issues.apache.org/jira/browse/XERCESJ-1705?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16745166#comment-16745166
 ] 

Gerben Abbink commented on XERCESJ-1705:
----------------------------------------

Thank you for your feedback.

But, i do think there's a problem somewhere. So, i created new and better test 
files. The old PROBLEM.xml and PROBLEM.xsd are no longer needed.

 

Here are the new test files:

NEW_PROBLEM.xml

NEW_PROBLEM.xsd.

 

I have also included two Java demos that validate the XML against the XSD 1.1:

SaxonEETester.java <== you need a (temporary) Saxon-EE license key to run this.

XercesTester.java

 

I run these demos on a 64-bits Windows 10 machine with 8GByte and paging files. 
I compile and run both Java programs with 64-bits Java 11 (OpenJDK) from the 
Windows Command Prompt.

In my previous post i mentioned XMLSpy , but here i am testing against the 
Saxon-EE XSD 1.1 validator from Saxonica because it's also a Java 
implementation, so i expect more or less similar results.

 

Here are the results:

The Saxon validator needs 9 sec. to come up with the right answer.

The Xerces validator crashes after 5 minutes with an error message.

I have included both outputs. According to Xerces's output there is not enough 
memory to continue.

 

My conclusion: this is not a performance problem but it is a memory problem. I 
am curious if you can replicate the results under similar circumstances.

 

> Validation against asserts (1.1) is slow and takes up a lot of memory for 
> larger files.
> ---------------------------------------------------------------------------------------
>
>                 Key: XERCESJ-1705
>                 URL: https://issues.apache.org/jira/browse/XERCESJ-1705
>             Project: Xerces2-J
>          Issue Type: Bug
>          Components: XML Schema 1.1 Structures
>    Affects Versions: 2.12.0
>            Reporter: Gerben Abbink
>            Priority: Major
>         Attachments: NEW_PROBLEM.xml, NEW_PROBLEM.xsd, PROBLEM.xml, 
> PROBLEM.xsd, SaxonEETester.java, SaxonOutput.txt, XercesOutput.txt, 
> XercesTester.java
>
>
> The validation of xml against asserts in XMLSchema 1.1 is slow and takes up a 
> lot of memory for larger xml files. I have created a simple test xml file 
> with lots of repetition and a corresponding xml schema to show the problem.
> It takes 20 sec. to validate the xml against the xml schema. When i remove 
> the asserts in the xml schema it takes just 1 second to validate. Testing was 
> done from the command prompt on a modern Windows machine with 8GByte memory.
> To compare, i have also validated the xml file against the xml schema in 
> XMLSpy. With asserts it takes 2 sec., without the asserts 1 sec. (XMLSpy does 
> not uses Xerces.)
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to