-
Notifications
You must be signed in to change notification settings - Fork 22
/
data.proto
799 lines (642 loc) · 28.2 KB
/
data.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
// Copyright 2022 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
syntax = "proto3";
package google.events.cloud.alloydb.v1;
import "google/protobuf/duration.proto";
import "google/protobuf/timestamp.proto";
import "google/type/dayofweek.proto";
import "google/type/timeofday.proto";
option csharp_namespace = "Google.Events.Protobuf.Cloud.AlloyDb.V1";
option php_namespace = "Google\\Events\\Cloud\\AlloyDb\\V1";
option ruby_package = "Google::Events::Cloud::AlloyDB::V1";
// The username/password for a database user. Used for specifying initial
// users at cluster creation time.
message UserPassword {
// The database username.
string user = 1;
// The initial password for the user.
string password = 2;
}
// Subset of the source instance configuration that is available when reading
// the cluster resource.
message MigrationSource {
// Denote the type of migration source that created this cluster.
enum MigrationSourceType {
// Migration source is unknown.
MIGRATION_SOURCE_TYPE_UNSPECIFIED = 0;
// DMS source means the cluster was created via DMS migration job.
DMS = 1;
}
// Output only. The host and port of the on-premises instance in host:port
// format
string host_port = 1;
// Output only. Place holder for the external source identifier(e.g DMS job
// name) that created the cluster.
string reference_id = 2;
// Output only. Type of migration source.
MigrationSourceType source_type = 3;
}
// EncryptionConfig describes the encryption config of a cluster or a backup
// that is encrypted with a CMEK (customer-managed encryption key).
message EncryptionConfig {
// The fully-qualified resource name of the KMS key.
// Each Cloud KMS key is regionalized and has the following format:
// projects/[PROJECT]/locations/[REGION]/keyRings/[RING]/cryptoKeys/[KEY_NAME]
string kms_key_name = 1;
}
// EncryptionInfo describes the encryption information of a cluster or a backup.
message EncryptionInfo {
// Possible encryption types.
enum Type {
// Encryption type not specified. Defaults to GOOGLE_DEFAULT_ENCRYPTION.
TYPE_UNSPECIFIED = 0;
// The data is encrypted at rest with a key that is fully managed by Google.
// No key version will be populated. This is the default state.
GOOGLE_DEFAULT_ENCRYPTION = 1;
// The data is encrypted at rest with a key that is managed by the customer.
// KMS key versions will be populated.
CUSTOMER_MANAGED_ENCRYPTION = 2;
}
// Output only. Type of encryption.
Type encryption_type = 1;
// Output only. Cloud KMS key versions that are being used to protect the
// database or the backup.
repeated string kms_key_versions = 2;
}
// SSL configuration for an AlloyDB Cluster.
message SslConfig {
// SSL mode options.
enum SslMode {
// SSL mode not specified. Defaults to SSL_MODE_ALLOW.
SSL_MODE_UNSPECIFIED = 0;
// SSL connections are optional. CA verification not enforced.
SSL_MODE_ALLOW = 1;
// SSL connections are required. CA verification not enforced.
// Clients may use locally self-signed certificates (default psql client
// behavior).
SSL_MODE_REQUIRE = 2;
// SSL connections are required. CA verification enforced.
// Clients must have certificates signed by a Cluster CA, e.g. via
// GenerateClientCertificate.
SSL_MODE_VERIFY_CA = 3;
}
// Certificate Authority (CA) source for SSL/TLS certificates.
enum CaSource {
// Certificate Authority (CA) source not specified. Defaults to
// CA_SOURCE_MANAGED.
CA_SOURCE_UNSPECIFIED = 0;
// Certificate Authority (CA) managed by the AlloyDB Cluster.
CA_SOURCE_MANAGED = 1;
}
// Optional. SSL mode. Specifies client-server SSL/TLS connection behavior.
SslMode ssl_mode = 1;
// Optional. Certificate Authority (CA) source. Only CA_SOURCE_MANAGED is
// supported currently, and is the default value.
CaSource ca_source = 2;
}
// Message describing the user-specified automated backup policy.
//
// All fields in the automated backup policy are optional. Defaults for each
// field are provided if they are not set.
message AutomatedBackupPolicy {
// A weekly schedule starts a backup at prescribed start times within a
// day, for the specified days of the week.
//
// The weekly schedule message is flexible and can be used to create many
// types of schedules. For example, to have a daily backup that starts at
// 22:00, configure the `start_times` field to have one element "22:00" and
// the `days_of_week` field to have all seven days of the week.
message WeeklySchedule {
// The times during the day to start a backup. The start times are assumed
// to be in UTC and to be an exact hour (e.g., 04:00:00).
//
// If no start times are provided, a single fixed start time is chosen
// arbitrarily.
repeated google.type.TimeOfDay start_times = 1;
// The days of the week to perform a backup.
//
// If this field is left empty, the default of every day of the week is
// used.
repeated google.type.DayOfWeek days_of_week = 2;
}
// A time based retention policy specifies that all backups within a certain
// time period should be retained.
message TimeBasedRetention {
// The retention period.
google.protobuf.Duration retention_period = 1;
}
// A quantity based policy specifies that a certain number of the most recent
// successful backups should be retained.
message QuantityBasedRetention {
// The number of backups to retain.
int32 count = 1;
}
// The schedule for this automated backup policy.
//
// A schedule specifies times at which to start a backup. If a backup
// window is also provided, the backup is guaranteed to be started and
// completed within the start time plus the backup window. If the backup is
// not completed within the backup window it is marked as failed.
//
// If not set, the schedule defaults to a weekly schedule with one backup
// per day and a start time chosen arbitrarily.
oneof schedule {
// Weekly schedule for the Backup.
WeeklySchedule weekly_schedule = 2;
}
// The retention policy for automated backups.
//
// The retention policy for a backup is fixed at the time the backup is
// created. Changes to this field only apply to new backups taken with the
// policy; the retentions of existing backups remain unchanged.
//
// If no retention policy is set, a default of 14 days is used.
oneof retention {
// Time-based Backup retention policy.
TimeBasedRetention time_based_retention = 4;
// Quantity-based Backup retention policy to retain recent backups.
QuantityBasedRetention quantity_based_retention = 5;
}
// Whether automated automated backups are enabled. If not set, defaults to
// true.
optional bool enabled = 1;
// The length of the time window during which a backup can be
// taken. If a backup does not succeed within this time window, it will be
// canceled and considered failed.
//
// The backup window must be at least 5 minutes long. There is no upper bound
// on the window. If not set, it defaults to 1 hour.
google.protobuf.Duration backup_window = 3;
// Optional. The encryption config can be specified to encrypt the
// backups with a customer-managed encryption key (CMEK). When this field is
// not specified, the backup will then use default encryption scheme to
// protect the user data.
EncryptionConfig encryption_config = 8;
// The location where the backup will be stored. Currently, the only supported
// option is to store the backup in the same region as the cluster.
//
// If empty, defaults to the region of the cluster.
string location = 6;
// Labels to apply to backups created using this configuration.
map<string, string> labels = 7;
}
// Message describing a BackupSource.
message BackupSource {
// Output only. The system-generated UID of the backup which was used to
// create this resource. The UID is generated when the backup is created, and
// it is retained until the backup is deleted.
string backup_uid = 2;
// Required. The name of the backup resource with the format:
// * projects/{project}/locations/{region}/backups/{backup_id}
string backup_name = 1;
}
// A cluster is a collection of regional AlloyDB resources. It can include a
// primary instance and one or more read pool instances.
// All cluster resources share a storage layer, which scales as needed.
message Cluster {
// Configuration information for the secondary cluster. This should be set
// if and only if the cluster is of type SECONDARY.
message SecondaryConfig {
// The name of the primary cluster name with the format:
// * projects/{project}/locations/{region}/clusters/{cluster_id}
string primary_cluster_name = 1;
}
// Configuration for the primary cluster. It has the list of clusters that are
// replicating from this cluster. This should be set if and only if the
// cluster is of type PRIMARY.
message PrimaryConfig {
// Output only. Names of the clusters that are replicating from this
// cluster.
repeated string secondary_cluster_names = 1;
}
// Cluster State
enum State {
// The state of the cluster is unknown.
STATE_UNSPECIFIED = 0;
// The cluster is active and running.
READY = 1;
// The cluster is stopped. All instances in the cluster are stopped.
// Customers can start a stopped cluster at any point and all their
// instances will come back to life with same names and IP resources. In
// this state, customer pays for storage.
// Associated backups could also be present in a stopped cluster.
STOPPED = 2;
// The cluster is empty and has no associated resources.
// All instances, associated storage and backups have been deleted.
EMPTY = 3;
// The cluster is being created.
CREATING = 4;
// The cluster is being deleted.
DELETING = 5;
// The creation of the cluster failed.
FAILED = 6;
// The cluster is bootstrapping with data from some other source.
// Direct mutations to the cluster (e.g. adding read pool) are not allowed.
BOOTSTRAPPING = 7;
// The cluster is under maintenance. AlloyDB regularly performs maintenance
// and upgrades on customer clusters. Updates on the cluster are
// not allowed while the cluster is in this state.
MAINTENANCE = 8;
// The cluster is being promoted.
PROMOTING = 9;
}
// Type of Cluster
enum ClusterType {
// The type of the cluster is unknown.
CLUSTER_TYPE_UNSPECIFIED = 0;
// Primary cluster that support read and write operations.
PRIMARY = 1;
// Secondary cluster that is replicating from another region.
// This only supports read.
SECONDARY = 2;
}
// In case of an imported cluster, this field contains information about the
// source this cluster was imported from.
oneof source {
// Output only. Cluster created from backup.
BackupSource backup_source = 15;
// Output only. Cluster created via DMS migration.
MigrationSource migration_source = 16;
}
// Output only. The name of the cluster resource with the format:
// * projects/{project}/locations/{region}/clusters/{cluster_id}
// where the cluster ID segment should satisfy the regex expression
// `[a-z0-9-]+`. For more details see https://google.aip.dev/122.
// The prefix of the cluster resource name is the name of the parent resource:
// * projects/{project}/locations/{region}
string name = 1;
// User-settable and human-readable display name for the Cluster.
string display_name = 2;
// Output only. The system-generated UID of the resource. The UID is assigned
// when the resource is created, and it is retained until it is deleted.
string uid = 3;
// Output only. Create time stamp
google.protobuf.Timestamp create_time = 4;
// Output only. Update time stamp
google.protobuf.Timestamp update_time = 5;
// Output only. Delete time stamp
google.protobuf.Timestamp delete_time = 6;
// Labels as key value pairs
map<string, string> labels = 7;
// Output only. The current serving state of the cluster.
State state = 8;
// Output only. The type of the cluster. This is an output-only field and it's
// populated at the Cluster creation time or the Cluster promotion
// time. The cluster type is determined by which RPC was used to create
// the cluster (i.e. `CreateCluster` vs. `CreateSecondaryCluster`
ClusterType cluster_type = 24;
// Output only. The database engine major version. This is an output-only
// field and it's populated at the Cluster creation time. This field cannot be
// changed after cluster creation.
DatabaseVersion database_version = 9;
// Required. The resource link for the VPC network in which cluster resources
// are created and from which they are accessible via Private IP. The network
// must belong to the same project as the cluster. It is specified in the
// form: "projects/{project_number}/global/networks/{network_id}". This is
// required to create a cluster. It can be updated, but it cannot be removed.
string network = 10;
// For Resource freshness validation (https://google.aip.dev/154)
string etag = 11;
// Annotations to allow client tools to store small amount of arbitrary data.
// This is distinct from labels.
// https://google.aip.dev/128
map<string, string> annotations = 12;
// Output only. Reconciling (https://google.aip.dev/128#reconciliation).
// Set to true if the current state of Cluster does not match the user's
// intended state, and the service is actively updating the resource to
// reconcile them. This can happen due to user-triggered updates or
// system actions like failover or maintenance.
bool reconciling = 13;
// The automated backup policy for this cluster.
//
// If no policy is provided then the default policy will be used. If backups
// are supported for the cluster, the default policy takes one backup a day,
// has a backup window of 1 hour, and retains backups for 14 days.
// For more information on the defaults, consult the
// documentation for the message type.
AutomatedBackupPolicy automated_backup_policy = 17;
// SSL configuration for this AlloyDB Cluster.
SslConfig ssl_config = 18;
// Optional. The encryption config can be specified to encrypt the data disks
// and other persistent data resources of a cluster with a
// customer-managed encryption key (CMEK). When this field is not
// specified, the cluster will then use default encryption scheme to
// protect the user data.
EncryptionConfig encryption_config = 19;
// Output only. The encryption information for the cluster.
EncryptionInfo encryption_info = 20;
// Cross Region replication config specific to SECONDARY cluster.
SecondaryConfig secondary_config = 22;
// Output only. Cross Region replication config specific to PRIMARY cluster.
PrimaryConfig primary_config = 23;
}
// An Instance is a computing unit that an end customer can connect to.
// It's the main unit of computing resources in AlloyDB.
message Instance {
// MachineConfig describes the configuration of a machine.
message MachineConfig {
// The number of CPU's in the VM instance.
int32 cpu_count = 1;
}
// Details of a single node in the instance.
// Nodes in an AlloyDB instance are ephemereal, they can change during
// update, failover, autohealing and resize operations.
message Node {
// The Compute Engine zone of the VM e.g. "us-central1-b".
string zone_id = 1;
// The identifier of the VM e.g. "test-read-0601-407e52be-ms3l".
string id = 2;
// The private IP address of the VM e.g. "10.57.0.34".
string ip = 3;
// Determined by state of the compute VM and postgres-service health.
// Compute VM state can have values listed in
// https://cloud.google.com/compute/docs/instances/instance-life-cycle and
// postgres-service health can have values: HEALTHY and UNHEALTHY.
string state = 4;
}
// QueryInsights Instance specific configuration.
message QueryInsightsInstanceConfig {
// Record application tags for an instance.
// This flag is turned "on" by default.
optional bool record_application_tags = 2;
// Record client address for an instance. Client address is PII information.
// This flag is turned "on" by default.
optional bool record_client_address = 3;
// Query string length. The default value is 1024.
// Any integer between 256 and 4500 is considered valid.
uint32 query_string_length = 4;
// Number of query execution plans captured by Insights per minute
// for all queries combined. The default value is 5.
// Any integer between 0 and 20 is considered valid.
optional uint32 query_plans_per_minute = 5;
}
// Configuration for a read pool instance.
message ReadPoolConfig {
// Read capacity, i.e. number of nodes in a read pool instance.
int32 node_count = 1;
}
// Instance State
enum State {
// The state of the instance is unknown.
STATE_UNSPECIFIED = 0;
// The instance is active and running.
READY = 1;
// The instance is stopped. Instance name and IP resources are preserved.
STOPPED = 2;
// The instance is being created.
CREATING = 3;
// The instance is being deleted.
DELETING = 4;
// The instance is down for maintenance.
MAINTENANCE = 5;
// The creation of the instance failed or a fatal error occurred during
// an operation on the instance.
// Note: Instances in this state would tried to be auto-repaired. And
// Customers should be able to restart, update or delete these instances.
FAILED = 6;
// Index 7 is used in the producer apis for ROLLED_BACK state. Keeping that
// index unused in case that state also needs to exposed via consumer apis
// in future.
// The instance has been configured to sync data from some other source.
BOOTSTRAPPING = 8;
// The instance is being promoted.
PROMOTING = 9;
}
// Type of an Instance
enum InstanceType {
// The type of the instance is unknown.
INSTANCE_TYPE_UNSPECIFIED = 0;
// PRIMARY instances support read and write operations.
PRIMARY = 1;
// READ POOL instances support read operations only. Each read pool instance
// consists of one or more homogeneous nodes.
// * Read pool of size 1 can only have zonal availability.
// * Read pools with node count of 2 or more can have regional
// availability (nodes are present in 2 or more zones in a region).
READ_POOL = 2;
// SECONDARY instances support read operations only. SECONDARY instance
// is a cross-region read replica
SECONDARY = 3;
}
// The Availability type of an instance. Potential values:
// - ZONAL: The instance serves data from only one zone. Outages in that
// zone affect instance availability.
// - REGIONAL: The instance can serve data from more than one zone in a
// region (it is highly available).
enum AvailabilityType {
// This is an unknown Availability type.
AVAILABILITY_TYPE_UNSPECIFIED = 0;
// Zonal available instance.
ZONAL = 1;
// Regional (or Highly) available instance.
REGIONAL = 2;
}
// Output only. The name of the instance resource with the format:
// * projects/{project}/locations/{region}/clusters/{cluster_id}/instances/{instance_id}
// where the cluster and instance ID segments should satisfy the regex
// expression `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`, e.g. 1-63 characters of
// lowercase letters, numbers, and dashes, starting with a letter, and ending
// with a letter or number. For more details see https://google.aip.dev/122.
// The prefix of the instance resource name is the name of the parent
// resource:
// * projects/{project}/locations/{region}/clusters/{cluster_id}
string name = 1;
// User-settable and human-readable display name for the Instance.
string display_name = 2;
// Output only. The system-generated UID of the resource. The UID is assigned
// when the resource is created, and it is retained until it is deleted.
string uid = 3;
// Output only. Create time stamp
google.protobuf.Timestamp create_time = 4;
// Output only. Update time stamp
google.protobuf.Timestamp update_time = 5;
// Output only. Delete time stamp
google.protobuf.Timestamp delete_time = 6;
// Labels as key value pairs
map<string, string> labels = 7;
// Output only. The current serving state of the instance.
State state = 8;
// Required. The type of the instance. Specified at creation time.
InstanceType instance_type = 9;
// Configurations for the machines that host the underlying
// database engine.
MachineConfig machine_config = 10;
// Availability type of an Instance.
// If empty, defaults to REGIONAL for primary instances.
// For read pools, availability_type is always UNSPECIFIED. Instances in the
// read pools are evenly distributed across available zones within the region
// (i.e. read pools with more than one node will have a node in at
// least two zones).
AvailabilityType availability_type = 11;
// The Compute Engine zone that the instance should serve from, per
// https://cloud.google.com/compute/docs/regions-zones
// This can ONLY be specified for ZONAL instances.
// If present for a REGIONAL instance, an error will be thrown.
// If this is absent for a ZONAL instance, instance is created in a random
// zone with available capacity.
string gce_zone = 12;
// Database flags. Set at instance level.
// * They are copied from primary instance on read instance creation.
// * Read instances can set new or override existing flags that are relevant
// for reads, e.g. for enabling columnar cache on a read instance. Flags
// set on read instance may or may not be present on primary.
//
//
// This is a list of "key": "value" pairs.
// "key": The name of the flag. These flags are passed at instance setup time,
// so include both server options and system variables for Postgres. Flags are
// specified with underscores, not hyphens.
// "value": The value of the flag. Booleans are set to **on** for true
// and **off** for false. This field must be omitted if the flag
// doesn't take a value.
map<string, string> database_flags = 13;
// Output only. This is set for the read-write VM of the PRIMARY instance
// only.
Node writable_node = 19;
// Output only. List of available read-only VMs in this instance, including
// the standby for a PRIMARY instance.
repeated Node nodes = 20;
// Configuration for query insights.
QueryInsightsInstanceConfig query_insights_config = 21;
// Read pool specific config.
ReadPoolConfig read_pool_config = 14;
// Output only. The IP address for the Instance.
// This is the connection endpoint for an end-user application.
string ip_address = 15;
// Output only. Reconciling (https://google.aip.dev/128#reconciliation).
// Set to true if the current state of Instance does not match the user's
// intended state, and the service is actively updating the resource to
// reconcile them. This can happen due to user-triggered updates or
// system actions like failover or maintenance.
bool reconciling = 16;
// For Resource freshness validation (https://google.aip.dev/154)
string etag = 17;
// Annotations to allow client tools to store small amount of arbitrary data.
// This is distinct from labels.
// https://google.aip.dev/128
map<string, string> annotations = 18;
}
// Message describing Backup object
message Backup {
// Backup State
enum State {
// The state of the backup is unknown.
STATE_UNSPECIFIED = 0;
// The backup is ready.
READY = 1;
// The backup is creating.
CREATING = 2;
// The backup failed.
FAILED = 3;
// The backup is being deleted.
DELETING = 4;
}
// Backup Type
enum Type {
// Backup Type is unknown.
TYPE_UNSPECIFIED = 0;
// ON_DEMAND backups that were triggered by the customer (e.g., not
// AUTOMATED).
ON_DEMAND = 1;
// AUTOMATED backups triggered by the automated backups scheduler pursuant
// to an automated backup policy.
AUTOMATED = 2;
// CONTINUOUS backups triggered by the automated backups scheduler
// due to a continuous backup policy.
CONTINUOUS = 3;
}
// Output only. The name of the backup resource with the format:
// * projects/{project}/locations/{region}/backups/{backup_id}
// where the cluster and backup ID segments should satisfy the regex
// expression `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`, e.g. 1-63 characters of
// lowercase letters, numbers, and dashes, starting with a letter, and ending
// with a letter or number. For more details see https://google.aip.dev/122.
// The prefix of the backup resource name is the name of the parent
// resource:
// * projects/{project}/locations/{region}
string name = 1;
// User-settable and human-readable display name for the Backup.
string display_name = 2;
// Output only. The system-generated UID of the resource. The UID is assigned
// when the resource is created, and it is retained until it is deleted.
string uid = 3;
// Output only. Create time stamp
google.protobuf.Timestamp create_time = 4;
// Output only. Update time stamp
google.protobuf.Timestamp update_time = 5;
// Output only. Delete time stamp
google.protobuf.Timestamp delete_time = 15;
// Labels as key value pairs
map<string, string> labels = 6;
// Output only. The current state of the backup.
State state = 7;
// The backup type, which suggests the trigger for the backup.
Type type = 8;
// User-provided description of the backup.
string description = 9;
// Output only. The system-generated UID of the cluster which was used to
// create this resource.
string cluster_uid = 18;
// Required. The full resource name of the backup source cluster
// (e.g., projects/{project}/locations/{region}/clusters/{cluster_id}).
string cluster_name = 10;
// Output only. Reconciling (https://google.aip.dev/128#reconciliation), if
// true, indicates that the service is actively updating the resource. This
// can happen due to user-triggered updates or system actions like failover or
// maintenance.
bool reconciling = 11;
// Optional. The encryption config can be specified to encrypt the
// backup with a customer-managed encryption key (CMEK). When this field is
// not specified, the backup will then use default encryption scheme to
// protect the user data.
EncryptionConfig encryption_config = 12;
// Output only. The encryption information for the backup.
EncryptionInfo encryption_info = 13;
// For Resource freshness validation (https://google.aip.dev/154)
string etag = 14;
// Annotations to allow client tools to store small amount of arbitrary data.
// This is distinct from labels.
// https://google.aip.dev/128
map<string, string> annotations = 16;
// Output only. The size of the backup in bytes.
int64 size_bytes = 17;
// Output only. The time at which after the backup is eligible to be garbage
// collected. It is the duration specified by the backup's retention policy,
// added to the backup's create_time.
google.protobuf.Timestamp expiry_time = 19;
}
// The supported database engine versions.
enum DatabaseVersion {
// This is an unknown database version.
DATABASE_VERSION_UNSPECIFIED = 0;
// DEPRECATED - The database version is Postgres 13.
POSTGRES_13 = 1;
// The database version is Postgres 14.
POSTGRES_14 = 2;
}
// The data within all Instance events.
message InstanceEventData {
// Optional. The Instance event payload. Unset for deletion events.
optional Instance payload = 1;
}
// The data within all Backup events.
message BackupEventData {
// Optional. The Backup event payload. Unset for deletion events.
optional Backup payload = 1;
}
// The data within all Cluster events.
message ClusterEventData {
// Optional. The Cluster event payload. Unset for deletion events.
optional Cluster payload = 1;
}