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 203773 - Multiple XML validation fails for large XML documents
Summary: Multiple XML validation fails for large XML documents
Status: RESOLVED WORKSFORME
Alias: None
Product: xml
Classification: Unclassified
Component: Validation (show other bugs)
Version: 7.1
Hardware: Macintosh Mac OS X
: P3 normal (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-16 06:59 UTC by dbell
Modified: 2015-02-04 03:37 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 177918


Attachments
An XML document to use to replicate the issue (8.78 KB, application/octet-stream)
2011-10-16 07:08 UTC, dbell
Details
The w3c XML schema schema. Place this in the same directory as the other schema file (UiBinder.xsd) when trying to replicate the issue, to resolve references. (82.83 KB, application/octet-stream)
2011-10-16 07:10 UTC, dbell
Details
stacktrace (3.64 KB, text/plain)
2011-12-01 12:51 UTC, Martin Fousek
Details

Note You need to log in before you can comment on or make changes to this bug.
Description dbell 2011-10-16 06:59:34 UTC
[ BUILD # : 201110140600 ]
[ JDK VERSION : 1.6.26 ]

For large XML documents, when I try to validate two documents in succession,
the second attempt before the first has finished, the validation output appears
in the same output pane ("XML Check"). When the second validation is started,
the output window is cleared, and then the output from both validation attempts
are written to the output window, with no obvious indication which document the
errors/messages are from. The same is true for multiple validation checks on
the same file: previous checks are not cancelled, and output from all checks
appears in the same console.

To replicate (two schema scenario):
1. Get two big XML documents that reference XML schemata.
2. Validate one (Right-Click > Validate XML)
3. Look in the output window pane "XML Check": the check has started
4. Quickly validate the other, before the first validation attempt has finished
(Right-Click > Validate XML)
5. Look in the output window pane "XML Check": only the second validation
attempt's start messages are visible. Then "XML validation finished appears
twice in the console.

To replicate (one schema scenario):
1. Get a big XML document that references an XML schema.
2. Validate it (Right-Click > Validate XML)
3. Look in the output window pane "XML Check": the check has started
4. Quickly validate it again, before the first validation attempt has finished
(Right-Click > Validate XML)
5. Look in the output window pane "XML Check": only the second validation
attempt's start messages are visible. Then "XML validation finished appears
twice in the console.
6. Repeat 1-5 with three or more concurrent validation attempts. Sometimes an
error will appear (will link to uploaded stacktraces).

Workaround:
Wait until each validation attempt has finished before attempting validation
again.
Comment 1 dbell 2011-10-16 07:02:44 UTC
Attached uploaded stacktraces
Comment 2 dbell 2011-10-16 07:08:59 UTC
Created attachment 112092 [details]
An XML document to use to replicate the issue
Comment 3 dbell 2011-10-16 07:10:31 UTC
Created attachment 112093 [details]
The w3c XML schema schema. Place this in the same directory as the other schema file (UiBinder.xsd) when trying to replicate the issue, to resolve references.
Comment 4 Svata Dedic 2011-10-18 16:00:16 UTC
Two parallel runs of validation do not cooperate with each other. Each of them opens a validation output (window system will not open two windows, rather it reuses the existing validation output window) and clears it at start.
If another validation starts, it simply clears the running one's result as if it were results from an already terminated validation which are obsolete now.

I see two options:
* chain the outputs, wait for 1st validation to finish then emit buffered output of the 2nd and other runs
* open a separate tab for each additional parallel validation

I prefer the 2nd option, actually, as it better separates outputs for the user.
Comment 5 dbell 2011-10-19 09:09:05 UTC
(In reply to comment #4)
> I prefer the 2nd option, actually, as it better separates outputs for the user.

I agree: this is consistent with project builds, each appearing in their own outpu.
Comment 6 Martin Fousek 2011-12-01 12:51:36 UTC
Created attachment 113699 [details]
stacktrace

invoked few times validation on xml document
Comment 7 Quality Engineering 2015-02-04 03:37:29 UTC
Reported for 7.3.x or earlier, no new info since then -> closing as worksforme, please reopen in case you see it.