You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by sl...@apache.org on 2012/11/21 20:18:03 UTC
[2/2] git commit: Fix unit test failures
Fix unit test failures
patch by slebresne; reviewed by yukim for CASSANDRA-4980
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/9366fb32
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/9366fb32
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/9366fb32
Branch: refs/heads/cassandra-1.2
Commit: 9366fb32305a59822c7b914788995f2b11d92064
Parents: e2df26b
Author: Sylvain Lebresne <sy...@datastax.com>
Authored: Wed Nov 21 20:16:50 2012 +0100
Committer: Sylvain Lebresne <sy...@datastax.com>
Committed: Wed Nov 21 20:16:50 2012 +0100
----------------------------------------------------------------------
.../apache/cassandra/service/StorageService.java | 2 --
.../apache/cassandra/db/RecoveryManager2Test.java | 4 ++++
2 files changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cassandra/blob/9366fb32/src/java/org/apache/cassandra/service/StorageService.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/service/StorageService.java b/src/java/org/apache/cassandra/service/StorageService.java
index 17b21d9..567d829 100644
--- a/src/java/org/apache/cassandra/service/StorageService.java
+++ b/src/java/org/apache/cassandra/service/StorageService.java
@@ -389,8 +389,6 @@ public class StorageService implements IEndpointStateChangeSubscriber, StorageSe
{
throw new AssertionError(e);
}
-
- Schema.instance.updateVersionAndAnnounce();
}
public synchronized void initServer() throws ConfigurationException
http://git-wip-us.apache.org/repos/asf/cassandra/blob/9366fb32/test/unit/org/apache/cassandra/db/RecoveryManager2Test.java
----------------------------------------------------------------------
diff --git a/test/unit/org/apache/cassandra/db/RecoveryManager2Test.java b/test/unit/org/apache/cassandra/db/RecoveryManager2Test.java
index c77dec3..9787c7f 100644
--- a/test/unit/org/apache/cassandra/db/RecoveryManager2Test.java
+++ b/test/unit/org/apache/cassandra/db/RecoveryManager2Test.java
@@ -32,6 +32,7 @@ import org.apache.cassandra.SchemaLoader;
import org.apache.cassandra.db.compaction.CompactionManager;
import org.apache.cassandra.db.commitlog.CommitLog;
import org.apache.cassandra.utils.ByteBufferUtil;
+import org.apache.cassandra.utils.FBUtilities;
public class RecoveryManager2Test extends SchemaLoader
{
@@ -41,6 +42,9 @@ public class RecoveryManager2Test extends SchemaLoader
/* test that commit logs do not replay flushed data */
public void testWithFlush() throws Exception
{
+ // Flush everything that may be in the commit log now to start fresh
+ FBUtilities.waitOnFutures(Table.open(Table.SYSTEM_KS).flush());
+
CompactionManager.instance.disableAutoCompaction();
// add a row to another CF so we test skipping mutations within a not-entirely-flushed CF