api/config: deprecate build_version in DiscoveryRequest. (#9620)

This is a followup to #9301, where it was not possible to deprecate a
field on DiscoveryRequest as we were previously assuming identical v2/v3
transport protocols. After this deprecation, build_version can't appear
in v3 messages, and we need to convert back to a true v2
DiscoveryRequest prior to JSON serializing for REST.

There's more work to be done in the future, when we add new v3-only
fields, but this should work for 1.13.0. Future work tracked at
https://github.com/envoyproxy/envoy/issues/9619.

Risk level: Low
Testing: coverage of the behaviors for both gRPC and REST config sources
  is provided by api_version_integration_test (failing previously as soon
  as build_version was deprecated).

Fixes #9604

Signed-off-by: Harvey Tuch <htuch@google.com>

Mirrored from https://github.com/envoyproxy/envoy @ 0ee6212b02bdab7b3d66e868449ac93556e63118
master-ci-test
data-plane-api(CircleCI) 5 years ago
parent ab80ff8c19
commit 6467390343
  1. 5
      envoy/api/v2/core/base.proto
  2. 11
      envoy/config/core/v3alpha/base.proto

@ -154,9 +154,8 @@ message Node {
// This is motivated by informing a management server during canary which
// version of Envoy is being tested in a heterogeneous fleet. This will be set
// by Envoy in management server RPCs.
// This field will be deprecated in favor of the user_agent_name and user_agent_version values.
// [#comment:TODO(yanavlasov): Deprecate once issue #9604 is fixed.]
string build_version = 5;
// This field is deprecated in favor of the user_agent_name and user_agent_version values.
string build_version = 5 [deprecated = true];
// Free-form string that identifies the entity requesting config.
// E.g. "envoy" or "grpc"

@ -132,6 +132,10 @@ message Extension {
message Node {
option (udpa.annotations.versioning).previous_message_type = "envoy.api.v2.core.Node";
reserved 5;
reserved "build_version";
// An opaque node identifier for the Envoy node. This also provides the local
// service node name. It should be set if any of the following features are
// used: :ref:`statsd <arch_overview_statistics>`, :ref:`CDS
@ -160,13 +164,6 @@ message Node {
// Locality specifying where the Envoy instance is running.
Locality locality = 4;
// This is motivated by informing a management server during canary which
// version of Envoy is being tested in a heterogeneous fleet. This will be set
// by Envoy in management server RPCs.
// This field will be deprecated in favor of the user_agent_name and user_agent_version values.
// [#comment:TODO(yanavlasov): Deprecate once issue #9604 is fixed.]
string build_version = 5;
// Free-form string that identifies the entity requesting config.
// E.g. "envoy" or "grpc"
string user_agent_name = 6;

Loading…
Cancel
Save