helidon-io / helidon

Java libraries for writing microservices
https://helidon.io
Apache License 2.0
3.52k stars 566 forks source link

2.x/3.x: Support ability to timeout idle connections #9163

Closed barchetta closed 2 months ago

barchetta commented 2 months ago

Environment Details


Problem Description

In Helidon 4 the WebServer supports idle-connection-timeout that controls how long it should wait before closing a connection that has no traffic on it.

Helidon 2 and 3 (which are Netty based) do not appear to have such capability. To implement this might require using Netty's IdleStateHandler

ggsrivas commented 2 months ago

HI Team, We are facing this issue on our service. The open socket count keeps going up and stops accepting new connection in 7-8 days. We are forced to restart the service to clean those open connections. This is affecting our customer as the API as inaccessible when this happens. Any ETA for this fix?

spericas commented 2 months ago

Fixed in 2.x and 3.x

ggsrivas commented 2 months ago

@spericas should we expect a 2.6.9 release soon with this fix? I don't see that tag on Github.

spericas commented 2 months ago

@spericas should we expect a 2.6.9 release soon with this fix? I don't see that tag on Github.

@barchetta ?

barchetta commented 2 months ago

@ggsrivas It will be soon, but I do not have an ETA at the moment. I am making a build change so that we can produce a 2.6.9-SNAPSHOT build that you can test with. I will notify you once that is ready.

spericas commented 2 months ago

@ggsrivas It will be soon, but I do not have an ETA at the moment. I am making a build change so that we can produce a 2.6.9-SNAPSHOT build that you can test with. I will notify you once that is ready.

That's actually a great idea, trying out a SNAPSHOT version to verify this works in your environment.

barchetta commented 2 months ago

@ggsrivas 2.6.9-SNAPSHOT with the fix is available at: https://oss.sonatype.org/content/repositories/snapshots/io/helidon/