From 5d99a81b63587f8cbf7d18ce17f6bbb093376c23 Mon Sep 17 00:00:00 2001 From: Patrick Steinhardt Date: Wed, 2 Sep 2020 08:08:24 +0200 Subject: praefect: Fix stale client connections due to keepalive policy While the Gitaly server sets up a keepalive enforcement policy, the Praefect server doesn't. As a result, the default policy is active which says that a keepalive ping is only allowed ever 5 minutes and only if there is an active stream. This may in fact explain some latency issues we've been seeing with the transaction service. Given the current infrequent accesses to it, there are extended periods of time where no calls are being made from Gitaly to Praefect. But while Gitaly clients have keepalive set up to ping Praefect every 20 seconds even if there are no streams, Praefect will just discard these pings. As a result we may see stale connections which will time out only to reconnect afterwards. Let's specify the same keepalive enforcement policy for Praefect as we do for Gitaly to fix this issue. --- changelogs/unreleased/pks-praefect-keepalive-policy.yml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 changelogs/unreleased/pks-praefect-keepalive-policy.yml (limited to 'changelogs') diff --git a/changelogs/unreleased/pks-praefect-keepalive-policy.yml b/changelogs/unreleased/pks-praefect-keepalive-policy.yml new file mode 100644 index 000000000..e3e5c9ebe --- /dev/null +++ b/changelogs/unreleased/pks-praefect-keepalive-policy.yml @@ -0,0 +1,5 @@ +--- +title: Fix stale connections to Praefect due to keepalive policy +merge_request: 2511 +author: +type: fixed -- cgit v1.2.3