xds: Add a KeyValueStore-backed xDS delegate extension to contrib (#22921)
An xDS delegate extension point was added in #22473 to enable custom behavior upon receiving and loading xDS resources. This change creates an implementation of the XdsResourcesDelegate interface that is backed by a KeyValueStore. The intended use case is to enable persisting xDS resources and loading them on startup in Envoy Mobile, in the event that the xDS control plane is unreachable. Signed-off-by: Ali Beyad abeyad@google.com Risk Level: Low Testing: Unit & Integration tests Docs Changes: N/A (hidden experimental feature) Release Notes: N/A Platform Specific Features: N/A Signed-off-by: Ali Beyad <abeyad@google.com> Mirrored from https://github.com/envoyproxy/envoy @ f28db324be3fcb6e91eb5a89d90c08617f76a2b2pull/626/head
parent
afa3db609f
commit
69d44c929d
3 changed files with 42 additions and 0 deletions
@ -0,0 +1,12 @@ |
||||
# DO NOT EDIT. This file is generated by tools/proto_format/proto_sync.py. |
||||
|
||||
load("@envoy_api//bazel:api_build_system.bzl", "api_proto_package") |
||||
|
||||
licenses(["notice"]) # Apache 2 |
||||
|
||||
api_proto_package( |
||||
deps = [ |
||||
"//envoy/config/common/key_value/v3:pkg", |
||||
"@com_github_cncf_udpa//udpa/annotations:pkg", |
||||
], |
||||
) |
@ -0,0 +1,29 @@ |
||||
syntax = "proto3"; |
||||
|
||||
package envoy.extensions.config.v3alpha; |
||||
|
||||
import "envoy/config/common/key_value/v3/config.proto"; |
||||
|
||||
import "udpa/annotations/status.proto"; |
||||
|
||||
option java_package = "io.envoyproxy.envoy.extensions.config.v3alpha"; |
||||
option java_outer_classname = "KvStoreXdsDelegateConfigProto"; |
||||
option java_multiple_files = true; |
||||
option go_package = "github.com/envoyproxy/go-control-plane/envoy/extensions/config/v3alpha"; |
||||
option (udpa.annotations.file_status).package_version_status = ACTIVE; |
||||
|
||||
// [#extension: envoy.xds_delegates.kv_store] |
||||
// |
||||
// Configuration for a KeyValueStore-based XdsResourcesDelegate implementation. This implementation |
||||
// updates the underlying KV store with xDS resources received from the configured management |
||||
// servers, enabling configuration to be persisted locally and used on startup in case connectivity |
||||
// with the xDS management servers could not be established. |
||||
// |
||||
// The KV Store based delegate's handling of wildcard resources (empty resource list or "*") is |
||||
// designed for use with O(100) resources or fewer, so it's not currently advised to use this |
||||
// feature for large configurations with heavy use of wildcard resources. |
||||
message KeyValueStoreXdsDelegateConfig { |
||||
// Configuration for the KeyValueStore that holds the xDS resources. |
||||
// [#allow-fully-qualified-name:] |
||||
.envoy.config.common.key_value.v3.KeyValueStoreConfig key_value_store_config = 1; |
||||
} |
Loading…
Reference in new issue