Skip to content

Commit 9c9dc20

Browse files
committed
Update: Add support for removeResponseHeaders in BackendUtilization. Adjust logic, tests, and documentation to highlight default value and ORCA header removal.
Signed-off-by: anurag.ag <[email protected]>
1 parent c3e06cb commit 9c9dc20

19 files changed

+561
-2
lines changed

api/v1alpha1/loadbalancer_types.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,12 @@ type BackendUtilization struct {
207207
// For map fields in ORCA proto, use the form "<map_field>.<key>", e.g., "named_metrics.foo".
208208
// +optional
209209
MetricNamesForComputingUtilization []string `json:"metricNamesForComputingUtilization,omitempty"`
210+
211+
// RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
212+
// Defaults to true.
213+
// +optional
214+
// +kubebuilder:default=true
215+
RemoveResponseHeaders *bool `json:"removeResponseHeaders,omitempty"`
210216
}
211217

212218
// ConsistentHashType defines the type of input to hash on.

api/v1alpha1/zz_generated.deepcopy.go

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -741,6 +741,12 @@ spec:
741741
items:
742742
type: string
743743
type: array
744+
removeResponseHeaders:
745+
default: true
746+
description: |-
747+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
748+
Defaults to true.
749+
type: boolean
744750
weightExpirationPeriod:
745751
description: If a given endpoint has not reported load metrics
746752
in this long, stop using the reported weight. Defaults to

charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -771,6 +771,12 @@ spec:
771771
items:
772772
type: string
773773
type: array
774+
removeResponseHeaders:
775+
default: true
776+
description: |-
777+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
778+
Defaults to true.
779+
type: boolean
774780
weightExpirationPeriod:
775781
description: If a given endpoint has not reported
776782
load metrics in this long, stop using the reported

charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyproxies.yaml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11842,6 +11842,12 @@ spec:
1184211842
items:
1184311843
type: string
1184411844
type: array
11845+
removeResponseHeaders:
11846+
default: true
11847+
description: |-
11848+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
11849+
Defaults to true.
11850+
type: boolean
1184511851
weightExpirationPeriod:
1184611852
description: If a given endpoint
1184711853
has not reported load metrics
@@ -13153,6 +13159,12 @@ spec:
1315313159
items:
1315413160
type: string
1315513161
type: array
13162+
removeResponseHeaders:
13163+
default: true
13164+
description: |-
13165+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
13166+
Defaults to true.
13167+
type: boolean
1315613168
weightExpirationPeriod:
1315713169
description: If a given endpoint
1315813170
has not reported load metrics
@@ -14620,6 +14632,12 @@ spec:
1462014632
items:
1462114633
type: string
1462214634
type: array
14635+
removeResponseHeaders:
14636+
default: true
14637+
description: |-
14638+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
14639+
Defaults to true.
14640+
type: boolean
1462314641
weightExpirationPeriod:
1462414642
description: If a given endpoint has
1462514643
not reported load metrics in this
@@ -16003,6 +16021,12 @@ spec:
1600316021
items:
1600416022
type: string
1600516023
type: array
16024+
removeResponseHeaders:
16025+
default: true
16026+
description: |-
16027+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
16028+
Defaults to true.
16029+
type: boolean
1600616030
weightExpirationPeriod:
1600716031
description: If a given endpoint has not reported
1600816032
load metrics in this long, stop using the

charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_securitypolicies.yaml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1391,6 +1391,12 @@ spec:
13911391
items:
13921392
type: string
13931393
type: array
1394+
removeResponseHeaders:
1395+
default: true
1396+
description: |-
1397+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
1398+
Defaults to true.
1399+
type: boolean
13941400
weightExpirationPeriod:
13951401
description: If a given endpoint has not reported
13961402
load metrics in this long, stop using the reported
@@ -2585,6 +2591,12 @@ spec:
25852591
items:
25862592
type: string
25872593
type: array
2594+
removeResponseHeaders:
2595+
default: true
2596+
description: |-
2597+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
2598+
Defaults to true.
2599+
type: boolean
25882600
weightExpirationPeriod:
25892601
description: If a given endpoint has not reported
25902602
load metrics in this long, stop using the reported
@@ -3990,6 +4002,12 @@ spec:
39904002
items:
39914003
type: string
39924004
type: array
4005+
removeResponseHeaders:
4006+
default: true
4007+
description: |-
4008+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
4009+
Defaults to true.
4010+
type: boolean
39934011
weightExpirationPeriod:
39944012
description: If a given endpoint has not
39954013
reported load metrics in this long, stop
@@ -5455,6 +5473,12 @@ spec:
54555473
items:
54565474
type: string
54575475
type: array
5476+
removeResponseHeaders:
5477+
default: true
5478+
description: |-
5479+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
5480+
Defaults to true.
5481+
type: boolean
54585482
weightExpirationPeriod:
54595483
description: If a given endpoint has not reported
54605484
load metrics in this long, stop using the reported

charts/gateway-helm/crds/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -740,6 +740,12 @@ spec:
740740
items:
741741
type: string
742742
type: array
743+
removeResponseHeaders:
744+
default: true
745+
description: |-
746+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
747+
Defaults to true.
748+
type: boolean
743749
weightExpirationPeriod:
744750
description: If a given endpoint has not reported load metrics
745751
in this long, stop using the reported weight. Defaults to

charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -770,6 +770,12 @@ spec:
770770
items:
771771
type: string
772772
type: array
773+
removeResponseHeaders:
774+
default: true
775+
description: |-
776+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
777+
Defaults to true.
778+
type: boolean
773779
weightExpirationPeriod:
774780
description: If a given endpoint has not reported
775781
load metrics in this long, stop using the reported

charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyproxies.yaml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11841,6 +11841,12 @@ spec:
1184111841
items:
1184211842
type: string
1184311843
type: array
11844+
removeResponseHeaders:
11845+
default: true
11846+
description: |-
11847+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
11848+
Defaults to true.
11849+
type: boolean
1184411850
weightExpirationPeriod:
1184511851
description: If a given endpoint
1184611852
has not reported load metrics
@@ -13152,6 +13158,12 @@ spec:
1315213158
items:
1315313159
type: string
1315413160
type: array
13161+
removeResponseHeaders:
13162+
default: true
13163+
description: |-
13164+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
13165+
Defaults to true.
13166+
type: boolean
1315513167
weightExpirationPeriod:
1315613168
description: If a given endpoint
1315713169
has not reported load metrics
@@ -14619,6 +14631,12 @@ spec:
1461914631
items:
1462014632
type: string
1462114633
type: array
14634+
removeResponseHeaders:
14635+
default: true
14636+
description: |-
14637+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
14638+
Defaults to true.
14639+
type: boolean
1462214640
weightExpirationPeriod:
1462314641
description: If a given endpoint has
1462414642
not reported load metrics in this
@@ -16002,6 +16020,12 @@ spec:
1600216020
items:
1600316021
type: string
1600416022
type: array
16023+
removeResponseHeaders:
16024+
default: true
16025+
description: |-
16026+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
16027+
Defaults to true.
16028+
type: boolean
1600516029
weightExpirationPeriod:
1600616030
description: If a given endpoint has not reported
1600716031
load metrics in this long, stop using the

charts/gateway-helm/crds/generated/gateway.envoyproxy.io_securitypolicies.yaml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1390,6 +1390,12 @@ spec:
13901390
items:
13911391
type: string
13921392
type: array
1393+
removeResponseHeaders:
1394+
default: true
1395+
description: |-
1396+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
1397+
Defaults to true.
1398+
type: boolean
13931399
weightExpirationPeriod:
13941400
description: If a given endpoint has not reported
13951401
load metrics in this long, stop using the reported
@@ -2584,6 +2590,12 @@ spec:
25842590
items:
25852591
type: string
25862592
type: array
2593+
removeResponseHeaders:
2594+
default: true
2595+
description: |-
2596+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
2597+
Defaults to true.
2598+
type: boolean
25872599
weightExpirationPeriod:
25882600
description: If a given endpoint has not reported
25892601
load metrics in this long, stop using the reported
@@ -3989,6 +4001,12 @@ spec:
39894001
items:
39904002
type: string
39914003
type: array
4004+
removeResponseHeaders:
4005+
default: true
4006+
description: |-
4007+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
4008+
Defaults to true.
4009+
type: boolean
39924010
weightExpirationPeriod:
39934011
description: If a given endpoint has not
39944012
reported load metrics in this long, stop
@@ -5454,6 +5472,12 @@ spec:
54545472
items:
54555473
type: string
54565474
type: array
5475+
removeResponseHeaders:
5476+
default: true
5477+
description: |-
5478+
RemoveResponseHeaders removes the ORCA load report headers/trailers before sending the response to the client.
5479+
Defaults to true.
5480+
type: boolean
54575481
weightExpirationPeriod:
54585482
description: If a given endpoint has not reported
54595483
load metrics in this long, stop using the reported

0 commit comments

Comments
 (0)