Debian Codegraph @

xds/core/v3/collection_entry.proto

raw
1 syntax = "proto3";
2
3 package xds.core.v3;
4
5 import "google/protobuf/any.proto";
6
7 import "xds/annotations/v3/status.proto";
8 import "xds/core/v3/resource_locator.proto";
9
10 import "validate/validate.proto";
11
12 option java_outer_classname = "CollectionEntryProto";
13 option java_multiple_files = true;
14 option java_package = "com.github.xds.core.v3";
15 option go_package = "github.com/cncf/xds/go/xds/core/v3";
16
17 option (xds.annotations.v3.file_status).work_in_progress = true;
18
19 // xDS collection resource wrapper. This encapsulates a xDS resource when
20 // appearing inside a list collection resource. List collection resources are
21 // regular Resource messages of type:
22 //
23 // .. code-block:: proto
24 //
25 // message <T>Collection {
26 // repeated CollectionEntry resources = 1;
27 // }
28 //
29 message CollectionEntry {
30 // Inlined resource entry.
31 message InlineEntry {
32 // Optional name to describe the inlined resource. Resource names must match
33 // ``[a-zA-Z0-9_-\./]+`` (TODO(htuch): turn this into a PGV constraint once
34 // finalized, probably should be a RFC3986 pchar). This name allows
35 // reference via the #entry directive in ResourceLocator.
36 string name = 1 [(validate.rules).string.pattern = "^[0-9a-zA-Z_\\-\\.~:]+$"];
37
38 // The resource's logical version. It is illegal to have the same named xDS
39 // resource name at a given version with different resource payloads.
40 string version = 2;
41
42 // The resource payload, including type URL.
43 google.protobuf.Any resource = 3;
44 }
45
46 oneof resource_specifier {
47 option (validate.required) = true;
48
49 // A resource locator describing how the member resource is to be located.
50 ResourceLocator locator = 1;
51
52 // The resource is inlined in the list collection.
53 InlineEntry inline_entry = 2;
54 }
55 }