Re: possible bug while validating schemas

2006-10-29 Thread Michael Glavassevich
Hi Paul, This happens because you have maxOccurs="5" on " originDestinationPair". The larger the value of maxOccurs the more memory Xerces requires to build the DFA representation of the content model. If the value is sufficiently large you'll run out of memory. The workaround for this limi

Re: possible bug while validating schemas

2006-10-29 Thread Paul Tomsic
ah, of course. great catch. thank you. is there an obvious way to trap for this? i'm working for a large organization that tends to have 1000's of ppl that could be the maker of the XSD. short of me making an FAQ page of best-practices (which no one will read) can i programatically trap for th

Re: possible bug while validating schemas

2006-10-29 Thread Michael Glavassevich
Hi Paul, You can avoid the OOM error by setting the JAXP secure processing feature [1] or a SecurityManager [2][3]. This puts a limit on the maxOccurs values in the schema. A fatal error is emitted if the limit is exceeded. Thanks. [1] http://xerces.apache.org/xerces2-j/javadocs/api/javax/xml