Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add max connection age typhon server option #166

Merged
merged 1 commit into from
May 5, 2023

Conversation

danielchatfield
Copy link
Member

This pull request adds a new typhon.ServerOption that will enforce a server-side maximum connection age. This is useful in environments where long-lived connections can result in unbalanced load.

It's a little frustrating that I haven't been able to write a really robust test for this, I've had to settle for validating that the code is executed and the connection start time is being propagated. In practice this is a pretty decent test since the only thing it isn't covering is our ability to correctly determine if that connection start is > maxAge and to set a header which are both simple.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
"http2.0-h2",

// The Go h2c implementation doesn't currently support max
// connection age.
Copy link
Member Author

Choose a reason for hiding this comment

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

Same as the other server options – not supported by h2c (which we don't use anywhere).

@danielchatfield danielchatfield changed the title Add max connection age server option Add max connection age typhon server option May 5, 2023
@danielchatfield danielchatfield merged commit ea17ae8 into master May 5, 2023
@danielchatfield danielchatfield deleted the add-max-connection-age-server-option branch May 5, 2023 14:29
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.

None yet

2 participants