[jboss-dev] changes in parsing with xb

Alexey Loubyansky alexey.loubyansky at redhat.com
Thu Mar 12 10:41:38 EDT 2009

There have been many fixes in the last two beta releases of XB that will 
affect AS and other users.
Most noticeable changes/fixes are related to internal navigation across 
schema structures during XML parsing. In simple words, XB is now (much) 
more sensitive to validation issues (incorrect element order, etc).
Some files that could be parsed before, now (with default settings) 
won't. WRT AS it would be e.g. vfs, aop xml etc.

To workaround this, you can set system property 
xb.builder.useUnorderedSequence to true. This will make the order in 
which elements from a sequence appear in xml not important.
Alternatively, you can call 
JBossXBBuilder.setUseUnorderedSequence(boolean value) or use annotation 
to bind classes to unordered sequences.

But this has to remain a workaround, not the default. There has to be a 
good reason to use unordered sequences. Fix your XML and binding now.

The latest XB has not been integrated into the AS yet (although, I ran 
some tests from the AS testsuite locally) due to dependency on changes 
in VFS and deployers:

The latest metadata release (1.0.0.CR17) requires at least XB 2.0.1.Beta3.

If you are using XB, please, try the latest beta.

Here are release notes for XB 2.0.1.Beta3

and XB 2.0.1.Beta2

More information about the jboss-development mailing list