Contour: Http2ProtocolOptions is deprecated

Created on 9 Feb 2021  路  7Comments  路  Source: projectcontour/contour

When configuring the Http2Protocol options, for h2 or h2c clusters (https://github.com/projectcontour/contour/blob/main/internal/envoy/v3/cluster.go#L132), the field is marked as deprecated.

Looks like we need to switch to: envoy_api_field_extensions.upstreams.http.v3.HttpProtocolOptions.upstream_http_protocol_options

kinfeature lifecyclneeds-triage

Most helpful comment

image

All 7 comments

From the docs it doesn't look like typed_extension_protocol_options is deprecated but rather upstream_http_protocol_options is deprecated: https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/cluster/v3/cluster.proto#envoy-v3-api-field-config-cluster-v3-cluster-upstream-http-protocol-options

It does look like we could use explicit_http_config in the helper to explicitly use HTTP/2: https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/upstreams/http/v3/http_protocol_options.proto#envoy-v3-api-field-extensions-upstreams-http-v3-httpprotocoloptions-explicit-http-config (specifically set UpstreamProtocolOptions field to an *HttpProtocolOptions_ExplicitHttpConfig_)

I thought I fixed this with https://github.com/projectcontour/contour/pull/3321 -- is something wrong with that change?

I thought I fixed this with #3321 -- is something wrong with that change?

Oh yeah, you totally already used the Explicit field (the proto/oneof translated to Go confused me for a bit haha), I think your change is already up to date with the latest APIs, not sure what @stevesloka is referencing

In the envoy package under clusters, we're using that field still which is marked as deprecated:
image

Yeah looks like your code is not up to date. This was the one that got merged, reverted, then re-merged :/

image

Was this page helpful?
0 / 5 - 0 ratings

Related issues

phylake picture phylake  路  4Comments

davecheney picture davecheney  路  6Comments

jedsalazar picture jedsalazar  路  6Comments

jjimenezmont picture jjimenezmont  路  5Comments

stevesloka picture stevesloka  路  3Comments