[jboss-cvs] JBoss Messaging SVN: r2079 - trunk/src/main/org/jboss/messaging/core/tx.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Sat Jan 27 08:53:55 EST 2007
Author: timfox
Date: 2007-01-27 08:53:55 -0500 (Sat, 27 Jan 2007)
New Revision: 2079
Modified:
trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
Log:
Transaction map needs to be ordered for proper recovery
Modified: trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java 2007-01-27 12:12:34 UTC (rev 2078)
+++ trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java 2007-01-27 13:53:55 UTC (rev 2079)
@@ -22,7 +22,9 @@
package org.jboss.messaging.core.tx;
import java.util.ArrayList;
+import java.util.Collections;
import java.util.Iterator;
+import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
@@ -41,8 +43,6 @@
import org.jboss.messaging.core.plugin.contract.PostOffice;
import org.jboss.messaging.core.plugin.postoffice.Binding;
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
-
/**
* This class maintains JMS Server local transactions.
*
@@ -86,7 +86,10 @@
this.idManager = idManager;
- globalToLocalMap = new ConcurrentReaderHashMap();
+ //TODO the map should must be in order for recovery hence the LinkedHashMap
+ //but it would be nice for it to support better concurrency than just
+ //synchronizing everything
+ globalToLocalMap = Collections.synchronizedMap(new LinkedHashMap());
}
// Injection ----------------------------------------
More information about the jboss-cvs-commits
mailing list