From ac9db3b1577cd74892142257b7b0171bb33757f0 Mon Sep 17 00:00:00 2001 From: Eric Anderson Date: Tue, 14 Jul 2015 12:41:19 -0700 Subject: [PATCH] Reduce flow control window for interop tests Many of the interop tests were designed with the default 64 KB flow control window in mind. If we test with 1 MB then it defeats the flow control testing. 65 KB is an arbitrary number, but I chose it to be rather small, but still not the HTTP/2-default 64 KB because implementations have had trouble with applying flow control changes correctly. --- .../main/java/io/grpc/testing/integration/TestServiceClient.java | 1 + .../io/grpc/testing/integration/Http2NettyLocalChannelTest.java | 1 + .../test/java/io/grpc/testing/integration/Http2NettyTest.java | 1 + 3 files changed, 3 insertions(+) diff --git a/interop-testing/src/main/java/io/grpc/testing/integration/TestServiceClient.java b/interop-testing/src/main/java/io/grpc/testing/integration/TestServiceClient.java index 931afae0ab..c8dd30a2b6 100644 --- a/interop-testing/src/main/java/io/grpc/testing/integration/TestServiceClient.java +++ b/interop-testing/src/main/java/io/grpc/testing/integration/TestServiceClient.java @@ -250,6 +250,7 @@ public class TestServiceClient { } } return NettyChannelBuilder.forAddress(new InetSocketAddress(address, serverPort)) + .flowControlWindow(65 * 1024) .negotiationType(useTls ? NegotiationType.TLS : NegotiationType.PLAINTEXT) .sslContext(sslContext) .build(); diff --git a/interop-testing/src/test/java/io/grpc/testing/integration/Http2NettyLocalChannelTest.java b/interop-testing/src/test/java/io/grpc/testing/integration/Http2NettyLocalChannelTest.java index bc7d7306c5..153fb4f555 100644 --- a/interop-testing/src/test/java/io/grpc/testing/integration/Http2NettyLocalChannelTest.java +++ b/interop-testing/src/test/java/io/grpc/testing/integration/Http2NettyLocalChannelTest.java @@ -56,6 +56,7 @@ public class Http2NettyLocalChannelTest extends AbstractTransportTest { startStaticServer( NettyServerBuilder .forAddress(new LocalAddress("in-process-1")) + .flowControlWindow(65 * 1024) .channelType(LocalServerChannel.class)); } diff --git a/interop-testing/src/test/java/io/grpc/testing/integration/Http2NettyTest.java b/interop-testing/src/test/java/io/grpc/testing/integration/Http2NettyTest.java index 23d07d11d0..264263169b 100644 --- a/interop-testing/src/test/java/io/grpc/testing/integration/Http2NettyTest.java +++ b/interop-testing/src/test/java/io/grpc/testing/integration/Http2NettyTest.java @@ -57,6 +57,7 @@ public class Http2NettyTest extends AbstractTransportTest { public static void startServer() { try { startStaticServer(NettyServerBuilder.forPort(serverPort) + .flowControlWindow(65 * 1024) .sslContext(GrpcSslContexts .forServer(TestUtils.loadCert("server1.pem"), TestUtils.loadCert("server1.key")) .ciphers(TestUtils.preferredTestCiphers(), SupportedCipherSuiteFilter.INSTANCE)