Skip to content

Conversation

@SalahDevp
Copy link
Contributor

@SalahDevp SalahDevp commented Jul 7, 2025

This PR fixes issue (#205) by replacing the old KeepAlive config with the new KeepAliveConfig (introduced in Go 1.23), allowing more control over TCP keepalive behavior.

  • Sets a shorter keepalive: Idle=30s, Interval=5s, Count=3 → total timeout 40s instead of the old 4m 30s

This change is to reduce the hang caused by the default TCP keepalive behavior when the client’s IP changes or connection gets interrupted.

Fixes: #205

@SuperQ
Copy link
Contributor

SuperQ commented Nov 27, 2025

This needs a rebase and DCO.

This needs a DCO sign-off. You can use git commit -s --amend to add it.

Signed-off-by: salahdevp <slhokli2002@gmail.com>
@SalahDevp
Copy link
Contributor Author

Done, rebased and added DCO

Copy link
Contributor

@SuperQ SuperQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@SuperQ SuperQ merged commit 01ec1f6 into prometheus-community:master Nov 27, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Long-polling /poll hangs ~5 min on IP change, causes metrics gap

2 participants