From ff04940febe937dcf0e62e524f9ae214da4b52e2 Mon Sep 17 00:00:00 2001 From: Yutong Li Date: Tue, 2 Jun 2020 23:36:45 +0000 Subject: [PATCH] config dump: add EDS (#3362) Signed-off-by: Yutong Li --- api/envoy/admin/v3/config_dump.proto | 34 +++++++++++++++ api/envoy/admin/v4alpha/config_dump.proto | 42 +++++++++++++++++++ .../envoy/admin/v3/config_dump.proto | 34 +++++++++++++++ .../envoy/admin/v4alpha/config_dump.proto | 42 +++++++++++++++++++ 4 files changed, 152 insertions(+) diff --git a/api/envoy/admin/v3/config_dump.proto b/api/envoy/admin/v3/config_dump.proto index b3c3836a8cc0..6cfdf8eae4d5 100644 --- a/api/envoy/admin/v3/config_dump.proto +++ b/api/envoy/admin/v3/config_dump.proto @@ -32,6 +32,7 @@ message ConfigDump { // * *clusters*: :ref:`ClustersConfigDump ` // * *listeners*: :ref:`ListenersConfigDump ` // * *routes*: :ref:`RoutesConfigDump ` + // * *endpoints*: :ref:`EndpointsConfigDump ` // // You can filter output with the resource and mask query parameters. // See :ref:`/config_dump?resource={} `, @@ -346,3 +347,36 @@ message SecretsConfigDump { // warming in preparation to service clusters or listeners. repeated DynamicSecret dynamic_warming_secrets = 3; } + +// [#not-implemented-hide:] +// Envoy's EDS implementation *will* fill this message with all currently known endpoints. Endpoint +// configuration information can be used to recreate an Envoy configuration by populating all +// endpoints as static endpoints or by returning them in an EDS response. +message EndpointsConfigDump { + message StaticEndpointConfig { + // The endpoint config. + google.protobuf.Any endpoint_config = 1; + + // The timestamp when the Endpoint was last updated. + google.protobuf.Timestamp last_updated = 2; + } + + message DynamicEndpointConfig { + // This is the per-resource version information. This version is currently taken from the + // :ref:`version_info ` field at the time that + // the endpoint configuration was loaded. + string version_info = 1; + + // The endpoint config. + google.protobuf.Any endpoint_config = 2; + + // The timestamp when the Endpoint was last updated. + google.protobuf.Timestamp last_updated = 3; + } + + // The statically loaded endpoint configs. + repeated StaticEndpointConfig static_endpoint_configs = 2; + + // The dynamically loaded endpoint configs. + repeated DynamicEndpointConfig dynamic_endpoint_configs = 3; +} diff --git a/api/envoy/admin/v4alpha/config_dump.proto b/api/envoy/admin/v4alpha/config_dump.proto index 02709a414506..52b591b6af03 100644 --- a/api/envoy/admin/v4alpha/config_dump.proto +++ b/api/envoy/admin/v4alpha/config_dump.proto @@ -32,6 +32,7 @@ message ConfigDump { // * *clusters*: :ref:`ClustersConfigDump ` // * *listeners*: :ref:`ListenersConfigDump ` // * *routes*: :ref:`RoutesConfigDump ` + // * *endpoints*: :ref:`EndpointsConfigDump ` // // You can filter output with the resource and mask query parameters. // See :ref:`/config_dump?resource={} `, @@ -340,3 +341,44 @@ message SecretsConfigDump { // warming in preparation to service clusters or listeners. repeated DynamicSecret dynamic_warming_secrets = 3; } + +// [#not-implemented-hide:] +// Envoy's EDS implementation *will* fill this message with all currently known endpoints. Endpoint +// configuration information can be used to recreate an Envoy configuration by populating all +// endpoints as static endpoints or by returning them in an EDS response. +message EndpointsConfigDump { + option (udpa.annotations.versioning).previous_message_type = "envoy.admin.v3.EndpointsConfigDump"; + + message StaticEndpointConfig { + option (udpa.annotations.versioning).previous_message_type = + "envoy.admin.v3.EndpointsConfigDump.StaticEndpointConfig"; + + // The endpoint config. + google.protobuf.Any endpoint_config = 1; + + // The timestamp when the Endpoint was last updated. + google.protobuf.Timestamp last_updated = 2; + } + + message DynamicEndpointConfig { + option (udpa.annotations.versioning).previous_message_type = + "envoy.admin.v3.EndpointsConfigDump.DynamicEndpointConfig"; + + // This is the per-resource version information. This version is currently taken from the + // :ref:`version_info ` field at the time that + // the endpoint configuration was loaded. + string version_info = 1; + + // The endpoint config. + google.protobuf.Any endpoint_config = 2; + + // The timestamp when the Endpoint was last updated. + google.protobuf.Timestamp last_updated = 3; + } + + // The statically loaded endpoint configs. + repeated StaticEndpointConfig static_endpoint_configs = 2; + + // The dynamically loaded endpoint configs. + repeated DynamicEndpointConfig dynamic_endpoint_configs = 3; +} diff --git a/generated_api_shadow/envoy/admin/v3/config_dump.proto b/generated_api_shadow/envoy/admin/v3/config_dump.proto index b3c3836a8cc0..6cfdf8eae4d5 100644 --- a/generated_api_shadow/envoy/admin/v3/config_dump.proto +++ b/generated_api_shadow/envoy/admin/v3/config_dump.proto @@ -32,6 +32,7 @@ message ConfigDump { // * *clusters*: :ref:`ClustersConfigDump ` // * *listeners*: :ref:`ListenersConfigDump ` // * *routes*: :ref:`RoutesConfigDump ` + // * *endpoints*: :ref:`EndpointsConfigDump ` // // You can filter output with the resource and mask query parameters. // See :ref:`/config_dump?resource={} `, @@ -346,3 +347,36 @@ message SecretsConfigDump { // warming in preparation to service clusters or listeners. repeated DynamicSecret dynamic_warming_secrets = 3; } + +// [#not-implemented-hide:] +// Envoy's EDS implementation *will* fill this message with all currently known endpoints. Endpoint +// configuration information can be used to recreate an Envoy configuration by populating all +// endpoints as static endpoints or by returning them in an EDS response. +message EndpointsConfigDump { + message StaticEndpointConfig { + // The endpoint config. + google.protobuf.Any endpoint_config = 1; + + // The timestamp when the Endpoint was last updated. + google.protobuf.Timestamp last_updated = 2; + } + + message DynamicEndpointConfig { + // This is the per-resource version information. This version is currently taken from the + // :ref:`version_info ` field at the time that + // the endpoint configuration was loaded. + string version_info = 1; + + // The endpoint config. + google.protobuf.Any endpoint_config = 2; + + // The timestamp when the Endpoint was last updated. + google.protobuf.Timestamp last_updated = 3; + } + + // The statically loaded endpoint configs. + repeated StaticEndpointConfig static_endpoint_configs = 2; + + // The dynamically loaded endpoint configs. + repeated DynamicEndpointConfig dynamic_endpoint_configs = 3; +} diff --git a/generated_api_shadow/envoy/admin/v4alpha/config_dump.proto b/generated_api_shadow/envoy/admin/v4alpha/config_dump.proto index 02709a414506..52b591b6af03 100644 --- a/generated_api_shadow/envoy/admin/v4alpha/config_dump.proto +++ b/generated_api_shadow/envoy/admin/v4alpha/config_dump.proto @@ -32,6 +32,7 @@ message ConfigDump { // * *clusters*: :ref:`ClustersConfigDump ` // * *listeners*: :ref:`ListenersConfigDump ` // * *routes*: :ref:`RoutesConfigDump ` + // * *endpoints*: :ref:`EndpointsConfigDump ` // // You can filter output with the resource and mask query parameters. // See :ref:`/config_dump?resource={} `, @@ -340,3 +341,44 @@ message SecretsConfigDump { // warming in preparation to service clusters or listeners. repeated DynamicSecret dynamic_warming_secrets = 3; } + +// [#not-implemented-hide:] +// Envoy's EDS implementation *will* fill this message with all currently known endpoints. Endpoint +// configuration information can be used to recreate an Envoy configuration by populating all +// endpoints as static endpoints or by returning them in an EDS response. +message EndpointsConfigDump { + option (udpa.annotations.versioning).previous_message_type = "envoy.admin.v3.EndpointsConfigDump"; + + message StaticEndpointConfig { + option (udpa.annotations.versioning).previous_message_type = + "envoy.admin.v3.EndpointsConfigDump.StaticEndpointConfig"; + + // The endpoint config. + google.protobuf.Any endpoint_config = 1; + + // The timestamp when the Endpoint was last updated. + google.protobuf.Timestamp last_updated = 2; + } + + message DynamicEndpointConfig { + option (udpa.annotations.versioning).previous_message_type = + "envoy.admin.v3.EndpointsConfigDump.DynamicEndpointConfig"; + + // This is the per-resource version information. This version is currently taken from the + // :ref:`version_info ` field at the time that + // the endpoint configuration was loaded. + string version_info = 1; + + // The endpoint config. + google.protobuf.Any endpoint_config = 2; + + // The timestamp when the Endpoint was last updated. + google.protobuf.Timestamp last_updated = 3; + } + + // The statically loaded endpoint configs. + repeated StaticEndpointConfig static_endpoint_configs = 2; + + // The dynamically loaded endpoint configs. + repeated DynamicEndpointConfig dynamic_endpoint_configs = 3; +}