Author: scheu Date: Tue Apr 15 12:57:09 2008 New Revision: 648395 URL: http://svn.apache.org/viewvc?rev=648395&view=rev Log: WSCOMMONS-321 Contributor:Rich Scheuerle Root cause of for NoSuchElementException (found by JAXWS CTS testing) OMStAXWrapper code was accidentally disabling caching.
The validating test is in Axis2/JAXWS and will be contributed soon. Modified: webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMXMLParserWrapper.java webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMStAXWrapper.java Modified: webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMXMLParserWrapper.java URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMXMLParserWrapper.java?rev=648395&r1=648394&r2=648395&view=diff ============================================================================== --- webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMXMLParserWrapper.java (original) +++ webservices/commons/trunk/modules/axiom/modules/axiom-api/src/main/java/org/apache/axiom/om/OMXMLParserWrapper.java Tue Apr 15 12:57:09 2008 @@ -48,6 +48,11 @@ * @throws OMException */ void setCache(boolean b) throws OMException; + + /** + * @return true if caching + */ + boolean isCache(); /** * Allows to access the underlying parser. Since the parser depends on the underlying Modified: webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMStAXWrapper.java URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMStAXWrapper.java?rev=648395&r1=648394&r2=648395&view=diff ============================================================================== --- webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMStAXWrapper.java (original) +++ webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/OMStAXWrapper.java Tue Apr 15 12:57:09 2008 @@ -209,8 +209,11 @@ try { if (startNode instanceof OMSourcedElement && !cache && builder != null) { + if (!builder.isCache()) { + resetCache = true; + } builder.setCache(true); // bootstrap the navigator - resetCache = true; + } } catch(Throwable t) {} --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]