XML.orgXML.org
FOCUS AREAS |XML-DEV |XML.org DAILY NEWSLINK |REGISTRY |RESOURCES |ABOUT
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] [Summary] Eager and Just-in-Time loading of XML Schema documents, compiled documents, enhancing performance, streaming

Mukul Gandhi <gandhi.mukul@gmail.com> wrote on 08/07/2010 11:30:03 AM:

> I just wonder how could consideration of eager or late loading of XML
> schema documents can significantly affect performance of an entire
> validation episode.
>
> I think, however large the XML document is, the corresponding schema
> documents are relatively smaller. For example, if an XML element has
> maxOccurs="unbounded" specification in an XML schema document, then
> there could potentially be uncountable instances of such elements in
> corresponding XML documents, which can practically lead to very large
> XML document sizes.
>
> So I think, how could just in time loading of schema documents can
> improve the overall performance of validation episode.


It can reduce memory usage.

> I don't think that, eager loading of XML schema documents of any (or most of)
> practical XML application retards performance of the whole schema
> validation episode (since loading of schema documents, and creating
> grammar objects of most practical XML schema's is a pretty fast and
> memory optimizing operation).

In a long running application the (time) cost of schema loading can be made insignificant if the API (e.g. JAXP 1.3 Validation [1] or Xerces' grammar pools [2]) you're using caches the schema it loaded in memory and allows you to reuse that "compiled" result for validation. But if you're loading the same schema over and over again on each validation episode it can be very expensive and have seen many scenarios (particularly industry standards) where the set of schema documents are several orders of magnitude larger than the typical instance documents being validated.

> On Sat, Aug 7, 2010 at 7:16 PM, Costello, Roger L. <costello@mitre.org> wrote:
> > EXPLOITING JUST-IN-TIME LOADING TO ENHANCE PERFORMANCE
> >
> > Consider this scenario:
> >
> > 1. Your XML document is very large.
> >
> > 2. The XML Schemas that will be used to validate the XML document
> are independent (or, the XML Schemas can be partitioned into
> independent sets).
>
>
>
> --
> Regards,
> Mukul Gandhi
>
> _______________________________________________________________________
>
> XML-DEV is a publicly archived, unmoderated list hosted by OASIS
> to support XML implementation and development. To minimize
> spam in the archives, you must subscribe before posting.
>
> [Un]Subscribe/change address: http://www.oasis-open.org/mlmanage/
> Or unsubscribe: xml-dev-unsubscribe@lists.xml.org
> subscribe: xml-dev-subscribe@lists.xml.org
> List archive: http://lists.xml.org/archives/xml-dev/
> List Guidelines: http://www.oasis-open.org/maillists/guidelines.php

[1] http://xerces.apache.org/xerces2-j/javadocs/api/javax/xml/validation/package-summary.html
[2] http://www.ibm.com/developerworks/xml/library/x-perfap3.html#N10194

Michael Glavassevich
XML Parser Development
IBM Toronto Lab
E-mail: mrglavas@ca.ibm.com

E-mail: mrglavas@apache.org



[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