users@jaxb.java.net

Re: other vendors was: jaxb.properties and bgm.ser files in a jar

From: Eric Ma <eric.ma_at_db.com>
Date: Tue, 15 Apr 2003 08:37:38 -0400

Dennis:

Thank you for the reply. Options in implementation are good, but I prefer to code against a single set of interfaces. I like JAXP because it unifies different parsers, and I hope JAXB can achieve the same goal WRT XML data binding. Now let me ask a dumb question: what does it take to turn JiBX into a JAXB compliant implementation?

Eric




                      Dennis Sosnoski
                      <dms_at_sosnoski.com To: JAXB-INTEREST_at_JAVA.SUN.COM
> cc:
                      Sent by: Subject: Re: other vendors was: jaxb.properties and bgm.ser files in a jar
                      Discussion list
                      for the Java
                      Architecture for
                      XML Binding
                      <JAXB-INTEREST_at_JA
                      VA.SUN.COM>


                      04/14/03 05:09 PM
                      Please respond to
                      Discussion list
                      for the Java
                      Architecture for
                      XML Binding






There's often a reason why options develop, Eric. In the case of data
binding technologies the main issue is that none of the frameworks
available will really fit everyone's needs.

JAXB offers excellent support for code generation from Schema, including
on-demand validation. Of course, if you're not working with a Schema -
or don't want to make the XML Schema the focus of your application -
JAXB can't help you. JAXB is also somewhat bulky and has a
correspondingly high startup cost. This makes it a poor choice for
applications such as loading configuration files.

JiBX (the subject of my article, the first link below) offers high
performance and flexible mapping from XML to Java objects, letting you
decouple your Java code from the XML document structure. The main
downsides to JiBX are that it doesn't directly support validation or
code generation from Schema, and because the binding code is added to
your classes after they're compiled it's awkward to debug the actual
marshalling or unmarshalling process. The lack of Schema code generation
and validation makes JiBX a poor choice for working with complex XML
documents specified by Schemas.

XMLBeans (the subject of the second link) is an interesting approach
that combines some benefits of both the document model and data binding
approaches to working with XML. It's difficult to evaluate this fully
because of the restrictive license and proprietary nature of the code,
but it's likely to be slow for actual data binding use (probably fast to
just read and write a document, but slow to actually work with bound
objects which it handles by a sort of lazy binding approach). If and
when BEA allows me to run performance tests on XMLBeans I'll be able to
give more specific results. XMLBeans could be good for applications
where you only work with a small portion of an XML document - especially
when you want to use XPath selection expressions and such - but for
general data binding purposes JAXB and JiBX are probably better
alternatives.

  - Dennis

Eric Ma wrote:

>I think it is high time for the community to standardize on a single Java XML binding framework. There are just too many options now and makes it difficult to choose the right technology. See http://www-106.ibm.com/developerworks/java/library/x-databd3/index.html, and http://dev2dev.bea.com/technologies/xmlbeans/index.jsp.
>
>
>





--
This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.