commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Russell Neufeld <rneuf...@archivas.com>
Subject JXPath concurrency exceptions
Date Wed, 09 Jun 2004 22:47:35 GMT
Hi all,

	I've been using jxpath v1.1 to implement a central store of system configuration backed 
by an XML document.  I read the XML document into a DOM tree and then execute a series of
jxpath
getValue() calls on the DOM to get configuration values.  That all works great except under
heavy
load, say 100 threads looking for config values.  Every so often I get the following exception.
Do all calls to getValue() need to be synchronized?  That would be unfortunate. Is there any

alternative?  Is this a bug that's fixable in the jxpath source?

	Thanks.  Love jxpath by the way.

		Russ


java.util.ConcurrentModificationException
      at java.util.HashMap$HashIterator.nextEntry(HashMap.java:-3)
      at java.util.HashMap$EntryIterator.next(HashMap.java:905)
      at org.apache.commons.jxpath.ri.JXPathContextReferenceImpl.cleanupCache(JXPathContextReferenceImpl.java:270)
      at org.apache.commons.jxpath.ri.JXPathContextReferenceImpl.compileExpression(JXPathContextReferenceImpl.java:-3)
      at org.apache.commons.jxpath.ri.JXPathContextReferenceImpl.getValue(JXPathContextReferenceImpl.java:-3)
      at com.ris.common.Configuration.getProperty(Configuration.java:-3)


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message