commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ozeigerm...@apache.org
Subject svn commit: r348458 - in /jakarta/commons/proper/transaction/trunk: RELEASE-NOTES.txt src/java/org/apache/commons/transaction/file/FileResourceManager.java
Date Wed, 23 Nov 2005 15:19:52 GMT
Author: ozeigermann
Date: Wed Nov 23 07:19:45 2005
New Revision: 348458

URL: http://svn.apache.org/viewcvs?rev=348458&view=rev
Log:
Reduced likelyhood of clash between internally generated and external tx id in generatedUniqueTxId

Modified:
    jakarta/commons/proper/transaction/trunk/RELEASE-NOTES.txt
    jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java

Modified: jakarta/commons/proper/transaction/trunk/RELEASE-NOTES.txt
URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/transaction/trunk/RELEASE-NOTES.txt?rev=348458&r1=348457&r2=348458&view=diff
==============================================================================
--- jakarta/commons/proper/transaction/trunk/RELEASE-NOTES.txt (original)
+++ jakarta/commons/proper/transaction/trunk/RELEASE-NOTES.txt Wed Nov 23 07:19:45 2005
@@ -29,6 +29,7 @@
 - Fixed bugzilla issue 35201. Maps in AbstractXAResource now are synchronized to avoid problems
in multi threaded scenarios.
 - Fixed bug reported by Niklas Gustavsson on http://www.mail-archive.com/commons-dev@jakarta.apache.org/msg69441.html.
   Failed deletion of a file now throws an exception and enters an error state upon commit.
+- Reduced likelyhood of clash between internally generated and external tx id in generatedUniqueTxId
 
 KNOWN ISSUES
 ------------

Modified: jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java?rev=348458&r1=348457&r2=348458&view=diff
==============================================================================
--- jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java
(original)
+++ jakarta/commons/proper/transaction/trunk/src/java/org/apache/commons/transaction/file/FileResourceManager.java
Wed Nov 23 07:19:45 2005
@@ -199,6 +199,8 @@
     
     protected ResourceIdToPathMapper idMapper = null;
 
+    protected int idCnt = 0;
+    
     /*
      * --- ctor and general getter / setter methods ---
      *
@@ -884,7 +886,8 @@
         String txId;
         synchronized (globalTransactions) {
             do {
-                txId = Long.toHexString(System.currentTimeMillis());
+                txId = Long.toHexString(System.currentTimeMillis()) + "-"
+                        + Integer.toHexString(idCnt);
                 // XXX busy loop
             } while (getContext(txId) != null);
         }



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


Mime
View raw message