userver icon indicating copy to clipboard operation
userver copied to clipboard

[postgres] make connlimit-mode auto ttl dynamic

Open segoon opened this issue 2 years ago • 0 comments

If a service is restarted slower than in 15 seconds, other instances cut out all the connections. This may lead to unneeded connection rebalancing and even some runtime errors. We should look at boot time metric and dynamically calculate TTL of a ticket:

TTL = max(3*boot_time, 15 seconds);

Internal ticket: 7922

segoon avatar Dec 04 '23 09:12 segoon