Skip to content

Commit

Permalink
Expose ratelimit grpc authority field [1.14] (#9155)
Browse files Browse the repository at this point in the history
* expose ratelimit grpc authority field

* Update changelog/v1.17.0-beta8/ratelimit-grpc-authority.yaml



* move into oneof

---------

Co-authored-by: Nathan Fudenberg <[email protected]>
Co-authored-by: soloio-bulldozer[bot] <48420018+soloio-bulldozer[bot]@users.noreply.github.com>
  • Loading branch information
3 people authored Feb 11, 2024
1 parent a38c127 commit 1b5ef13
Show file tree
Hide file tree
Showing 14 changed files with 421 additions and 97 deletions.
5 changes: 5 additions & 0 deletions changelog/v1.14.29/ratelimit-grpc-authority.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
changelog:
- type: FIX
issueLink: https://github.com/solo-io/gloo/issues/8995
resolvesIssue: false
description: Expose a new ratelimit option `grpcService.authority` to configure the authority header for the ratelimit gRPC call.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions docs/data/ProtoMap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1331,6 +1331,9 @@ apis:
ratelimit.api.solo.io.SimpleDescriptor:
relativepath: reference/api/github.com/solo-io/solo-apis/api/rate-limiter/v1alpha1/ratelimit.proto.sk/#SimpleDescriptor
package: ratelimit.api.solo.io
ratelimit.options.gloo.solo.io.GrpcService:
relativepath: reference/api/github.com/solo-io/gloo/projects/gloo/api/v1/enterprise/options/ratelimit/ratelimit.proto.sk/#GrpcService
package: ratelimit.options.gloo.solo.io
ratelimit.options.gloo.solo.io.IngressRateLimit:
relativepath: reference/api/github.com/solo-io/gloo/projects/gloo/api/v1/enterprise/options/ratelimit/ratelimit.proto.sk/#IngressRateLimit
package: ratelimit.options.gloo.solo.io
Expand Down
10 changes: 10 additions & 0 deletions install/helm/gloo/crds/gateway.solo.io_v1_Gateway.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -962,6 +962,11 @@ spec:
type: boolean
enableXRatelimitHeaders:
type: boolean
grpcService:
properties:
authority:
type: string
type: object
rateLimitBeforeAuth:
type: boolean
ratelimitServerRef:
Expand Down Expand Up @@ -2548,6 +2553,11 @@ spec:
type: boolean
enableXRatelimitHeaders:
type: boolean
grpcService:
properties:
authority:
type: string
type: object
rateLimitBeforeAuth:
type: boolean
ratelimitServerRef:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -957,6 +957,11 @@ spec:
type: boolean
enableXRatelimitHeaders:
type: boolean
grpcService:
properties:
authority:
type: string
type: object
rateLimitBeforeAuth:
type: boolean
ratelimitServerRef:
Expand Down
5 changes: 5 additions & 0 deletions install/helm/gloo/crds/gloo.solo.io_v1_Settings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -623,6 +623,11 @@ spec:
type: boolean
enableXRatelimitHeaders:
type: boolean
grpcService:
properties:
authority:
type: string
type: object
rateLimitBeforeAuth:
type: boolean
ratelimitServerRef:
Expand Down
10 changes: 10 additions & 0 deletions projects/gloo/api/v1/enterprise/options/ratelimit/ratelimit.proto
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,16 @@ message Settings {
// Set this is set to true if you would like to rate limit traffic before applying external auth to it.
// *Note*: When this is true, you will lose some features like being able to rate limit a request based on its auth state
bool rate_limit_before_auth = 9;

oneof service_type {
// Optional gRPC settings used when calling the ratelimit server.
GrpcService grpc_service = 10;
}
}

message GrpcService {
// Set the authority header when calling the gRPC service.
string authority = 1;
}

// API based on Envoy's rate-limit service API. (reference here: https://github.com/lyft/ratelimit#configuration)
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 1b5ef13

Please sign in to comment.