cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r768111 - /incubator/cassandra/trunk/src/org/apache/cassandra/db/Memtable.java
Date Fri, 24 Apr 2009 00:52:10 GMT
Author: jbellis
Date: Fri Apr 24 00:52:09 2009
New Revision: 768111

URL: http://svn.apache.org/viewvc?rev=768111&view=rev
Log:
avoid clearing out memtable during flush since it can still be accessed as a
'historial' MT.  clearing during flush can lead to client seeing old data, if the
clear is done before the sstable is completely written (so the next thing to be
checked will be an old sstable).
patch by Sandeep Tata; reviewed by jbellis for #98.

Modified:
    incubator/cassandra/trunk/src/org/apache/cassandra/db/Memtable.java

Modified: incubator/cassandra/trunk/src/org/apache/cassandra/db/Memtable.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/src/org/apache/cassandra/db/Memtable.java?rev=768111&r1=768110&r2=768111&view=diff
==============================================================================
--- incubator/cassandra/trunk/src/org/apache/cassandra/db/Memtable.java (original)
+++ incubator/cassandra/trunk/src/org/apache/cassandra/db/Memtable.java Fri Apr 24 00:52:09
2009
@@ -399,15 +399,12 @@
                 /* Now write the key and value to disk */
                 ssTable.append(partitioner.decorateKey(key), buffer);
                 bf.add(key);
-                columnFamily.clear();
             }
         }
         ssTable.close(bf);
         cfStore.onMemtableFlush(cLogCtx);
         cfStore.storeLocation( ssTable.getDataFileLocation(), bf );
         buffer.close();
-
-        columnFamilies_.clear();
     }
 
     private class MemtableThreadPoolExecutor extends DebuggableThreadPoolExecutor



Mime
View raw message