count a row deletionas one operation towards memtable threshold

patch by Aaron Morton; reviewed by jbellis for CASSANDRA-2519

git-svn-id: https://svn.apache.org/repos/asf/cassandra/branches/cassandra-0.7@1095438 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jonathan Ellis 2011-04-20 15:53:17 +00:00
parent 3c93525db9
commit 23706164f6
2 changed files with 5 additions and 1 deletions

View File

@ -32,6 +32,8 @@
* avoid caching token-only decoratedkeys (CASSANDRA-2416)
* preserve version when streaming data from old sstables (CASSANDRA-2283)
* fix backslash substitutions in CLI (CASSANDRA-2492)
* count a row deletion as one operation towards memtable threshold
(CASSANDRA-2519)
0.7.4

View File

@ -128,7 +128,9 @@ public class Memtable implements Comparable<Memtable>, IFlushable
private void resolve(DecoratedKey key, ColumnFamily cf)
{
currentThroughput.addAndGet(cf.size());
currentOperations.addAndGet(cf.getColumnCount());
currentOperations.addAndGet((cf.getColumnCount() == 0)
? cf.isMarkedForDelete() ? 1 : 0
: cf.getColumnCount());
ColumnFamily oldCf = columnFamilies.putIfAbsent(key, cf);
if (oldCf == null)