You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by mc...@apache.org on 2020/04/04 18:47:56 UTC

[cassandra] branch trunk updated: Initialize commitlog for ConnectionBurnTest due to CASSANDRA-15295

This is an automated email from the ASF dual-hosted git repository.

mck pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/cassandra.git


The following commit(s) were added to refs/heads/trunk by this push:
     new e2d2bfd  Initialize commitlog for ConnectionBurnTest due to CASSANDRA-15295
e2d2bfd is described below

commit e2d2bfd9ccd5fc5875ea9eae571c42732e701193
Author: Zhao Yang <zh...@gmail.com>
AuthorDate: Sun Apr 5 00:54:55 2020 +0800

    Initialize commitlog for ConnectionBurnTest due to CASSANDRA-15295
    
     patch by Zhao Yang; reviewed by Mick Semb Wever for CASSANDRA-15692
---
 test/burn/org/apache/cassandra/net/ConnectionBurnTest.java | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/test/burn/org/apache/cassandra/net/ConnectionBurnTest.java b/test/burn/org/apache/cassandra/net/ConnectionBurnTest.java
index 57eb726..a421f3e 100644
--- a/test/burn/org/apache/cassandra/net/ConnectionBurnTest.java
+++ b/test/burn/org/apache/cassandra/net/ConnectionBurnTest.java
@@ -43,6 +43,7 @@ import java.util.stream.IntStream;
 import com.google.common.collect.ImmutableList;
 import com.google.common.util.concurrent.Uninterruptibles;
 
+import org.junit.BeforeClass;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -50,6 +51,7 @@ import io.netty.channel.Channel;
 import net.openhft.chronicle.core.util.ThrowingBiConsumer;
 import net.openhft.chronicle.core.util.ThrowingRunnable;
 import org.apache.cassandra.config.DatabaseDescriptor;
+import org.apache.cassandra.db.commitlog.CommitLog;
 import org.apache.cassandra.io.IVersionedSerializer;
 import org.apache.cassandra.io.util.DataInputPlus;
 import org.apache.cassandra.io.util.DataOutputPlus;
@@ -249,6 +251,9 @@ public class ConnectionBurnTest
             return result;
         }
 
+        /**
+         * Test connections with broken messages, live in-flight bytes updates, reconnect
+         */
         public void run() throws ExecutionException, InterruptedException, NoSuchFieldException, IllegalAccessException, TimeoutException
         {
             Reporters reporters = new Reporters(endpoints, connections);
@@ -642,9 +647,17 @@ public class ConnectionBurnTest
 
     public static void main(String[] args) throws ExecutionException, InterruptedException, NoSuchFieldException, IllegalAccessException, TimeoutException
     {
+        setup();
         new ConnectionBurnTest().test();
     }
 
+    @BeforeClass
+    public static void setup()
+    {
+        // since CASSANDRA-15295, commitlog needs to be manually started.
+        CommitLog.instance.start();
+    }
+
     @org.junit.Test
     public void test() throws ExecutionException, InterruptedException, NoSuchFieldException, IllegalAccessException, TimeoutException
     {
@@ -659,5 +672,4 @@ public class ConnectionBurnTest
                               .withTcpUserTimeoutInMS(0));
         MessagingService.instance().socketFactory.shutdownNow();
     }
-
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org