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

Limit GRPC Active streams #33936

Merged
merged 1 commit into from
Oct 27, 2023
Merged

Limit GRPC Active streams #33936

merged 1 commit into from
Oct 27, 2023

Conversation

jentfoo
Copy link
Contributor

@jentfoo jentfoo commented Oct 26, 2023

Originally there was a default limit of 100 max concurrent streams, however in 2017 the GRPC team removed this default: grpc/grpc-go#1624

With the recent HTTP/2 Rapid Reset DoS, it is now being encouraged to re-introduce a limit. The fix actually requires this value to be configured: grpc/grpc-go#6703

I choose a value of 1000, which should be excessively large (10x the old default of 100).

For that reason this fix will be backported. When we backport to v14 and older we will also update grpc-go to the recent 1.58.3 which includes an additional fix (not needed in master due to already being on 1.59.0)

Originally there was a default limit of 100 max concurrent streams, however in 2017 the GRPC team removed this default: grpc/grpc-go#1624

With the recent HTTP/2 Rapid Reset DoS, it is now being encouraged to re-introduce a limit.  The fix requires this value to be configured in fact: grpc/grpc-go#6703
@github-actions
Copy link

The PR changelog entry failed validation: Changelog entry not found in the PR body. Please add a "no-changelog" label to the PR, or changelog lines starting with changelog: followed by the changelog entries for the PR.

@zmb3
Copy link
Collaborator

zmb3 commented Oct 26, 2023

I would run a scale test or wait for a full test plan before merging this one.

Copy link
Contributor

@rosstimothy rosstimothy left a comment

Choose a reason for hiding this comment

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

I share the same concerns as @zmb3 about putting this change into a release without any stress testing.

@@ -100,6 +100,10 @@ const (
// By default all users use /bin/bash
DefaultShell = "/bin/bash"

// GRPCMaxConcurrentStreams is the max GRPC streams that can be active at a time. Once the limit is reached new
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: slightly pedantic but it is gRPC not GRPC

@fspmarshall
Copy link
Contributor

I have some unrelated scale testing to do today. Will pull in this PR as well.

@fspmarshall
Copy link
Contributor

Update: did a 30k agent scaling test with these changes included (2 auth/2 proxy/etcd backend). Didn't observe any ill effects in metrics/logs, and manually verified basic cluster functionality (login/UI navigation/ssh access). Seems peachy.

@jentfoo jentfoo added this pull request to the merge queue Oct 27, 2023
Merged via the queue into master with commit 05adc2d Oct 27, 2023
36 of 37 checks passed
@jentfoo jentfoo deleted the jent/limit_grpc_streams branch October 27, 2023 15:44
@public-teleport-github-review-bot

@jentfoo See the table below for backport results.

Branch Result
branch/v12 Failed
branch/v13 Create PR
branch/v14 Create PR

jentfoo added a commit that referenced this pull request Oct 27, 2023
Originally there was a default limit of 100 max concurrent streams, however in 2017 the GRPC team removed this default: grpc/grpc-go#1624

With the recent HTTP/2 Rapid Reset DoS, it is now being encouraged to re-introduce a limit.  The fix requires this value to be configured in fact: grpc/grpc-go#6703
jentfoo added a commit that referenced this pull request Oct 27, 2023
Originally there was a default limit of 100 max concurrent streams, however in 2017 the GRPC team removed this default: grpc/grpc-go#1624

With the recent HTTP/2 Rapid Reset DoS, it is now being encouraged to re-introduce a limit.  The fix requires this value to be configured in fact: grpc/grpc-go#6703
jentfoo added a commit that referenced this pull request Oct 27, 2023
Originally there was a default limit of 100 max concurrent streams, however in 2017 the GRPC team removed this default: grpc/grpc-go#1624

With the recent HTTP/2 Rapid Reset DoS, it is now being encouraged to re-introduce a limit.  The fix requires this value to be configured in fact: grpc/grpc-go#6703
github-merge-queue bot pushed a commit that referenced this pull request Oct 27, 2023
* Limit GRPC Active streams (#33936)

Originally there was a default limit of 100 max concurrent streams, however in 2017 the GRPC team removed this default: grpc/grpc-go#1624

With the recent HTTP/2 Rapid Reset DoS, it is now being encouraged to re-introduce a limit.  The fix requires this value to be configured in fact: grpc/grpc-go#6703

* Update gRPC to 1.58.3 to address GHSA-m425-mq94-257g
github-merge-queue bot pushed a commit that referenced this pull request Oct 27, 2023
* Limit GRPC Active streams (#33936)

Originally there was a default limit of 100 max concurrent streams, however in 2017 the GRPC team removed this default: grpc/grpc-go#1624

With the recent HTTP/2 Rapid Reset DoS, it is now being encouraged to re-introduce a limit.  The fix requires this value to be configured in fact: grpc/grpc-go#6703

* Update gRPC to 1.58.3 to address GHSA-m425-mq94-257g
github-merge-queue bot pushed a commit that referenced this pull request Oct 27, 2023
* Limit GRPC Active streams (#33936)

Originally there was a default limit of 100 max concurrent streams, however in 2017 the GRPC team removed this default: grpc/grpc-go#1624

With the recent HTTP/2 Rapid Reset DoS, it is now being encouraged to re-introduce a limit.  The fix requires this value to be configured in fact: grpc/grpc-go#6703

* Update gRPC to 1.58.3 to address GHSA-m425-mq94-257g
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport/branch/v13 backport/branch/v14 no-changelog Indicates that a PR does not require a changelog entry size/sm
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants