aboutsummaryrefslogtreecommitdiffstats
path: root/vespa-feed-client
diff options
context:
space:
mode:
authorBjørn Christian Seime <bjorncs@yahooinc.com>2023-07-07 14:34:27 +0200
committerBjørn Christian Seime <bjorncs@yahooinc.com>2023-07-07 14:34:27 +0200
commitde0e433e5a6289328b3a128f7c4a1a9747ec84e1 (patch)
tree73479e4e194df7b93504f6a8fb4b9d96ca4dbb52 /vespa-feed-client
parent3fbac464d07b4571ce990a81a31c9712cd9a8438 (diff)
Use large initial windows
Diffstat (limited to 'vespa-feed-client')
-rw-r--r--vespa-feed-client/src/main/java/ai/vespa/feed/client/impl/JettyCluster.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/vespa-feed-client/src/main/java/ai/vespa/feed/client/impl/JettyCluster.java b/vespa-feed-client/src/main/java/ai/vespa/feed/client/impl/JettyCluster.java
index 4f919167520..261454c710f 100644
--- a/vespa-feed-client/src/main/java/ai/vespa/feed/client/impl/JettyCluster.java
+++ b/vespa-feed-client/src/main/java/ai/vespa/feed/client/impl/JettyCluster.java
@@ -119,6 +119,10 @@ class JettyCluster implements Cluster {
connector.setSslContextFactory(clientSslCtxFactory);
HTTP2Client h2Client = new HTTP2Client(connector);
h2Client.setMaxConcurrentPushedStreams(b.maxStreamsPerConnection);
+ // Set the HTTP/2 flow control windows very large to cause TCP congestion instead of HTTP/2 flow control congestion.
+ int initialWindow = 128 * 1024 * 1024;
+ h2Client.setInitialSessionRecvWindow(initialWindow);
+ h2Client.setInitialStreamRecvWindow(initialWindow);
HttpClientTransportOverHTTP2 transport = new HttpClientTransportOverHTTP2(h2Client);
transport.setConnectionPoolFactory(dest -> {
MultiplexConnectionPool pool = new MultiplexConnectionPool(