diff --git a/api/v1alpha1/shared_types.go b/api/v1alpha1/shared_types.go index 343f1210c8..ff8428f11b 100644 --- a/api/v1alpha1/shared_types.go +++ b/api/v1alpha1/shared_types.go @@ -718,6 +718,33 @@ type HTTP2Settings struct { // Default: TerminateConnection // +optional OnInvalidMessage *InvalidMessageAction `json:"onInvalidMessage,omitempty"` + + // ConnectionKeepalive configures HTTP/2 connection keepalive using PING frames. + // +optional + ConnectionKeepalive *HTTP2ConnectionKeepalive `json:"connectionKeepalive,omitempty"` +} + +// HTTP2ConnectionKeepalive configures HTTP/2 PING-based keepalive settings. +// +kubebuilder:validation:XValidation:rule="!has(self.timeout) || !has(self.interval) || duration(self.timeout) < duration(self.interval)",message="timeout must be less than interval" +type HTTP2ConnectionKeepalive struct { + // Interval specifies how often to send HTTP/2 PING frames to keep the connection alive. + // +optional + Interval *gwapiv1.Duration `json:"interval,omitempty"` + + // Timeout specifies how long to wait for a PING response before considering the connection dead. + // +optional + Timeout *gwapiv1.Duration `json:"timeout,omitempty"` + + // IntervalJitter specifies a random jitter percentage added to each interval. + // Defaults to 15% if not specified. + // +kubebuilder:validation:Minimum=0 + // +kubebuilder:validation:Maximum=100 + // +optional + IntervalJitter *uint32 `json:"intervalJitter,omitempty"` + + // ConnectionIdleInterval specifies how long a connection must be idle before a PING is sent. + // +optional + ConnectionIdleInterval *gwapiv1.Duration `json:"connectionIdleInterval,omitempty"` } // ResponseOverride defines the configuration to override specific responses with a custom one. diff --git a/api/v1alpha1/zz_generated.deepcopy.go b/api/v1alpha1/zz_generated.deepcopy.go index 3a5ce771a3..1a461075a3 100644 --- a/api/v1alpha1/zz_generated.deepcopy.go +++ b/api/v1alpha1/zz_generated.deepcopy.go @@ -3491,6 +3491,41 @@ func (in *HTTP1Settings) DeepCopy() *HTTP1Settings { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *HTTP2ConnectionKeepalive) DeepCopyInto(out *HTTP2ConnectionKeepalive) { + *out = *in + if in.Interval != nil { + in, out := &in.Interval, &out.Interval + *out = new(v1.Duration) + **out = **in + } + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(v1.Duration) + **out = **in + } + if in.IntervalJitter != nil { + in, out := &in.IntervalJitter, &out.IntervalJitter + *out = new(uint32) + **out = **in + } + if in.ConnectionIdleInterval != nil { + in, out := &in.ConnectionIdleInterval, &out.ConnectionIdleInterval + *out = new(v1.Duration) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTP2ConnectionKeepalive. +func (in *HTTP2ConnectionKeepalive) DeepCopy() *HTTP2ConnectionKeepalive { + if in == nil { + return nil + } + out := new(HTTP2ConnectionKeepalive) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *HTTP2Settings) DeepCopyInto(out *HTTP2Settings) { *out = *in @@ -3514,6 +3549,11 @@ func (in *HTTP2Settings) DeepCopyInto(out *HTTP2Settings) { *out = new(InvalidMessageAction) **out = **in } + if in.ConnectionKeepalive != nil { + in, out := &in.ConnectionKeepalive, &out.ConnectionKeepalive + *out = new(HTTP2ConnectionKeepalive) + (*in).DeepCopyInto(*out) + } } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTP2Settings. diff --git a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml index 56c666f9e8..f5fc0d75ce 100644 --- a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml +++ b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml @@ -649,6 +649,38 @@ spec: http2: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how long a connection + must be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send HTTP/2 PING + frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait for a PING + response before considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) || duration(self.timeout) + < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml index d199db4116..c52cf36eae 100644 --- a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml +++ b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml @@ -799,6 +799,38 @@ spec: http2: description: HTTP2 provides HTTP/2 configuration on the listener. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how long a connection + must be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send HTTP/2 PING + frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait for a PING + response before considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) || duration(self.timeout) + < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml index da2d4e856a..406dce7a73 100644 --- a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml +++ b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml @@ -710,6 +710,40 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how + long a connection must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) || + duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyproxies.yaml b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyproxies.yaml index 45aef65fee..31c41b8b6c 100644 --- a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyproxies.yaml +++ b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_envoyproxies.yaml @@ -11803,6 +11803,46 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using + PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection + must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies + how often to send HTTP/2 PING + frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies + how long to wait for a PING + response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than + interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -13110,6 +13150,46 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using + PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection + must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies + how often to send HTTP/2 PING + frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies + how long to wait for a PING + response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than + interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -14573,6 +14653,42 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using PING + frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection must + be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how + often to send HTTP/2 PING frames to + keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long + to wait for a PING response before + considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -15953,6 +16069,41 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before + a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often + to send HTTP/2 PING frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to + wait for a PING response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_securitypolicies.yaml b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_securitypolicies.yaml index fc4088dc2d..a01c36e4b3 100644 --- a/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_securitypolicies.yaml +++ b/charts/gateway-crds-helm/templates/generated/gateway.envoyproxy.io_securitypolicies.yaml @@ -1330,6 +1330,40 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -2522,6 +2556,40 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -3925,6 +3993,41 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before + a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often + to send HTTP/2 PING frames to keep the + connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long + to wait for a PING response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -5385,6 +5488,40 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml index 006f1c5a8b..955d3a72e3 100644 --- a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml +++ b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_backendtrafficpolicies.yaml @@ -648,6 +648,38 @@ spec: http2: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how long a connection + must be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send HTTP/2 PING + frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait for a PING + response before considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) || duration(self.timeout) + < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml index 8b60000ca2..f92a95cc66 100644 --- a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml +++ b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml @@ -798,6 +798,38 @@ spec: http2: description: HTTP2 provides HTTP/2 configuration on the listener. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how long a connection + must be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send HTTP/2 PING + frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait for a PING + response before considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) || duration(self.timeout) + < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml index b255bd38d9..806f8c396b 100644 --- a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml +++ b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyextensionpolicies.yaml @@ -709,6 +709,40 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how + long a connection must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) || + duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyproxies.yaml b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyproxies.yaml index 73f0f74432..920f645407 100644 --- a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyproxies.yaml +++ b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_envoyproxies.yaml @@ -11802,6 +11802,46 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using + PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection + must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies + how often to send HTTP/2 PING + frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies + how long to wait for a PING + response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than + interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -13109,6 +13149,46 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using + PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection + must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies + how often to send HTTP/2 PING + frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies + how long to wait for a PING + response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than + interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -14572,6 +14652,42 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using PING + frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection must + be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how + often to send HTTP/2 PING frames to + keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long + to wait for a PING response before + considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -15952,6 +16068,41 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before + a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often + to send HTTP/2 PING frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to + wait for a PING response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_securitypolicies.yaml b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_securitypolicies.yaml index 6e82fdf6d6..1c782dfedc 100644 --- a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_securitypolicies.yaml +++ b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_securitypolicies.yaml @@ -1329,6 +1329,40 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -2521,6 +2555,40 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -3924,6 +3992,41 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before + a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often + to send HTTP/2 PING frames to keep the + connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long + to wait for a PING response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -5384,6 +5487,40 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object + x-kubernetes-validations: + - message: timeout must be less than interval + rule: '!has(self.timeout) || !has(self.interval) + || duration(self.timeout) < duration(self.interval)' initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/internal/gatewayapi/http.go b/internal/gatewayapi/http.go index e54b3f761d..a604b69c1c 100644 --- a/internal/gatewayapi/http.go +++ b/internal/gatewayapi/http.go @@ -8,6 +8,7 @@ package gatewayapi import ( "errors" "fmt" + "time" "k8s.io/utils/ptr" @@ -72,5 +73,37 @@ func buildIRHTTP2Settings(http2Settings *egv1a1.HTTP2Settings) (*ir.HTTP2Setting } } + if http2Settings.ConnectionKeepalive != nil { + keepalive := &ir.HTTP2ConnectionKeepalive{} + if http2Settings.ConnectionKeepalive.Interval != nil { + d, err := time.ParseDuration(string(*http2Settings.ConnectionKeepalive.Interval)) + if err != nil { + errs = errors.Join(errs, fmt.Errorf("invalid ConnectionKeepalive.Interval: %w", err)) + } else { + keepalive.Interval = ir.MetaV1DurationPtr(d) + } + } + if http2Settings.ConnectionKeepalive.Timeout != nil { + d, err := time.ParseDuration(string(*http2Settings.ConnectionKeepalive.Timeout)) + if err != nil { + errs = errors.Join(errs, fmt.Errorf("invalid ConnectionKeepalive.Timeout: %w", err)) + } else { + keepalive.Timeout = ir.MetaV1DurationPtr(d) + } + } + if http2Settings.ConnectionKeepalive.IntervalJitter != nil { + keepalive.IntervalJitter = http2Settings.ConnectionKeepalive.IntervalJitter + } + if http2Settings.ConnectionKeepalive.ConnectionIdleInterval != nil { + d, err := time.ParseDuration(string(*http2Settings.ConnectionKeepalive.ConnectionIdleInterval)) + if err != nil { + errs = errors.Join(errs, fmt.Errorf("invalid ConnectionKeepalive.ConnectionIdleInterval: %w", err)) + } else { + keepalive.ConnectionIdleInterval = ir.MetaV1DurationPtr(d) + } + } + http2.ConnectionKeepalive = keepalive + } + return http2, errs } diff --git a/internal/gatewayapi/testdata/backendtrafficpolicy-http2-keepalive.in.yaml b/internal/gatewayapi/testdata/backendtrafficpolicy-http2-keepalive.in.yaml new file mode 100644 index 0000000000..bf6c0f8193 --- /dev/null +++ b/internal/gatewayapi/testdata/backendtrafficpolicy-http2-keepalive.in.yaml @@ -0,0 +1,52 @@ +gateways: + - apiVersion: gateway.networking.k8s.io/v1 + kind: Gateway + metadata: + namespace: envoy-gateway + name: gateway-1 + spec: + gatewayClassName: envoy-gateway-class + listeners: + - name: http + protocol: HTTP + port: 80 + allowedRoutes: + namespaces: + from: All +httpRoutes: + - apiVersion: gateway.networking.k8s.io/v1 + kind: HTTPRoute + metadata: + namespace: default + name: httproute-1 + spec: + hostnames: + - gateway.envoyproxy.io + parentRefs: + - namespace: envoy-gateway + name: gateway-1 + sectionName: http + rules: + - matches: + - path: + value: "/" + backendRefs: + - name: service-1 + port: 8080 +backendTrafficPolicies: + - apiVersion: gateway.envoyproxy.io/v1alpha1 + kind: BackendTrafficPolicy + metadata: + namespace: default + name: policy-for-route + spec: + targetRef: + group: gateway.networking.k8s.io + kind: HTTPRoute + name: httproute-1 + http2: + connectionKeepalive: + interval: 60s + timeout: 10s + intervalJitter: 20 + connectionIdleInterval: 30s diff --git a/internal/gatewayapi/testdata/backendtrafficpolicy-http2-keepalive.out.yaml b/internal/gatewayapi/testdata/backendtrafficpolicy-http2-keepalive.out.yaml new file mode 100644 index 0000000000..3b2c568f3f --- /dev/null +++ b/internal/gatewayapi/testdata/backendtrafficpolicy-http2-keepalive.out.yaml @@ -0,0 +1,223 @@ +backendTrafficPolicies: +- apiVersion: gateway.envoyproxy.io/v1alpha1 + kind: BackendTrafficPolicy + metadata: + name: policy-for-route + namespace: default + spec: + http2: + connectionKeepalive: + connectionIdleInterval: 30s + interval: 60s + intervalJitter: 20 + timeout: 10s + targetRef: + group: gateway.networking.k8s.io + kind: HTTPRoute + name: httproute-1 + status: + ancestors: + - ancestorRef: + group: gateway.networking.k8s.io + kind: Gateway + name: gateway-1 + namespace: envoy-gateway + sectionName: http + conditions: + - lastTransitionTime: null + message: Policy has been accepted. + reason: Accepted + status: "True" + type: Accepted + - lastTransitionTime: null + message: spec.targetRef is deprecated, use spec.targetRefs instead + reason: DeprecatedField + status: "True" + type: Warning + controllerName: gateway.envoyproxy.io/gatewayclass-controller +gateways: +- apiVersion: gateway.networking.k8s.io/v1 + kind: Gateway + metadata: + name: gateway-1 + namespace: envoy-gateway + spec: + gatewayClassName: envoy-gateway-class + listeners: + - allowedRoutes: + namespaces: + from: All + name: http + port: 80 + protocol: HTTP + status: + listeners: + - attachedRoutes: 1 + conditions: + - lastTransitionTime: null + message: Sending translated listener configuration to the data plane + reason: Programmed + status: "True" + type: Programmed + - lastTransitionTime: null + message: Listener has been successfully translated + reason: Accepted + status: "True" + type: Accepted + - lastTransitionTime: null + message: Listener references have been resolved + reason: ResolvedRefs + status: "True" + type: ResolvedRefs + name: http + supportedKinds: + - group: gateway.networking.k8s.io + kind: HTTPRoute + - group: gateway.networking.k8s.io + kind: GRPCRoute +httpRoutes: +- apiVersion: gateway.networking.k8s.io/v1 + kind: HTTPRoute + metadata: + name: httproute-1 + namespace: default + spec: + hostnames: + - gateway.envoyproxy.io + parentRefs: + - name: gateway-1 + namespace: envoy-gateway + sectionName: http + rules: + - backendRefs: + - name: service-1 + port: 8080 + matches: + - path: + value: / + status: + parents: + - conditions: + - lastTransitionTime: null + message: Route is accepted + reason: Accepted + status: "True" + type: Accepted + - lastTransitionTime: null + message: Resolved all the Object references for the Route + reason: ResolvedRefs + status: "True" + type: ResolvedRefs + controllerName: gateway.envoyproxy.io/gatewayclass-controller + parentRef: + name: gateway-1 + namespace: envoy-gateway + sectionName: http +infraIR: + envoy-gateway/gateway-1: + proxy: + listeners: + - name: envoy-gateway/gateway-1/http + ports: + - containerPort: 10080 + name: http-80 + protocol: HTTP + servicePort: 80 + metadata: + labels: + gateway.envoyproxy.io/owning-gateway-name: gateway-1 + gateway.envoyproxy.io/owning-gateway-namespace: envoy-gateway + ownerReference: + kind: GatewayClass + name: envoy-gateway-class + name: envoy-gateway/gateway-1 + namespace: envoy-gateway-system +xdsIR: + envoy-gateway/gateway-1: + accessLog: + json: + - path: /dev/stdout + globalResources: + proxyServiceCluster: + metadata: + kind: Service + name: envoy-envoy-gateway-gateway-1-196ae069 + namespace: envoy-gateway-system + sectionName: "8080" + name: envoy-gateway/gateway-1 + settings: + - addressType: IP + endpoints: + - host: 7.6.5.4 + port: 8080 + zone: zone1 + metadata: + kind: Service + name: envoy-envoy-gateway-gateway-1-196ae069 + namespace: envoy-gateway-system + sectionName: "8080" + name: envoy-gateway/gateway-1 + protocol: TCP + http: + - address: 0.0.0.0 + externalPort: 80 + hostnames: + - '*' + isHTTP2: false + metadata: + kind: Gateway + name: gateway-1 + namespace: envoy-gateway + sectionName: http + name: envoy-gateway/gateway-1/http + path: + escapedSlashesAction: UnescapeAndRedirect + mergeSlashes: true + port: 10080 + routes: + - destination: + metadata: + kind: HTTPRoute + name: httproute-1 + namespace: default + name: httproute/default/httproute-1/rule/0 + settings: + - addressType: IP + endpoints: + - host: 7.7.7.7 + port: 8080 + metadata: + kind: Service + name: service-1 + namespace: default + sectionName: "8080" + name: httproute/default/httproute-1/rule/0/backend/0 + protocol: HTTP + weight: 1 + hostname: gateway.envoyproxy.io + isHTTP2: false + metadata: + kind: HTTPRoute + name: httproute-1 + namespace: default + policies: + - kind: BackendTrafficPolicy + name: policy-for-route + namespace: default + name: httproute/default/httproute-1/rule/0/match/0/gateway_envoyproxy_io + pathMatch: + distinct: false + name: "" + prefix: / + traffic: + http2: + connectionKeepalive: + connectionIdleInterval: 30s + interval: 1m0s + intervalJitter: 20 + timeout: 10s + readyListener: + address: 0.0.0.0 + ipFamily: IPv4 + path: /ready + port: 19003 diff --git a/internal/gatewayapi/testdata/clienttrafficpolicy-http2-keepalive.in.yaml b/internal/gatewayapi/testdata/clienttrafficpolicy-http2-keepalive.in.yaml new file mode 100644 index 0000000000..1fe936bce7 --- /dev/null +++ b/internal/gatewayapi/testdata/clienttrafficpolicy-http2-keepalive.in.yaml @@ -0,0 +1,33 @@ +clientTrafficPolicies: +- apiVersion: gateway.envoyproxy.io/v1alpha1 + kind: ClientTrafficPolicy + metadata: + namespace: envoy-gateway + name: target-gateway-1-section-http-1 + spec: + http2: + connectionKeepalive: + interval: 60s + timeout: 10s + intervalJitter: 20 + connectionIdleInterval: 30s + targetRef: + group: gateway.networking.k8s.io + kind: Gateway + name: gateway-1 + sectionName: http-1 +gateways: +- apiVersion: gateway.networking.k8s.io/v1 + kind: Gateway + metadata: + namespace: envoy-gateway + name: gateway-1 + spec: + gatewayClassName: envoy-gateway-class + listeners: + - name: http-1 + protocol: HTTP + port: 80 + allowedRoutes: + namespaces: + from: Same diff --git a/internal/gatewayapi/testdata/clienttrafficpolicy-http2-keepalive.out.yaml b/internal/gatewayapi/testdata/clienttrafficpolicy-http2-keepalive.out.yaml new file mode 100644 index 0000000000..281ca73022 --- /dev/null +++ b/internal/gatewayapi/testdata/clienttrafficpolicy-http2-keepalive.out.yaml @@ -0,0 +1,145 @@ +clientTrafficPolicies: +- apiVersion: gateway.envoyproxy.io/v1alpha1 + kind: ClientTrafficPolicy + metadata: + name: target-gateway-1-section-http-1 + namespace: envoy-gateway + spec: + http2: + connectionKeepalive: + connectionIdleInterval: 30s + interval: 60s + intervalJitter: 20 + timeout: 10s + targetRef: + group: gateway.networking.k8s.io + kind: Gateway + name: gateway-1 + sectionName: http-1 + status: + ancestors: + - ancestorRef: + group: gateway.networking.k8s.io + kind: Gateway + name: gateway-1 + namespace: envoy-gateway + sectionName: http-1 + conditions: + - lastTransitionTime: null + message: Policy has been accepted. + reason: Accepted + status: "True" + type: Accepted + controllerName: gateway.envoyproxy.io/gatewayclass-controller +gateways: +- apiVersion: gateway.networking.k8s.io/v1 + kind: Gateway + metadata: + name: gateway-1 + namespace: envoy-gateway + spec: + gatewayClassName: envoy-gateway-class + listeners: + - allowedRoutes: + namespaces: + from: Same + name: http-1 + port: 80 + protocol: HTTP + status: + listeners: + - attachedRoutes: 0 + conditions: + - lastTransitionTime: null + message: Sending translated listener configuration to the data plane + reason: Programmed + status: "True" + type: Programmed + - lastTransitionTime: null + message: Listener has been successfully translated + reason: Accepted + status: "True" + type: Accepted + - lastTransitionTime: null + message: Listener references have been resolved + reason: ResolvedRefs + status: "True" + type: ResolvedRefs + name: http-1 + supportedKinds: + - group: gateway.networking.k8s.io + kind: HTTPRoute + - group: gateway.networking.k8s.io + kind: GRPCRoute +infraIR: + envoy-gateway/gateway-1: + proxy: + listeners: + - name: envoy-gateway/gateway-1/http-1 + ports: + - containerPort: 10080 + name: http-80 + protocol: HTTP + servicePort: 80 + metadata: + labels: + gateway.envoyproxy.io/owning-gateway-name: gateway-1 + gateway.envoyproxy.io/owning-gateway-namespace: envoy-gateway + ownerReference: + kind: GatewayClass + name: envoy-gateway-class + name: envoy-gateway/gateway-1 + namespace: envoy-gateway-system +xdsIR: + envoy-gateway/gateway-1: + accessLog: + json: + - path: /dev/stdout + globalResources: + proxyServiceCluster: + metadata: + kind: Service + name: envoy-envoy-gateway-gateway-1-196ae069 + namespace: envoy-gateway-system + sectionName: "8080" + name: envoy-gateway/gateway-1 + settings: + - addressType: IP + endpoints: + - host: 7.6.5.4 + port: 8080 + zone: zone1 + metadata: + kind: Service + name: envoy-envoy-gateway-gateway-1-196ae069 + namespace: envoy-gateway-system + sectionName: "8080" + name: envoy-gateway/gateway-1 + protocol: TCP + http: + - address: 0.0.0.0 + externalPort: 80 + hostnames: + - '*' + http2: + connectionKeepalive: + connectionIdleInterval: 30s + interval: 1m0s + intervalJitter: 20 + timeout: 10s + isHTTP2: false + metadata: + kind: Gateway + name: gateway-1 + namespace: envoy-gateway + sectionName: http-1 + name: envoy-gateway/gateway-1/http-1 + path: + escapedSlashesAction: UnescapeAndRedirect + mergeSlashes: true + port: 10080 + readyListener: + address: 0.0.0.0 + ipFamily: IPv4 + path: /ready + port: 19003 diff --git a/internal/ir/xds.go b/internal/ir/xds.go index 1380222b31..45ebf143b9 100644 --- a/internal/ir/xds.go +++ b/internal/ir/xds.go @@ -627,6 +627,21 @@ type HTTP2Settings struct { MaxConcurrentStreams *uint32 `json:"maxConcurrentStreams,omitempty" yaml:"maxConcurrentStreams,omitempty"` // ResetStreamOnError determines if a stream or connection is reset on messaging error. ResetStreamOnError *bool `json:"resetStreamOnError,omitempty" yaml:"resetStreamOnError,omitempty"` + // ConnectionKeepalive configures HTTP/2 PING-based keepalive settings. + ConnectionKeepalive *HTTP2ConnectionKeepalive `json:"connectionKeepalive,omitempty" yaml:"connectionKeepalive,omitempty"` +} + +// HTTP2ConnectionKeepalive configures HTTP/2 PING-based keepalive settings. +// +k8s:deepcopy-gen=true +type HTTP2ConnectionKeepalive struct { + // Interval specifies how often to send HTTP/2 PING frames. + Interval *metav1.Duration `json:"interval,omitempty" yaml:"interval,omitempty"` + // Timeout specifies how long to wait for a PING response. + Timeout *metav1.Duration `json:"timeout,omitempty" yaml:"timeout,omitempty"` + // IntervalJitter specifies a random jitter percentage added to each interval (0-100). + IntervalJitter *uint32 `json:"intervalJitter,omitempty" yaml:"intervalJitter,omitempty"` + // ConnectionIdleInterval specifies idle time before sending a PING. + ConnectionIdleInterval *metav1.Duration `json:"connectionIdleInterval,omitempty" yaml:"connectionIdleInterval,omitempty"` } // ResponseOverride defines the configuration to override specific responses with a custom one. diff --git a/internal/ir/zz_generated.deepcopy.go b/internal/ir/zz_generated.deepcopy.go index 463eefcce8..6e400cf4b0 100644 --- a/internal/ir/zz_generated.deepcopy.go +++ b/internal/ir/zz_generated.deepcopy.go @@ -1702,6 +1702,41 @@ func (in *HTTP1Settings) DeepCopy() *HTTP1Settings { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *HTTP2ConnectionKeepalive) DeepCopyInto(out *HTTP2ConnectionKeepalive) { + *out = *in + if in.Interval != nil { + in, out := &in.Interval, &out.Interval + *out = new(metav1.Duration) + **out = **in + } + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(metav1.Duration) + **out = **in + } + if in.IntervalJitter != nil { + in, out := &in.IntervalJitter, &out.IntervalJitter + *out = new(uint32) + **out = **in + } + if in.ConnectionIdleInterval != nil { + in, out := &in.ConnectionIdleInterval, &out.ConnectionIdleInterval + *out = new(metav1.Duration) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTP2ConnectionKeepalive. +func (in *HTTP2ConnectionKeepalive) DeepCopy() *HTTP2ConnectionKeepalive { + if in == nil { + return nil + } + out := new(HTTP2ConnectionKeepalive) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *HTTP2Settings) DeepCopyInto(out *HTTP2Settings) { *out = *in @@ -1725,6 +1760,11 @@ func (in *HTTP2Settings) DeepCopyInto(out *HTTP2Settings) { *out = new(bool) **out = **in } + if in.ConnectionKeepalive != nil { + in, out := &in.ConnectionKeepalive, &out.ConnectionKeepalive + *out = new(HTTP2ConnectionKeepalive) + (*in).DeepCopyInto(*out) + } } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTP2Settings. diff --git a/internal/xds/translator/cluster.go b/internal/xds/translator/cluster.go index 0b3be55247..fee6d3af92 100644 --- a/internal/xds/translator/cluster.go +++ b/internal/xds/translator/cluster.go @@ -1415,6 +1415,23 @@ func buildHTTP2Settings(opts *ir.HTTP2Settings) *corev3.Http2ProtocolOptions { } } + if opts.ConnectionKeepalive != nil { + keepalive := &corev3.KeepaliveSettings{} + if opts.ConnectionKeepalive.Interval != nil { + keepalive.Interval = durationpb.New(opts.ConnectionKeepalive.Interval.Duration) + } + if opts.ConnectionKeepalive.Timeout != nil { + keepalive.Timeout = durationpb.New(opts.ConnectionKeepalive.Timeout.Duration) + } + if opts.ConnectionKeepalive.IntervalJitter != nil { + keepalive.IntervalJitter = &xdstype.Percent{Value: float64(*opts.ConnectionKeepalive.IntervalJitter)} + } + if opts.ConnectionKeepalive.ConnectionIdleInterval != nil { + keepalive.ConnectionIdleInterval = durationpb.New(opts.ConnectionKeepalive.ConnectionIdleInterval.Duration) + } + out.ConnectionKeepalive = keepalive + } + return out } diff --git a/internal/xds/translator/listener.go b/internal/xds/translator/listener.go index 16be4b946f..85bd1eee33 100644 --- a/internal/xds/translator/listener.go +++ b/internal/xds/translator/listener.go @@ -110,6 +110,23 @@ func http2ProtocolOptions(opts *ir.HTTP2Settings) *corev3.Http2ProtocolOptions { } } + if opts.ConnectionKeepalive != nil { + keepalive := &corev3.KeepaliveSettings{} + if opts.ConnectionKeepalive.Interval != nil { + keepalive.Interval = durationpb.New(opts.ConnectionKeepalive.Interval.Duration) + } + if opts.ConnectionKeepalive.Timeout != nil { + keepalive.Timeout = durationpb.New(opts.ConnectionKeepalive.Timeout.Duration) + } + if opts.ConnectionKeepalive.IntervalJitter != nil { + keepalive.IntervalJitter = &typev3.Percent{Value: float64(*opts.ConnectionKeepalive.IntervalJitter)} + } + if opts.ConnectionKeepalive.ConnectionIdleInterval != nil { + keepalive.ConnectionIdleInterval = durationpb.New(opts.ConnectionKeepalive.ConnectionIdleInterval.Duration) + } + out.ConnectionKeepalive = keepalive + } + return out } diff --git a/internal/xds/translator/testdata/in/xds-ir/http2-keepalive.yaml b/internal/xds/translator/testdata/in/xds-ir/http2-keepalive.yaml new file mode 100644 index 0000000000..ab7e7d6a1a --- /dev/null +++ b/internal/xds/translator/testdata/in/xds-ir/http2-keepalive.yaml @@ -0,0 +1,28 @@ +http: +- name: "first-listener" + address: "::" + port: 10080 + hostnames: + - "foo.com" + path: + mergeSlashes: true + escapedSlashesAction: UnescapeAndRedirect + http2: + initialConnectionWindowSize: 65536 + initialStreamWindowSize: 33554432 + maxConcurrentStreams: 200 + connectionKeepalive: + interval: 60s + timeout: 10s + intervalJitter: 20 + connectionIdleInterval: 30s + routes: + - name: "first-route" + hostname: "*" + destination: + name: "first-route-dest" + settings: + - endpoints: + - host: "1.2.3.4" + port: 50000 + name: "first-route-dest/backend/0" diff --git a/internal/xds/translator/testdata/in/xds-ir/http2-route.yaml b/internal/xds/translator/testdata/in/xds-ir/http2-route.yaml index 2532906f5c..0de76a52d2 100644 --- a/internal/xds/translator/testdata/in/xds-ir/http2-route.yaml +++ b/internal/xds/translator/testdata/in/xds-ir/http2-route.yaml @@ -34,6 +34,11 @@ http: initialStreamWindowSize: 524288000 maxConcurrentStreams: 200 resetStreamOnError: true + connectionKeepalive: + interval: 60s + timeout: 10s + intervalJitter: 20 + connectionIdleInterval: 30s - name: "second-route" hostname: "*" pathMatch: diff --git a/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.clusters.yaml b/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.clusters.yaml new file mode 100644 index 0000000000..054f90bb71 --- /dev/null +++ b/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.clusters.yaml @@ -0,0 +1,24 @@ +- circuitBreakers: + thresholds: + - maxRetries: 1024 + commonLbConfig: {} + connectTimeout: 10s + dnsLookupFamily: V4_PREFERRED + edsClusterConfig: + edsConfig: + ads: {} + resourceApiVersion: V3 + serviceName: first-route-dest + ignoreHealthOnHostRemoval: true + lbPolicy: LEAST_REQUEST + loadBalancingPolicy: + policies: + - typedExtensionConfig: + name: envoy.load_balancing_policies.least_request + typedConfig: + '@type': type.googleapis.com/envoy.extensions.load_balancing_policies.least_request.v3.LeastRequest + localityLbConfig: + localityWeightedLbConfig: {} + name: first-route-dest + perConnectionBufferLimitBytes: 32768 + type: EDS diff --git a/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.endpoints.yaml b/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.endpoints.yaml new file mode 100644 index 0000000000..3b3f2d0907 --- /dev/null +++ b/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.endpoints.yaml @@ -0,0 +1,12 @@ +- clusterName: first-route-dest + endpoints: + - lbEndpoints: + - endpoint: + address: + socketAddress: + address: 1.2.3.4 + portValue: 50000 + loadBalancingWeight: 1 + loadBalancingWeight: 1 + locality: + region: first-route-dest/backend/0 diff --git a/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.listeners.yaml b/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.listeners.yaml new file mode 100644 index 0000000000..00964415dd --- /dev/null +++ b/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.listeners.yaml @@ -0,0 +1,41 @@ +- address: + socketAddress: + address: '::' + portValue: 10080 + defaultFilterChain: + filters: + - name: envoy.filters.network.http_connection_manager + typedConfig: + '@type': type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager + commonHttpProtocolOptions: + headersWithUnderscoresAction: REJECT_REQUEST + http2ProtocolOptions: + connectionKeepalive: + connectionIdleInterval: 30s + interval: 60s + intervalJitter: + value: 20 + timeout: 10s + initialConnectionWindowSize: 33554432 + initialStreamWindowSize: 65536 + maxConcurrentStreams: 200 + httpFilters: + - name: envoy.filters.http.router + typedConfig: + '@type': type.googleapis.com/envoy.extensions.filters.http.router.v3.Router + suppressEnvoyHeaders: true + mergeSlashes: true + normalizePath: true + pathWithEscapedSlashesAction: UNESCAPE_AND_REDIRECT + rds: + configSource: + ads: {} + resourceApiVersion: V3 + routeConfigName: first-listener + serverHeaderTransformation: PASS_THROUGH + statPrefix: http-10080 + useRemoteAddress: true + name: first-listener + maxConnectionsToAcceptPerSocketEvent: 1 + name: first-listener + perConnectionBufferLimitBytes: 32768 diff --git a/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.routes.yaml b/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.routes.yaml new file mode 100644 index 0000000000..0b5b4bee7b --- /dev/null +++ b/internal/xds/translator/testdata/out/xds-ir/http2-keepalive.routes.yaml @@ -0,0 +1,14 @@ +- ignorePortInHostMatching: true + name: first-listener + virtualHosts: + - domains: + - '*' + name: first-listener/* + routes: + - match: + prefix: / + name: first-route + route: + cluster: first-route-dest + upgradeConfigs: + - upgradeType: websocket diff --git a/internal/xds/translator/testdata/out/xds-ir/http2-route.clusters.yaml b/internal/xds/translator/testdata/out/xds-ir/http2-route.clusters.yaml index ed267e2009..76192596d3 100644 --- a/internal/xds/translator/testdata/out/xds-ir/http2-route.clusters.yaml +++ b/internal/xds/translator/testdata/out/xds-ir/http2-route.clusters.yaml @@ -27,6 +27,12 @@ '@type': type.googleapis.com/envoy.extensions.upstreams.http.v3.HttpProtocolOptions explicitHttpConfig: http2ProtocolOptions: + connectionKeepalive: + connectionIdleInterval: 30s + interval: 60s + intervalJitter: + value: 20 + timeout: 10s initialConnectionWindowSize: 524288000 initialStreamWindowSize: 1048576 maxConcurrentStreams: 200 diff --git a/release-notes/current.yaml b/release-notes/current.yaml index b4d0c5a0ad..c834b94f16 100644 --- a/release-notes/current.yaml +++ b/release-notes/current.yaml @@ -14,6 +14,7 @@ new features: | Added support for shadow mode in local rate limiting. Added `egctl config envoy-gateway` commands to retrieve Envoy Gateway admin config dumps. The DirectResponse body in HTTPFilter now supports Envoy command operators for dynamic content. See https://www.envoyproxy.io/docs/envoy/latest/configuration/observability/access_log/usage#command-operators for more details. + Added HTTP/2 connection keepalive support to ClientTrafficPolicy and BackendTrafficPolicy. Support for configuring weights for locality zones. bug fixes: | diff --git a/site/content/en/latest/api/extension_types.md b/site/content/en/latest/api/extension_types.md index 08a7b0b8e3..cd8131584e 100644 --- a/site/content/en/latest/api/extension_types.md +++ b/site/content/en/latest/api/extension_types.md @@ -2388,6 +2388,23 @@ _Appears in:_ | `disableSafeMaxConnectionDuration` | _boolean_ | false | | DisableSafeMaxConnectionDuration controls the close behavior for HTTP/1 connections.
By default, connection closure is delayed until the next request arrives after maxConnectionDuration is exceeded.
It then adds a Connection: close header and gracefully closes the connection after the response completes.
When set to true (disabled), Envoy uses its default drain behavior, closing the connection shortly after maxConnectionDuration elapses.
Has no effect unless maxConnectionDuration is set. | +#### HTTP2ConnectionKeepalive + + + +HTTP2ConnectionKeepalive configures HTTP/2 PING-based keepalive settings. + +_Appears in:_ +- [HTTP2Settings](#http2settings) + +| Field | Type | Required | Default | Description | +| --- | --- | --- | --- | --- | +| `interval` | _[Duration](https://gateway-api.sigs.k8s.io/reference/1.4/spec/#duration)_ | false | | Interval specifies how often to send HTTP/2 PING frames to keep the connection alive. | +| `timeout` | _[Duration](https://gateway-api.sigs.k8s.io/reference/1.4/spec/#duration)_ | false | | Timeout specifies how long to wait for a PING response before considering the connection dead. | +| `intervalJitter` | _integer_ | false | | IntervalJitter specifies a random jitter percentage added to each interval.
Defaults to 15% if not specified. | +| `connectionIdleInterval` | _[Duration](https://gateway-api.sigs.k8s.io/reference/1.4/spec/#duration)_ | false | | ConnectionIdleInterval specifies how long a connection must be idle before a PING is sent. | + + #### HTTP2Settings @@ -2405,6 +2422,7 @@ _Appears in:_ | `initialConnectionWindowSize` | _[Quantity](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.29/#quantity-resource-api)_ | false | | InitialConnectionWindowSize sets the initial window size for HTTP/2 connections.
If not set, the default value is 1 MiB. | | `maxConcurrentStreams` | _integer_ | false | | MaxConcurrentStreams sets the maximum number of concurrent streams allowed per connection.
If not set, the default value is 100. | | `onInvalidMessage` | _[InvalidMessageAction](#invalidmessageaction)_ | false | | OnInvalidMessage determines if Envoy will terminate the connection or just the offending stream in the event of HTTP messaging error
It's recommended for L2 Envoy deployments to set this value to TerminateStream.
https://www.envoyproxy.io/docs/envoy/latest/configuration/best_practices/level_two
Default: TerminateConnection | +| `connectionKeepalive` | _[HTTP2ConnectionKeepalive](#http2connectionkeepalive)_ | false | | ConnectionKeepalive configures HTTP/2 connection keepalive using PING frames. | #### HTTP3Settings diff --git a/test/helm/gateway-crds-helm/all.out.yaml b/test/helm/gateway-crds-helm/all.out.yaml index a38447564d..9521016e38 100644 --- a/test/helm/gateway-crds-helm/all.out.yaml +++ b/test/helm/gateway-crds-helm/all.out.yaml @@ -21815,6 +21815,34 @@ spec: http2: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how long a connection + must be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send HTTP/2 PING + frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait for a PING + response before considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -24994,6 +25022,34 @@ spec: http2: description: HTTP2 provides HTTP/2 configuration on the listener. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how long a connection + must be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send HTTP/2 PING + frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait for a PING + response before considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -26833,6 +26889,36 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how + long a connection must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -40654,6 +40740,41 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using + PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection + must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies + how often to send HTTP/2 PING + frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies + how long to wait for a PING + response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -41961,6 +42082,41 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using + PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection + must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies + how often to send HTTP/2 PING + frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies + how long to wait for a PING + response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -43424,6 +43580,38 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using PING + frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection must + be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how + often to send HTTP/2 PING frames to + keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long + to wait for a PING response before + considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -44804,6 +44992,37 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before + a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often + to send HTTP/2 PING frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to + wait for a PING response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -47523,6 +47742,36 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -48715,6 +48964,36 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -50118,6 +50397,37 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before + a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often + to send HTTP/2 PING frames to keep the + connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long + to wait for a PING response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -51578,6 +51888,36 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ diff --git a/test/helm/gateway-crds-helm/envoy-gateway-crds.out.yaml b/test/helm/gateway-crds-helm/envoy-gateway-crds.out.yaml index ba8d3a77c7..c2f9d491e4 100644 --- a/test/helm/gateway-crds-helm/envoy-gateway-crds.out.yaml +++ b/test/helm/gateway-crds-helm/envoy-gateway-crds.out.yaml @@ -1145,6 +1145,34 @@ spec: http2: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how long a connection + must be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send HTTP/2 PING + frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait for a PING + response before considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -4324,6 +4352,34 @@ spec: http2: description: HTTP2 provides HTTP/2 configuration on the listener. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how long a connection + must be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send HTTP/2 PING + frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait for a PING + response before considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -6163,6 +6219,36 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 connection + keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies how + long a connection must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -19984,6 +20070,41 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using + PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection + must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies + how often to send HTTP/2 PING + frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies + how long to wait for a PING + response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -21291,6 +21412,41 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using + PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection + must be idle before a PING is + sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies + how often to send HTTP/2 PING + frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies + how long to wait for a PING + response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -22754,6 +22910,38 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using PING + frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval + specifies how long a connection must + be idle before a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how + often to send HTTP/2 PING frames to + keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long + to wait for a PING response before + considering the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -24134,6 +24322,37 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before + a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often + to send HTTP/2 PING frames to keep the connection + alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to + wait for a PING response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -26853,6 +27072,36 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -28045,6 +28294,36 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -29448,6 +29727,37 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures + HTTP/2 connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before + a PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often + to send HTTP/2 PING frames to keep the + connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long + to wait for a PING response before considering + the connection dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ @@ -30908,6 +31218,36 @@ spec: description: HTTP2 provides HTTP/2 configuration for backend connections. properties: + connectionKeepalive: + description: ConnectionKeepalive configures HTTP/2 + connection keepalive using PING frames. + properties: + connectionIdleInterval: + description: ConnectionIdleInterval specifies + how long a connection must be idle before a + PING is sent. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + interval: + description: Interval specifies how often to send + HTTP/2 PING frames to keep the connection alive. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + intervalJitter: + description: |- + IntervalJitter specifies a random jitter percentage added to each interval. + Defaults to 15% if not specified. + format: int32 + maximum: 100 + minimum: 0 + type: integer + timeout: + description: Timeout specifies how long to wait + for a PING response before considering the connection + dead. + pattern: ^([0-9]{1,5}(h|m|s|ms)){1,4}$ + type: string + type: object initialConnectionWindowSize: allOf: - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$