OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
RE: [xml-dev] XML Schema: "Best used with the ______ tool"

> Current generation data binding tools unmarshal and marshal 
> as fast or faster than just building or serializing a DOM, 
> and access is much faster and easier than using XSLT or 
> XQuery to access data from said DOM. Have you actually tried 
> any comparisons? Even back six years ago my JiBX data binding 
> was faster than the best of the DOM-type models (dom4j), as 
> discussed in this article: 
> http://www.ibm.com/developerworks/xml/library/x-databdopt2/ 
> Data binding also generally uses much less memory than a DOM 
> model, because only the data values are represented rather 
> than all the details of the XML structure. As for validation, 
> it is rarely used in production systems due to the large 
> performance overhead.

I don't have any performance data, and I would love to see some. But XSLT
and XQuery processors also use tree representations that are much faster and
smaller than a DOM (in one recent Saxon measurement, 40% of the size, 40%
faster to build, and 30 times faster to navigate), and I don't think there's
any intrinsic reason why they should be slower than data binding. I'm not
saying they are faster, just challenging your assertion that they are
impossibly slow - I think the burden of proof is on you.
> XQuery may be usable when you only need a few selected items 
> of data from the documents, but it's not a realistic approach 
> when all the data in the document is actually used by the application.

> For most web services applications the Java (or other programming
> language) representation is actually primary, and XML is just 
> being used for interchange. 

I don't think it matters which is primary, the complexity comes from having
two representations and keeping them aligned. But I would have thought the
format used for data interchange is primary in the sense that it needs to be
agreed with other parties, whereas the Java representation is under local
control. (Unless of course you're running the same code at both ends, in
which case I'm not sure why you're using XML at all.)

> Do you seriously expect 
> developers to go back to creating DOM representations from 
> their data structures, and vice versa?

Good lord, no! DOM should be allowed to die an undignified, lonely and
miserable death. But I also think that business logic should be written in
4GLs not in 3GLs - 20 years ago we seemed to be more advanced in recognizing
that than we are today.

Michael Kay

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS