openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From curti...@apache.org
Subject svn commit: r1406228 - /openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java
Date Tue, 06 Nov 2012 17:17:05 GMT
Author: curtisr7
Date: Tue Nov  6 17:17:04 2012
New Revision: 1406228

URL: http://svn.apache.org/viewvc?rev=1406228&view=rev
Log:
OPENJPA-2292: Use java.util.IdentityHashMap in BrokerImpl.initializeOperatingSet to reduce
object allocations.

Modified:
    openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java

Modified: openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java?rev=1406228&r1=1406227&r2=1406228&view=diff
==============================================================================
--- openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java (original)
+++ openjpa/trunk/openjpa-kernel/src/main/java/org/apache/openjpa/kernel/BrokerImpl.java Tue
Nov  6 17:17:04 2012
@@ -32,6 +32,7 @@ import java.util.Collection;
 import java.util.Collections;
 import java.util.HashMap;
 import java.util.HashSet;
+import java.util.IdentityHashMap;
 import java.util.Iterator;
 import java.util.LinkedHashSet;
 import java.util.LinkedList;
@@ -392,8 +393,9 @@ public class BrokerImpl
             beginInternal();
     }
 
+    @SuppressWarnings("unchecked")
     private void initializeOperatingSet() {
-        _operating = MapBackedSet.decorate(new IdentityMap());
+        _operating = MapBackedSet.decorate(new IdentityHashMap<Object, Object>());
     }
     
     /**



Mime
View raw message