mirror of https://github.com/apache/cassandra
merge from 2.0
This commit is contained in:
commit
e0718bcdfb
|
|
@ -23,6 +23,7 @@
|
|||
* Add logging levels (minimal, normal or verbose) to stress tool (CASSANDRA-6849)
|
||||
* Fix race condition in Batch CLE (CASSANDRA-6860)
|
||||
Merged from 2.0:
|
||||
* Log more information when exceeding tombstone_warn_threshold (CASSANDRA-6865)
|
||||
* Fix truncate to not abort due to unreachable fat clients (CASSANDRA-6864)
|
||||
* Fix schema concurrency exceptions (CASSANDRA-6841)
|
||||
* Fix leaking validator FH in StreamWriter (CASSANDRA-6832)
|
||||
|
|
|
|||
|
|
@ -220,8 +220,24 @@ public class SliceQueryFilter implements IDiskAtomFilter
|
|||
|
||||
Tracing.trace("Read {} live and {} tombstoned cells", columnCounter.live(), columnCounter.ignored());
|
||||
if (respectTombstoneThresholds() && columnCounter.ignored() > DatabaseDescriptor.getTombstoneWarnThreshold())
|
||||
logger.warn("Read {} live and {} tombstoned cells in {}.{} (see tombstone_warn_threshold)",
|
||||
columnCounter.live(), columnCounter.ignored(), container.metadata().ksName, container.metadata().cfName);
|
||||
{
|
||||
StringBuilder sb = new StringBuilder();
|
||||
AbstractType<?> type = container.metadata().comparator;
|
||||
for (ColumnSlice sl : slices)
|
||||
{
|
||||
if (sl == null)
|
||||
continue;
|
||||
|
||||
sb.append('[');
|
||||
sb.append(type.getString(sl.start));
|
||||
sb.append('-');
|
||||
sb.append(type.getString(sl.finish));
|
||||
sb.append(']');
|
||||
}
|
||||
|
||||
logger.warn("Read {} live and {} tombstoned cells in {}.{} (see tombstone_warn_threshold). {} columns was requested, slices={}, delInfo={}",
|
||||
columnCounter.live(), columnCounter.ignored(), container.metadata().ksName, container.metadata().cfName, count, sb, container.deletionInfo());
|
||||
}
|
||||
}
|
||||
|
||||
protected boolean respectTombstoneThresholds()
|
||||
|
|
|
|||
|
|
@ -177,18 +177,18 @@ public class CqlTableTest extends PigTestBase
|
|||
pig.registerQuery("STORE recs INTO 'cql://cql3ks/collectiontable?" + defaultParameters + "&output_query=update+cql3ks.collectiontable+set+n+%3D+%3F' USING CqlStorage();");
|
||||
pig.executeBatch();
|
||||
|
||||
//(book2,((m,mm),(n,nn)))
|
||||
//(book3,((m,mm),(n,nn)))
|
||||
//(book4,((m,mm),(n,nn)))
|
||||
//(book1,((m,mm),(n,nn)))
|
||||
//(book2,((key2, value2),(m,mm),(n,nn)))
|
||||
//(book3,((key3, value3),(m,mm),(n,nn)))
|
||||
//(book4,((key4, value4),(m,mm),(n,nn)))
|
||||
//(book1,((key1, value1),(m,mm),(n,nn)))
|
||||
pig.registerQuery("result= LOAD 'cql://cql3ks/collectiontable?" + defaultParameters + "' USING CqlStorage();");
|
||||
Iterator<Tuple> it = pig.openIterator("result");
|
||||
if (it.hasNext()) {
|
||||
while (it.hasNext()) {
|
||||
Tuple t = it.next();
|
||||
Tuple t1 = (Tuple) t.get(1);
|
||||
Assert.assertEquals(t1.size(), 2);
|
||||
Tuple element1 = (Tuple) t1.get(0);
|
||||
Tuple element2 = (Tuple) t1.get(1);
|
||||
Assert.assertEquals(t1.size(), 3);
|
||||
Tuple element1 = (Tuple) t1.get(1);
|
||||
Tuple element2 = (Tuple) t1.get(2);
|
||||
Assert.assertEquals(element1.get(0), "m");
|
||||
Assert.assertEquals(element1.get(1), "mm");
|
||||
Assert.assertEquals(element2.get(0), "n");
|
||||
|
|
|
|||
Loading…
Reference in New Issue