Skip to content

Commit 96facec

Browse files
Google APIscopybara-github
authored andcommitted
feat(spanner): Add resource reference annotation to backup schedules
docs(spanner): Add an example to filter backups based on schedule name PiperOrigin-RevId: 662402292
1 parent 182e5df commit 96facec

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

google/spanner/admin/database/v1/backup.proto

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -184,8 +184,12 @@ message Backup {
184184
// the list of all backup schedule URIs that are associated with creating
185185
// this backup. If collapsing is not done, then this field captures the
186186
// single backup schedule URI associated with creating this backup.
187-
repeated string backup_schedules = 14
188-
[(google.api.field_behavior) = OUTPUT_ONLY];
187+
repeated string backup_schedules = 14 [
188+
(google.api.field_behavior) = OUTPUT_ONLY,
189+
(google.api.resource_reference) = {
190+
type: "spanner.googleapis.com/BackupSchedule"
191+
}
192+
];
189193

190194
// Output only. Populated only for backups in an incremental backup chain.
191195
// Backups share the same chain id if and only if they belong to the same
@@ -426,6 +430,7 @@ message ListBackupsRequest {
426430
// * `expire_time` (and values are of the format YYYY-MM-DDTHH:MM:SSZ)
427431
// * `version_time` (and values are of the format YYYY-MM-DDTHH:MM:SSZ)
428432
// * `size_bytes`
433+
// * `backup_schedules`
429434
//
430435
// You can combine multiple expressions by enclosing each expression in
431436
// parentheses. By default, expressions are combined with AND logic, but
@@ -444,6 +449,8 @@ message ListBackupsRequest {
444449
// * `expire_time < \"2018-03-28T14:50:00Z\"`
445450
// - The backup `expire_time` is before 2018-03-28T14:50:00Z.
446451
// * `size_bytes > 10000000000` - The backup's size is greater than 10GB
452+
// * `backup_schedules:daily`
453+
// - The backup is created from a schedule with "daily" in its name.
447454
string filter = 2;
448455

449456
// Number of backups to be returned in the response. If 0 or

0 commit comments

Comments
 (0)