Skip to content

Commit 18c4322

Browse files
committed
Labels are consistently validated across services
* The combined size of a key/value pair cannot exceed 4096 bytes Signed-off-by: Jess Valarezo <[email protected]>
1 parent d700a9c commit 18c4322

19 files changed

Lines changed: 189 additions & 8 deletions

File tree

api/services/containers/v1/containers.pb.go

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/services/containers/v1/containers.proto

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ message Container {
4242

4343
// Labels provides an area to include arbitrary data on containers.
4444
//
45+
// The combined size of a key/value pair cannot exceed 4096 bytes.
46+
//
4547
// Note that to add a new value to this field, read the existing set and
4648
// include the entire result in the update call.
4749
map<string, string> labels = 2;

api/services/content/v1/content.pb.go

Lines changed: 6 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/services/content/v1/content.proto

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,9 @@ message Info {
8787
// UpdatedAt provides the time the info was last updated.
8888
google.protobuf.Timestamp updated_at = 4 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false];
8989

90-
// Labels are arbitrary data on content.
90+
// Labels are arbitrary data on snapshots.
91+
//
92+
// The combined size of a key/value pair cannot exceed 4096 bytes.
9193
map<string, string> labels = 5;
9294
}
9395

@@ -270,7 +272,9 @@ message WriteContentRequest {
270272
// returned with the current write state.
271273
bytes data = 6;
272274

273-
// Labels are arbitrary data to set on commit.
275+
// Labels are arbitrary data on snapshots.
276+
//
277+
// The combined size of a key/value pair cannot exceed 4096 bytes.
274278
map<string, string> labels = 7;
275279
}
276280

api/services/images/v1/images.pb.go

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/services/images/v1/images.proto

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ message Image {
5151
// and do not get inherited into the package image in any way.
5252
//
5353
// Labels may be updated using the field mask.
54+
// The combined size of a key/value pair cannot exceed 4096 bytes.
5455
map<string, string> labels = 2;
5556

5657
// Target describes the content entry point of the image.

api/services/namespaces/v1/namespace.pb.go

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/services/namespaces/v1/namespace.proto

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ message Namespace {
3232

3333
// Labels provides an area to include arbitrary data on namespaces.
3434
//
35+
// The combined size of a key/value pair cannot exceed 4096 bytes.
36+
//
3537
// Note that to add a new value to this field, read the existing set and
3638
// include the entire result in the update call.
3739
map<string, string> labels = 2;

api/services/snapshot/v1/snapshots.pb.go

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/services/snapshot/v1/snapshots.proto

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ message PrepareSnapshotRequest {
2929
string parent = 3;
3030

3131
// Labels are arbitrary data on snapshots.
32+
//
33+
// The combined size of a key/value pair cannot exceed 4096 bytes.
3234
map<string, string> labels = 4;
3335
}
3436

@@ -42,6 +44,8 @@ message ViewSnapshotRequest {
4244
string parent = 3;
4345

4446
// Labels are arbitrary data on snapshots.
47+
//
48+
// The combined size of a key/value pair cannot exceed 4096 bytes.
4549
map<string, string> labels = 4;
4650
}
4751

@@ -69,6 +73,8 @@ message CommitSnapshotRequest {
6973
string key = 3;
7074

7175
// Labels are arbitrary data on snapshots.
76+
//
77+
// The combined size of a key/value pair cannot exceed 4096 bytes.
7278
map<string, string> labels = 4;
7379
}
7480

@@ -99,6 +105,8 @@ message Info {
99105
google.protobuf.Timestamp updated_at = 5 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false];
100106

101107
// Labels are arbitrary data on snapshots.
108+
//
109+
// The combined size of a key/value pair cannot exceed 4096 bytes.
102110
map<string, string> labels = 6;
103111
}
104112

0 commit comments

Comments
 (0)