瀏覽代碼

Force single-node cluster in NettyHttpRequestSizeLimitIT

Daniel Mitterdorfer 9 年之前
父節點
當前提交
edf010f878
共有 1 個文件被更改,包括 4 次插入2 次删除
  1. 4 2
      core/src/test/java/org/elasticsearch/http/netty/NettyHttpRequestSizeLimitIT.java

+ 4 - 2
core/src/test/java/org/elasticsearch/http/netty/NettyHttpRequestSizeLimitIT.java

@@ -39,9 +39,12 @@ import static org.hamcrest.Matchers.greaterThan;
 import static org.hamcrest.Matchers.hasSize;
 
 /**
+ * This test checks that in-flight requests are limited on HTTP level and that requests that are excluded from limiting can pass.
  *
+ * As the same setting is also used to limit in-flight requests on transport level, we avoid transport messages by forcing
+ * a single node "cluster".
  */
-@ClusterScope(scope = Scope.TEST, supportsDedicatedMasters = false, numDataNodes = 1)
+@ClusterScope(scope = Scope.TEST, supportsDedicatedMasters = false, numClientNodes = 0, numDataNodes = 1)
 public class NettyHttpRequestSizeLimitIT extends ESIntegTestCase {
     private static final ByteSizeValue LIMIT = new ByteSizeValue(2, ByteSizeUnit.KB);
 
@@ -89,7 +92,6 @@ public class NettyHttpRequestSizeLimitIT extends ESIntegTestCase {
         }
     }
 
-    @AwaitsFix(bugUrl = "muted while investigating")
     public void testDoesNotLimitExcludedRequests() throws Exception {
         ensureGreen();