You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bookkeeper.apache.org by si...@apache.org on 2018/06/04 22:03:57 UTC

[bookkeeper] 03/09: [TABLE] mark TableClientTest & TableClientSimpleTest as FlakyTest

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

sijie pushed a commit to branch branch-4.7
in repository https://gitbox.apache.org/repos/asf/bookkeeper.git

commit ee7f13755cd4a32f632628de813bdd81949b6b6d
Author: Sijie Guo <si...@apache.org>
AuthorDate: Fri May 25 20:52:50 2018 -0700

    [TABLE] mark TableClientTest & TableClientSimpleTest as FlakyTest
    
    Descriptions of the changes in this PR:
    
    *Motivation*
    
    These two integration tests are flaky on shutting down. Mark them as `FlakyTest` to make CI stable while investigating the issue.
    
    *Changes*
    
    Move `FlakyTest` annotation from bookkeeper-server test jar to bookkeeper-common test jar. So it can be used across multiple modules.
    
    At the same time, remove redundant `FlakyTest` annotation at distributedlog-core module.
    
    Related Issue: #1440
    
    Author: Sijie Guo <si...@apache.org>
    
    Reviewers: Jia Zhai <None>
    
    This closes #1445 from sijie/mark_two_integration_tests_as_flaky
---
 .../common/testing}/annotations/FlakyTest.java          |  2 +-
 .../BookKeeperDiskSpaceWeightedLedgerPlacementTest.java |  2 +-
 .../bookkeeper/client/BookieDecommissionTest.java       |  2 +-
 .../common/annotations/DistributedLogAnnotations.java   |  6 ------
 stream/distributedlog/core/pom.xml                      |  7 +++++++
 .../apache/distributedlog/TestAsyncReaderWriter.java    |  3 ---
 .../org/apache/distributedlog/TestNonBlockingReads.java |  2 --
 .../org/apache/distributedlog/TestRollLogSegments.java  |  6 ------
 .../org/apache/distributedlog/TestZooKeeperClient.java  |  3 ---
 .../distributedlog/admin/TestDistributedLogAdmin.java   | 12 ++----------
 .../apache/distributedlog/bk/TestLedgerAllocator.java   | 17 +++--------------
 .../TestDynamicConfigurationFeatureProvider.java        | 12 ++----------
 tests/integration/cluster/pom.xml                       |  8 ++++++++
 .../integration/stream/StorageAdminClientTest.java      |  7 +++----
 .../tests/integration/stream/TableClientSimpleTest.java |  4 ++--
 .../tests/integration/stream/TableClientTest.java       |  4 ++--
 16 files changed, 32 insertions(+), 65 deletions(-)

diff --git a/bookkeeper-server/src/test/java/org/apache/bookkeeper/test/annotations/FlakyTest.java b/bookkeeper-common/src/test/java/org/apache/bookkeeper/common/testing/annotations/FlakyTest.java
similarity index 95%
rename from bookkeeper-server/src/test/java/org/apache/bookkeeper/test/annotations/FlakyTest.java
rename to bookkeeper-common/src/test/java/org/apache/bookkeeper/common/testing/annotations/FlakyTest.java
index 2890f35..8240cf2 100644
--- a/bookkeeper-server/src/test/java/org/apache/bookkeeper/test/annotations/FlakyTest.java
+++ b/bookkeeper-common/src/test/java/org/apache/bookkeeper/common/testing/annotations/FlakyTest.java
@@ -15,7 +15,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.bookkeeper.test.annotations;
+package org.apache.bookkeeper.common.testing.annotations;
 
 import java.lang.annotation.Documented;
 import java.lang.annotation.Retention;
diff --git a/bookkeeper-server/src/test/java/org/apache/bookkeeper/client/BookKeeperDiskSpaceWeightedLedgerPlacementTest.java b/bookkeeper-server/src/test/java/org/apache/bookkeeper/client/BookKeeperDiskSpaceWeightedLedgerPlacementTest.java
index 72f7c52..fec5dd8 100644
--- a/bookkeeper-server/src/test/java/org/apache/bookkeeper/client/BookKeeperDiskSpaceWeightedLedgerPlacementTest.java
+++ b/bookkeeper-server/src/test/java/org/apache/bookkeeper/client/BookKeeperDiskSpaceWeightedLedgerPlacementTest.java
@@ -32,12 +32,12 @@ import java.util.concurrent.atomic.AtomicBoolean;
 
 import org.apache.bookkeeper.bookie.Bookie;
 import org.apache.bookkeeper.client.BookKeeper.DigestType;
+import org.apache.bookkeeper.common.testing.annotations.FlakyTest;
 import org.apache.bookkeeper.conf.ClientConfiguration;
 import org.apache.bookkeeper.conf.ServerConfiguration;
 import org.apache.bookkeeper.net.BookieSocketAddress;
 import org.apache.bookkeeper.proto.BookieServer;
 import org.apache.bookkeeper.test.BookKeeperClusterTestCase;
-import org.apache.bookkeeper.test.annotations.FlakyTest;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
diff --git a/bookkeeper-server/src/test/java/org/apache/bookkeeper/client/BookieDecommissionTest.java b/bookkeeper-server/src/test/java/org/apache/bookkeeper/client/BookieDecommissionTest.java
index 0e4928e..b55a8c6 100644
--- a/bookkeeper-server/src/test/java/org/apache/bookkeeper/client/BookieDecommissionTest.java
+++ b/bookkeeper-server/src/test/java/org/apache/bookkeeper/client/BookieDecommissionTest.java
@@ -29,10 +29,10 @@ import lombok.extern.slf4j.Slf4j;
 import org.apache.bookkeeper.bookie.Bookie;
 import org.apache.bookkeeper.client.BKException.BKIllegalOpException;
 import org.apache.bookkeeper.client.BookKeeper.DigestType;
+import org.apache.bookkeeper.common.testing.annotations.FlakyTest;
 import org.apache.bookkeeper.conf.ServerConfiguration;
 import org.apache.bookkeeper.meta.ZkLedgerUnderreplicationManager;
 import org.apache.bookkeeper.test.BookKeeperClusterTestCase;
-import org.apache.bookkeeper.test.annotations.FlakyTest;
 import org.junit.Test;
 
 /**
diff --git a/stream/distributedlog/common/src/main/java/org/apache/distributedlog/common/annotations/DistributedLogAnnotations.java b/stream/distributedlog/common/src/main/java/org/apache/distributedlog/common/annotations/DistributedLogAnnotations.java
index a5144b8..c1de7f6 100644
--- a/stream/distributedlog/common/src/main/java/org/apache/distributedlog/common/annotations/DistributedLogAnnotations.java
+++ b/stream/distributedlog/common/src/main/java/org/apache/distributedlog/common/annotations/DistributedLogAnnotations.java
@@ -22,12 +22,6 @@ package org.apache.distributedlog.common.annotations;
  */
 public class DistributedLogAnnotations {
     /**
-     * Annotation to identify flaky tests in DistributedLog.
-     * As and when we find that a test is flaky, we'll add this annotation to it for reference.
-     */
-    public @interface FlakyTest {}
-
-    /**
      * Annotation to specify the occurrence of a compression operation. These are CPU intensive
      * and should be avoided in low-latency paths.
      */
diff --git a/stream/distributedlog/core/pom.xml b/stream/distributedlog/core/pom.xml
index 22ad049..fd6356a 100644
--- a/stream/distributedlog/core/pom.xml
+++ b/stream/distributedlog/core/pom.xml
@@ -60,6 +60,13 @@
       <scope>test</scope>
     </dependency>
     <dependency>
+      <groupId>org.apache.bookkeeper</groupId>
+      <artifactId>bookkeeper-common</artifactId>
+      <version>${project.version}</version>
+      <type>test-jar</type>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
       <groupId>org.apache.distributedlog</groupId>
       <artifactId>distributedlog-common</artifactId>
       <version>${project.parent.version}</version>
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAsyncReaderWriter.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAsyncReaderWriter.java
index 9c40834..75e22ac 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAsyncReaderWriter.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestAsyncReaderWriter.java
@@ -56,7 +56,6 @@ import org.apache.distributedlog.api.LogReader;
 import org.apache.distributedlog.api.LogWriter;
 import org.apache.distributedlog.api.namespace.Namespace;
 import org.apache.distributedlog.api.namespace.NamespaceBuilder;
-import org.apache.distributedlog.common.annotations.DistributedLogAnnotations;
 import org.apache.distributedlog.common.config.ConcurrentBaseConfiguration;
 import org.apache.distributedlog.common.config.ConcurrentConstConfiguration;
 import org.apache.distributedlog.config.DynamicDistributedLogConfiguration;
@@ -826,7 +825,6 @@ public class TestAsyncReaderWriter extends TestDistributedLogBase {
      * Test Case: starting reading when the streams don't exist.
      * {@link https://issues.apache.org/jira/browse/DL-42}
      */
-    @DistributedLogAnnotations.FlakyTest
     @Ignore
     @Test(timeout = 120000)
     public void testSimpleAsyncReadWriteStartEmptyFactory() throws Exception {
@@ -1505,7 +1503,6 @@ public class TestAsyncReaderWriter extends TestDistributedLogBase {
         dlm.close();
     }
 
-    @DistributedLogAnnotations.FlakyTest
     @Test(timeout = 60000)
     public void testAsyncReadMissingLogSegmentsNotification() throws Exception {
         String name = "distrlog-async-reader-missing-zk-notification";
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestNonBlockingReads.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestNonBlockingReads.java
index 4b17a13..ef9f184 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestNonBlockingReads.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestNonBlockingReads.java
@@ -30,7 +30,6 @@ import java.util.concurrent.ScheduledThreadPoolExecutor;
 import java.util.concurrent.TimeUnit;
 import org.apache.distributedlog.api.DistributedLogManager;
 import org.apache.distributedlog.api.LogReader;
-import org.apache.distributedlog.common.annotations.DistributedLogAnnotations;
 import org.apache.distributedlog.exceptions.IdleReaderException;
 import org.apache.distributedlog.util.Utils;
 import org.junit.Assert;
@@ -42,7 +41,6 @@ import org.slf4j.LoggerFactory;
 /**
  * {@link https://issues.apache.org/jira/browse/DL-12}.
  */
-@DistributedLogAnnotations.FlakyTest
 @Ignore
 public class TestNonBlockingReads extends TestDistributedLogBase {
     static final Logger LOG = LoggerFactory.getLogger(TestNonBlockingReads.class);
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestRollLogSegments.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestRollLogSegments.java
index 7a8d33c..a3a3f34 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestRollLogSegments.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestRollLogSegments.java
@@ -33,7 +33,6 @@ import org.apache.bookkeeper.common.concurrent.FutureEventListener;
 import org.apache.bookkeeper.feature.SettableFeature;
 import org.apache.distributedlog.api.DistributedLogManager;
 import org.apache.distributedlog.api.LogReader;
-import org.apache.distributedlog.common.annotations.DistributedLogAnnotations.FlakyTest;
 import org.apache.distributedlog.feature.CoreFeatureKeys;
 import org.apache.distributedlog.impl.logsegment.BKLogSegmentEntryReader;
 import org.apache.distributedlog.util.FailpointUtils;
@@ -42,10 +41,6 @@ import org.junit.Test;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-
-
-
-
 /**
  * Test Cases for RollLogSegments.
  */
@@ -339,7 +334,6 @@ public class TestRollLogSegments extends TestDistributedLogBase {
         assertEquals(expectedReaderPosition, readPosition.getEntryId());
     }
 
-    @FlakyTest
     @Test(timeout = 60000)
     @SuppressWarnings("deprecation")
     public void testCaughtUpReaderOnLogSegmentRolling() throws Exception {
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestZooKeeperClient.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestZooKeeperClient.java
index 0c8daad..022b028 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestZooKeeperClient.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/TestZooKeeperClient.java
@@ -33,7 +33,6 @@ import org.apache.bookkeeper.stats.NullStatsLogger;
 import org.apache.bookkeeper.zookeeper.BoundExponentialBackoffRetryPolicy;
 import org.apache.distributedlog.ZooKeeperClient.Credentials;
 import org.apache.distributedlog.ZooKeeperClient.DigestCredentials;
-import org.apache.distributedlog.common.annotations.DistributedLogAnnotations;
 import org.apache.zookeeper.CreateMode;
 import org.apache.zookeeper.KeeperException;
 import org.apache.zookeeper.WatchedEvent;
@@ -265,7 +264,6 @@ public class TestZooKeeperClient extends ZooKeeperClusterTestCase {
     /**
      * {@link https://issues.apache.org/jira/browse/DL-34}.
      */
-    @DistributedLogAnnotations.FlakyTest
     @Ignore
     @Test(timeout = 60000)
     public void testAclAuthSpansExpiration() throws Exception {
@@ -290,7 +288,6 @@ public class TestZooKeeperClient extends ZooKeeperClusterTestCase {
     /**
      * {@link https://issues.apache.org/jira/browse/DL-34}.
      */
-    @DistributedLogAnnotations.FlakyTest
     @Ignore
     @Test(timeout = 60000)
     public void testAclAuthSpansExpirationNonRetryableClient() throws Exception {
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/admin/TestDistributedLogAdmin.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/admin/TestDistributedLogAdmin.java
index f5cd75e..b48d002 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/admin/TestDistributedLogAdmin.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/admin/TestDistributedLogAdmin.java
@@ -23,6 +23,7 @@ import static org.junit.Assert.fail;
 
 import java.net.URI;
 import java.util.concurrent.CompletableFuture;
+import org.apache.bookkeeper.common.testing.annotations.FlakyTest;
 import org.apache.distributedlog.DLMTestUtil;
 import org.apache.distributedlog.DLSN;
 import org.apache.distributedlog.DistributedLogConfiguration;
@@ -35,7 +36,6 @@ import org.apache.distributedlog.api.AsyncLogReader;
 import org.apache.distributedlog.api.DistributedLogManager;
 import org.apache.distributedlog.api.namespace.Namespace;
 import org.apache.distributedlog.api.namespace.NamespaceBuilder;
-import org.apache.distributedlog.common.annotations.DistributedLogAnnotations;
 import org.apache.distributedlog.exceptions.UnexpectedException;
 import org.apache.distributedlog.metadata.DryrunLogSegmentMetadataStoreUpdater;
 import org.apache.distributedlog.metadata.LogSegmentMetadataStoreUpdater;
@@ -44,12 +44,9 @@ import org.apache.zookeeper.CreateMode;
 import org.apache.zookeeper.ZooDefs;
 import org.junit.After;
 import org.junit.Before;
-import org.junit.Ignore;
-import org.junit.Test;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-
 /**
  * TestDistributedLogAdmin.
  */
@@ -73,12 +70,7 @@ public class TestDistributedLogAdmin extends TestDistributedLogBase {
         zooKeeperClient.close();
     }
 
-    /**
-     * {@link https://issues.apache.org/jira/browse/DL-44}.
-     */
-    @DistributedLogAnnotations.FlakyTest
-    @Ignore
-    @Test(timeout = 60000)
+    @FlakyTest("https://issues.apache.org/jira/browse/DL-44")
     @SuppressWarnings("deprecation")
     public void testChangeSequenceNumber() throws Exception {
         DistributedLogConfiguration confLocal = new DistributedLogConfiguration();
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/bk/TestLedgerAllocator.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/bk/TestLedgerAllocator.java
index 0270a4a..1786fe4 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/bk/TestLedgerAllocator.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/bk/TestLedgerAllocator.java
@@ -31,6 +31,7 @@ import org.apache.bookkeeper.client.BKException;
 import org.apache.bookkeeper.client.BookKeeper;
 import org.apache.bookkeeper.client.LedgerEntry;
 import org.apache.bookkeeper.client.LedgerHandle;
+import org.apache.bookkeeper.common.testing.annotations.FlakyTest;
 import org.apache.bookkeeper.versioning.LongVersion;
 import org.apache.bookkeeper.versioning.Versioned;
 import org.apache.distributedlog.BookKeeperClient;
@@ -41,7 +42,6 @@ import org.apache.distributedlog.TestZooKeeperClientBuilder;
 import org.apache.distributedlog.ZooKeeperClient;
 import org.apache.distributedlog.bk.SimpleLedgerAllocator.AllocationException;
 import org.apache.distributedlog.bk.SimpleLedgerAllocator.Phase;
-import org.apache.distributedlog.common.annotations.DistributedLogAnnotations;
 import org.apache.distributedlog.exceptions.ZKException;
 import org.apache.distributedlog.util.Transaction.OpListener;
 import org.apache.distributedlog.util.Utils;
@@ -54,7 +54,6 @@ import org.apache.zookeeper.ZooDefs;
 import org.apache.zookeeper.data.Stat;
 import org.junit.After;
 import org.junit.Before;
-import org.junit.Ignore;
 import org.junit.Rule;
 import org.junit.Test;
 import org.junit.rules.TestName;
@@ -125,12 +124,7 @@ public class TestLedgerAllocator extends TestDistributedLogBase {
         return Utils.ioResult(SimpleLedgerAllocator.of(allocationPath, null, newQuorumConfigProvider(conf), zkc, bkc));
     }
 
-    /**
-     * {@link https://issues.apache.org/jira/browse/DL-43}.
-     */
-    @DistributedLogAnnotations.FlakyTest
-    @Ignore
-    @Test(timeout = 60000)
+    @FlakyTest("https://issues.apache.org/jira/browse/DL-43")
     public void testAllocation() throws Exception {
         String allocationPath = "/allocation1";
         SimpleLedgerAllocator allocator = createAllocator(allocationPath);
@@ -310,12 +304,7 @@ public class TestLedgerAllocator extends TestDistributedLogBase {
                 dlConf.getBKDigestPW().getBytes(UTF_8));
     }
 
-    /**
-     * {@link https://issues.apache.org/jira/browse/DL-26}.
-     */
-    @DistributedLogAnnotations.FlakyTest
-    @Ignore
-    @Test(timeout = 60000)
+    @FlakyTest("https://issues.apache.org/jira/browse/DL-26")
     public void testCloseAllocatorAfterConfirm() throws Exception {
         String allocationPath = "/allocation2";
         SimpleLedgerAllocator allocator = createAllocator(allocationPath);
diff --git a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/feature/TestDynamicConfigurationFeatureProvider.java b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/feature/TestDynamicConfigurationFeatureProvider.java
index 536a6c0..e395345 100644
--- a/stream/distributedlog/core/src/test/java/org/apache/distributedlog/feature/TestDynamicConfigurationFeatureProvider.java
+++ b/stream/distributedlog/core/src/test/java/org/apache/distributedlog/feature/TestDynamicConfigurationFeatureProvider.java
@@ -21,16 +21,13 @@ import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertTrue;
 
+import org.apache.bookkeeper.common.testing.annotations.FlakyTest;
 import org.apache.bookkeeper.feature.Feature;
 import org.apache.bookkeeper.stats.NullStatsLogger;
 import org.apache.distributedlog.DistributedLogConfiguration;
-import org.apache.distributedlog.common.annotations.DistributedLogAnnotations;
 import org.apache.distributedlog.common.config.PropertiesWriter;
-import org.junit.Ignore;
 import org.junit.Test;
 
-
-
 /**
  * Test case for dynamic configuration based feature provider.
  */
@@ -79,12 +76,7 @@ public class TestDynamicConfigurationFeatureProvider {
         provider.stop();
     }
 
-    /**
-     * {@link https://issues.apache.org/jira/browse/DL-40}.
-     */
-    @DistributedLogAnnotations.FlakyTest
-    @Ignore
-    @Test(timeout = 60000)
+    @FlakyTest("https://issues.apache.org/jira/browse/DL-40")
     public void testLoadFeaturesFromOverlay() throws Exception {
         PropertiesWriter writer = new PropertiesWriter();
         writer.setProperty("feature_1", "10000");
diff --git a/tests/integration/cluster/pom.xml b/tests/integration/cluster/pom.xml
index 422269a..b33b7ab 100644
--- a/tests/integration/cluster/pom.xml
+++ b/tests/integration/cluster/pom.xml
@@ -51,6 +51,14 @@
       <scope>test</scope>
     </dependency>
 
+    <dependency>
+      <groupId>org.apache.bookkeeper</groupId>
+      <artifactId>bookkeeper-common</artifactId>
+      <version>${project.version}</version>
+      <type>test-jar</type>
+      <scope>test</scope>
+    </dependency>
+
   </dependencies>
 
   <build>
diff --git a/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/StorageAdminClientTest.java b/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/StorageAdminClientTest.java
index 569cf7c..15198a3 100644
--- a/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/StorageAdminClientTest.java
+++ b/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/StorageAdminClientTest.java
@@ -32,7 +32,7 @@ import org.apache.bookkeeper.clients.exceptions.NamespaceNotFoundException;
 import org.apache.bookkeeper.clients.exceptions.StreamExistsException;
 import org.apache.bookkeeper.clients.exceptions.StreamNotFoundException;
 import org.apache.bookkeeper.common.concurrent.FutureUtils;
-import org.apache.bookkeeper.common.util.OrderedScheduler;
+import org.apache.bookkeeper.common.testing.annotations.FlakyTest;
 import org.apache.bookkeeper.stream.proto.NamespaceConfiguration;
 import org.apache.bookkeeper.stream.proto.NamespaceProperties;
 import org.apache.bookkeeper.stream.proto.StreamConfiguration;
@@ -42,7 +42,6 @@ import org.apache.bookkeeper.stream.proto.storage.StatusCode;
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Rule;
-import org.junit.Test;
 import org.junit.rules.TestName;
 
 /**
@@ -67,7 +66,7 @@ public class StorageAdminClientTest extends StreamClusterTestBase {
         }
     }
 
-    @Test
+    @FlakyTest("https://github.com/apache/bookkeeper/issues/1440")
     public void testNamespaceAPI() throws Exception {
         // Create a namespace
         String nsName = testName.getMethodName();
@@ -123,7 +122,7 @@ public class StorageAdminClientTest extends StreamClusterTestBase {
         }
     }
 
-    @Test
+    @FlakyTest("https://github.com/apache/bookkeeper/issues/1440")
     public void testStreamAPI() throws Exception {
         // Create a namespace
         String nsName = testName.getMethodName() + "_ns";
diff --git a/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/TableClientSimpleTest.java b/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/TableClientSimpleTest.java
index d1ff091..e88dfc3 100644
--- a/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/TableClientSimpleTest.java
+++ b/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/TableClientSimpleTest.java
@@ -40,6 +40,7 @@ import org.apache.bookkeeper.api.kv.result.Code;
 import org.apache.bookkeeper.api.kv.result.KeyValue;
 import org.apache.bookkeeper.clients.admin.StorageAdminClient;
 import org.apache.bookkeeper.clients.config.StorageClientSettings;
+import org.apache.bookkeeper.common.testing.annotations.FlakyTest;
 import org.apache.bookkeeper.stream.proto.NamespaceConfiguration;
 import org.apache.bookkeeper.stream.proto.NamespaceProperties;
 import org.apache.bookkeeper.stream.proto.StreamConfiguration;
@@ -47,7 +48,6 @@ import org.apache.bookkeeper.stream.proto.StreamProperties;
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Rule;
-import org.junit.Test;
 import org.junit.rules.TestName;
 
 /**
@@ -89,7 +89,7 @@ public class TableClientSimpleTest extends StreamClusterTestBase {
         return Unpooled.wrappedBuffer(String.format("test-val-%06d", i).getBytes(UTF_8));
     }
 
-    @Test
+    @FlakyTest("https://github.com/apache/bookkeeper/issues/1440")
     public void testTableSimpleAPI() throws Exception {
         // Create a namespace
         NamespaceConfiguration nsConf = NamespaceConfiguration.newBuilder()
diff --git a/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/TableClientTest.java b/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/TableClientTest.java
index 0dff7fa..6a287da 100644
--- a/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/TableClientTest.java
+++ b/tests/integration/cluster/src/test/java/org/apache/bookkeeper/tests/integration/stream/TableClientTest.java
@@ -50,6 +50,7 @@ import org.apache.bookkeeper.api.kv.result.TxnResult;
 import org.apache.bookkeeper.clients.admin.StorageAdminClient;
 import org.apache.bookkeeper.clients.config.StorageClientSettings;
 import org.apache.bookkeeper.common.concurrent.FutureUtils;
+import org.apache.bookkeeper.common.testing.annotations.FlakyTest;
 import org.apache.bookkeeper.stream.proto.NamespaceConfiguration;
 import org.apache.bookkeeper.stream.proto.NamespaceProperties;
 import org.apache.bookkeeper.stream.proto.StreamConfiguration;
@@ -57,7 +58,6 @@ import org.apache.bookkeeper.stream.proto.StreamProperties;
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Rule;
-import org.junit.Test;
 import org.junit.rules.TestName;
 
 /**
@@ -100,7 +100,7 @@ public class TableClientTest extends StreamClusterTestBase {
         return Unpooled.wrappedBuffer(String.format("test-val-%06d", i).getBytes(UTF_8));
     }
 
-    @Test
+    @FlakyTest("https://github.com/apache/bookkeeper/issues/1440")
     public void testTableAPI() throws Exception {
         // Create a namespace
         NamespaceConfiguration nsConf = NamespaceConfiguration.newBuilder()

-- 
To stop receiving notification emails like this one, please contact
sijie@apache.org.