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

fix: keepalive interval calculation #9

Merged
merged 1 commit into from
Mar 12, 2024

Conversation

smira
Copy link
Member

@smira smira commented Mar 12, 2024

It should have been max, not min, enforcing minimum keepalive interval, not the other way around.

Also update dependencies and rekres.

It should have been `max`, not `min`, enforcing minimum keepalive
interval, not the other way around.

Also update dependencies and rekres.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
@@ -276,7 +276,7 @@ func (client *Client) Run(ctx context.Context, logger *zap.Logger, notifyCh chan

opts := []grpc.DialOption{
grpc.WithKeepaliveParams(keepalive.ClientParameters{
Time: min(10*time.Second, client.options.TTL/10),
Time: max(10*time.Second, client.options.TTL/10),
Copy link
Member Author

Choose a reason for hiding this comment

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

this is the fix

@smira
Copy link
Member Author

smira commented Mar 12, 2024

/m

@talos-bot talos-bot merged commit fbb1cea into siderolabs:main Mar 12, 2024
13 checks passed
smira added a commit to smira/talos that referenced this pull request Mar 13, 2024
See siderolabs/discovery-client#9

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
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.

3 participants