directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject [directory-mavibot] branch single-value updated: Added the txnCounter logs and in toString()
Date Tue, 02 Jan 2018 23:33:51 GMT
This is an automated email from the ASF dual-hosted git repository.

elecharny pushed a commit to branch single-value
in repository https://gitbox.apache.org/repos/asf/directory-mavibot.git


The following commit(s) were added to refs/heads/single-value by this push:
     new 1d6d676  Added the txnCounter logs and in toString()
1d6d676 is described below

commit 1d6d67695924a5f0cf3ad190e4d00b0b0bd241a0
Author: Emmanuel L├ęcharny <elecharny@symas.com>
AuthorDate: Wed Jan 3 00:33:49 2018 +0100

    Added the txnCounter logs and in toString()
---
 .../org/apache/directory/mavibot/btree/RecordManagerHeader.java  | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/mavibot/src/main/java/org/apache/directory/mavibot/btree/RecordManagerHeader.java
b/mavibot/src/main/java/org/apache/directory/mavibot/btree/RecordManagerHeader.java
index 581e33d..dbdae17 100644
--- a/mavibot/src/main/java/org/apache/directory/mavibot/btree/RecordManagerHeader.java
+++ b/mavibot/src/main/java/org/apache/directory/mavibot/btree/RecordManagerHeader.java
@@ -31,6 +31,9 @@ import org.slf4j.LoggerFactory;
  * | current CP offset   | 8 bytes : The offset of the current CopiedPages B-tree
  * +---------------------+
  * </pre>
+ * 
+ * We additionally keep a track of the number of read transaction using an instance.
+ * 
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class RecordManagerHeader
@@ -291,6 +294,9 @@ public class RecordManagerHeader
                     }
                 }
             }
+            
+            sb.append( "Nb transactions :" ).append( txnCounter.get() );
+            sb.append( '\n' );
 
             LOG_PAGES.debug( "Update RM Header : \n{}", sb.toString() );
         }
@@ -315,7 +321,8 @@ public class RecordManagerHeader
         sb.append( "    BOB current offset :  " ).append( String.format( "%16x", currentBtreeOfBtreesOffset
) ).append( '\n' );
         sb.append( "    CPB current offset :  " ).append( String.format( "%16x", currentCopiedPagesBtreeOffset
) ).append( '\n' );
         sb.append( "    last offset :         " ).append( String.format( "%16x", lastOffset
) ).append( '\n' );
-        
+        sb.append( "    Nb transactions :     " ).append( txnCounter.get() ).append( '\n'
);
+
         if ( btreeMap.isEmpty() )
         {
             sb.append( "    No managed B-trees\n" );

-- 
To stop receiving notification emails like this one, please contact
['"commits@directory.apache.org" <commits@directory.apache.org>'].

Mime
View raw message