You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commons-dev@ws.apache.org by sc...@apache.org on 2007/09/05 21:48:47 UTC

svn commit: r573036 - /webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListImplFactory.java

Author: scheu
Date: Wed Sep  5 12:48:45 2007
New Revision: 573036

URL: http://svn.apache.org/viewvc?rev=573036&view=rev
Log:
WSCOMMONS-241
Contributor:Rich Scheuerle
Fix Concurrent Modification of namespace table in the OMLinkedListImplFactory.

Modified:
    webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListImplFactory.java

Modified: webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListImplFactory.java
URL: http://svn.apache.org/viewvc/webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListImplFactory.java?rev=573036&r1=573035&r2=573036&view=diff
==============================================================================
--- webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListImplFactory.java (original)
+++ webservices/commons/trunk/modules/axiom/modules/axiom-impl/src/main/java/org/apache/axiom/om/impl/llom/factory/OMLinkedListImplFactory.java Wed Sep  5 12:48:45 2007
@@ -44,7 +44,7 @@
 import org.apache.axiom.om.impl.llom.OMTextImpl;
 
 import javax.xml.namespace.QName;
-import java.util.HashMap;
+import java.util.Hashtable;
 import java.util.Map;
 
 /** Class OMLinkedListImplFactory */
@@ -54,8 +54,9 @@
     /**
      * This is a map of namespaces with the namespace URI as the key and Namespace object itself as
      * the value.
+     * OMFactories are shared across threads.  The Hashtable is necessary to prevent concurrent modification exceptions.
      */
-    protected Map namespaceTable = new HashMap(5);
+    protected Map namespaceTable = new Hashtable(5);
 
     /**
      * Method createOMElement.



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