-
Notifications
You must be signed in to change notification settings - Fork 1.2k
/
backup.pb.go
executable file
·2233 lines (2034 loc) · 101 KB
/
backup.pb.go
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
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Copyright 2024 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
//
// http://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.
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.33.0
// protoc v4.25.3
// source: google/spanner/admin/database/v1/backup.proto
package databasepb
import (
reflect "reflect"
sync "sync"
longrunningpb "cloud.google.com/go/longrunning/autogen/longrunningpb"
_ "google.golang.org/genproto/googleapis/api/annotations"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
fieldmaskpb "google.golang.org/protobuf/types/known/fieldmaskpb"
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
// Indicates the current state of the backup.
type Backup_State int32
const (
// Not specified.
Backup_STATE_UNSPECIFIED Backup_State = 0
// The pending backup is still being created. Operations on the
// backup may fail with `FAILED_PRECONDITION` in this state.
Backup_CREATING Backup_State = 1
// The backup is complete and ready for use.
Backup_READY Backup_State = 2
)
// Enum value maps for Backup_State.
var (
Backup_State_name = map[int32]string{
0: "STATE_UNSPECIFIED",
1: "CREATING",
2: "READY",
}
Backup_State_value = map[string]int32{
"STATE_UNSPECIFIED": 0,
"CREATING": 1,
"READY": 2,
}
)
func (x Backup_State) Enum() *Backup_State {
p := new(Backup_State)
*p = x
return p
}
func (x Backup_State) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (Backup_State) Descriptor() protoreflect.EnumDescriptor {
return file_google_spanner_admin_database_v1_backup_proto_enumTypes[0].Descriptor()
}
func (Backup_State) Type() protoreflect.EnumType {
return &file_google_spanner_admin_database_v1_backup_proto_enumTypes[0]
}
func (x Backup_State) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use Backup_State.Descriptor instead.
func (Backup_State) EnumDescriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{0, 0}
}
// Encryption types for the backup.
type CreateBackupEncryptionConfig_EncryptionType int32
const (
// Unspecified. Do not use.
CreateBackupEncryptionConfig_ENCRYPTION_TYPE_UNSPECIFIED CreateBackupEncryptionConfig_EncryptionType = 0
// Use the same encryption configuration as the database. This is the
// default option when
// [encryption_config][google.spanner.admin.database.v1.CreateBackupEncryptionConfig]
// is empty. For example, if the database is using
// `Customer_Managed_Encryption`, the backup will be using the same Cloud
// KMS key as the database.
CreateBackupEncryptionConfig_USE_DATABASE_ENCRYPTION CreateBackupEncryptionConfig_EncryptionType = 1
// Use Google default encryption.
CreateBackupEncryptionConfig_GOOGLE_DEFAULT_ENCRYPTION CreateBackupEncryptionConfig_EncryptionType = 2
// Use customer managed encryption. If specified, `kms_key_name`
// must contain a valid Cloud KMS key.
CreateBackupEncryptionConfig_CUSTOMER_MANAGED_ENCRYPTION CreateBackupEncryptionConfig_EncryptionType = 3
)
// Enum value maps for CreateBackupEncryptionConfig_EncryptionType.
var (
CreateBackupEncryptionConfig_EncryptionType_name = map[int32]string{
0: "ENCRYPTION_TYPE_UNSPECIFIED",
1: "USE_DATABASE_ENCRYPTION",
2: "GOOGLE_DEFAULT_ENCRYPTION",
3: "CUSTOMER_MANAGED_ENCRYPTION",
}
CreateBackupEncryptionConfig_EncryptionType_value = map[string]int32{
"ENCRYPTION_TYPE_UNSPECIFIED": 0,
"USE_DATABASE_ENCRYPTION": 1,
"GOOGLE_DEFAULT_ENCRYPTION": 2,
"CUSTOMER_MANAGED_ENCRYPTION": 3,
}
)
func (x CreateBackupEncryptionConfig_EncryptionType) Enum() *CreateBackupEncryptionConfig_EncryptionType {
p := new(CreateBackupEncryptionConfig_EncryptionType)
*p = x
return p
}
func (x CreateBackupEncryptionConfig_EncryptionType) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (CreateBackupEncryptionConfig_EncryptionType) Descriptor() protoreflect.EnumDescriptor {
return file_google_spanner_admin_database_v1_backup_proto_enumTypes[1].Descriptor()
}
func (CreateBackupEncryptionConfig_EncryptionType) Type() protoreflect.EnumType {
return &file_google_spanner_admin_database_v1_backup_proto_enumTypes[1]
}
func (x CreateBackupEncryptionConfig_EncryptionType) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use CreateBackupEncryptionConfig_EncryptionType.Descriptor instead.
func (CreateBackupEncryptionConfig_EncryptionType) EnumDescriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{13, 0}
}
// Encryption types for the backup.
type CopyBackupEncryptionConfig_EncryptionType int32
const (
// Unspecified. Do not use.
CopyBackupEncryptionConfig_ENCRYPTION_TYPE_UNSPECIFIED CopyBackupEncryptionConfig_EncryptionType = 0
// This is the default option for
// [CopyBackup][google.spanner.admin.database.v1.DatabaseAdmin.CopyBackup]
// when
// [encryption_config][google.spanner.admin.database.v1.CopyBackupEncryptionConfig]
// is not specified. For example, if the source backup is using
// `Customer_Managed_Encryption`, the backup will be using the same Cloud
// KMS key as the source backup.
CopyBackupEncryptionConfig_USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION CopyBackupEncryptionConfig_EncryptionType = 1
// Use Google default encryption.
CopyBackupEncryptionConfig_GOOGLE_DEFAULT_ENCRYPTION CopyBackupEncryptionConfig_EncryptionType = 2
// Use customer managed encryption. If specified, either `kms_key_name` or
// `kms_key_names` must contain valid Cloud KMS key(s).
CopyBackupEncryptionConfig_CUSTOMER_MANAGED_ENCRYPTION CopyBackupEncryptionConfig_EncryptionType = 3
)
// Enum value maps for CopyBackupEncryptionConfig_EncryptionType.
var (
CopyBackupEncryptionConfig_EncryptionType_name = map[int32]string{
0: "ENCRYPTION_TYPE_UNSPECIFIED",
1: "USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION",
2: "GOOGLE_DEFAULT_ENCRYPTION",
3: "CUSTOMER_MANAGED_ENCRYPTION",
}
CopyBackupEncryptionConfig_EncryptionType_value = map[string]int32{
"ENCRYPTION_TYPE_UNSPECIFIED": 0,
"USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION": 1,
"GOOGLE_DEFAULT_ENCRYPTION": 2,
"CUSTOMER_MANAGED_ENCRYPTION": 3,
}
)
func (x CopyBackupEncryptionConfig_EncryptionType) Enum() *CopyBackupEncryptionConfig_EncryptionType {
p := new(CopyBackupEncryptionConfig_EncryptionType)
*p = x
return p
}
func (x CopyBackupEncryptionConfig_EncryptionType) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (CopyBackupEncryptionConfig_EncryptionType) Descriptor() protoreflect.EnumDescriptor {
return file_google_spanner_admin_database_v1_backup_proto_enumTypes[2].Descriptor()
}
func (CopyBackupEncryptionConfig_EncryptionType) Type() protoreflect.EnumType {
return &file_google_spanner_admin_database_v1_backup_proto_enumTypes[2]
}
func (x CopyBackupEncryptionConfig_EncryptionType) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use CopyBackupEncryptionConfig_EncryptionType.Descriptor instead.
func (CopyBackupEncryptionConfig_EncryptionType) EnumDescriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{14, 0}
}
// A backup of a Cloud Spanner database.
type Backup struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Required for the
// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]
// operation. Name of the database from which this backup was created. This
// needs to be in the same instance as the backup. Values are of the form
// `projects/<project>/instances/<instance>/databases/<database>`.
Database string `protobuf:"bytes,2,opt,name=database,proto3" json:"database,omitempty"`
// The backup will contain an externally consistent copy of the database at
// the timestamp specified by `version_time`. If `version_time` is not
// specified, the system will set `version_time` to the `create_time` of the
// backup.
VersionTime *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=version_time,json=versionTime,proto3" json:"version_time,omitempty"`
// Required for the
// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]
// operation. The expiration time of the backup, with microseconds
// granularity that must be at least 6 hours and at most 366 days
// from the time the CreateBackup request is processed. Once the `expire_time`
// has passed, the backup is eligible to be automatically deleted by Cloud
// Spanner to free the resources used by the backup.
ExpireTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=expire_time,json=expireTime,proto3" json:"expire_time,omitempty"`
// Output only for the
// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]
// operation. Required for the
// [UpdateBackup][google.spanner.admin.database.v1.DatabaseAdmin.UpdateBackup]
// operation.
//
// A globally unique identifier for the backup which cannot be
// changed. Values are of the form
// `projects/<project>/instances/<instance>/backups/[a-z][a-z0-9_\-]*[a-z0-9]`
// The final segment of the name must be between 2 and 60 characters
// in length.
//
// The backup is stored in the location(s) specified in the instance
// configuration of the instance containing the backup, identified
// by the prefix of the backup name of the form
// `projects/<project>/instances/<instance>`.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Output only. The time the
// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]
// request is received. If the request does not specify `version_time`, the
// `version_time` of the backup will be equivalent to the `create_time`.
CreateTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
// Output only. Size of the backup in bytes.
SizeBytes int64 `protobuf:"varint,5,opt,name=size_bytes,json=sizeBytes,proto3" json:"size_bytes,omitempty"`
// Output only. The current state of the backup.
State Backup_State `protobuf:"varint,6,opt,name=state,proto3,enum=google.spanner.admin.database.v1.Backup_State" json:"state,omitempty"`
// Output only. The names of the restored databases that reference the backup.
// The database names are of
// the form `projects/<project>/instances/<instance>/databases/<database>`.
// Referencing databases may exist in different instances. The existence of
// any referencing database prevents the backup from being deleted. When a
// restored database from the backup enters the `READY` state, the reference
// to the backup is removed.
ReferencingDatabases []string `protobuf:"bytes,7,rep,name=referencing_databases,json=referencingDatabases,proto3" json:"referencing_databases,omitempty"`
// Output only. The encryption information for the backup.
EncryptionInfo *EncryptionInfo `protobuf:"bytes,8,opt,name=encryption_info,json=encryptionInfo,proto3" json:"encryption_info,omitempty"`
// Output only. The encryption information for the backup, whether it is
// protected by one or more KMS keys. The information includes all Cloud
// KMS key versions used to encrypt the backup. The `encryption_status' field
// inside of each `EncryptionInfo` is not populated. At least one of the key
// versions must be available for the backup to be restored. If a key version
// is revoked in the middle of a restore, the restore behavior is undefined.
EncryptionInformation []*EncryptionInfo `protobuf:"bytes,13,rep,name=encryption_information,json=encryptionInformation,proto3" json:"encryption_information,omitempty"`
// Output only. The database dialect information for the backup.
DatabaseDialect DatabaseDialect `protobuf:"varint,10,opt,name=database_dialect,json=databaseDialect,proto3,enum=google.spanner.admin.database.v1.DatabaseDialect" json:"database_dialect,omitempty"`
// Output only. The names of the destination backups being created by copying
// this source backup. The backup names are of the form
// `projects/<project>/instances/<instance>/backups/<backup>`.
// Referencing backups may exist in different instances. The existence of
// any referencing backup prevents the backup from being deleted. When the
// copy operation is done (either successfully completed or cancelled or the
// destination backup is deleted), the reference to the backup is removed.
ReferencingBackups []string `protobuf:"bytes,11,rep,name=referencing_backups,json=referencingBackups,proto3" json:"referencing_backups,omitempty"`
// Output only. The max allowed expiration time of the backup, with
// microseconds granularity. A backup's expiration time can be configured in
// multiple APIs: CreateBackup, UpdateBackup, CopyBackup. When updating or
// copying an existing backup, the expiration time specified must be
// less than `Backup.max_expire_time`.
MaxExpireTime *timestamppb.Timestamp `protobuf:"bytes,12,opt,name=max_expire_time,json=maxExpireTime,proto3" json:"max_expire_time,omitempty"`
}
func (x *Backup) Reset() {
*x = Backup{}
if protoimpl.UnsafeEnabled {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *Backup) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Backup) ProtoMessage() {}
func (x *Backup) ProtoReflect() protoreflect.Message {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use Backup.ProtoReflect.Descriptor instead.
func (*Backup) Descriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{0}
}
func (x *Backup) GetDatabase() string {
if x != nil {
return x.Database
}
return ""
}
func (x *Backup) GetVersionTime() *timestamppb.Timestamp {
if x != nil {
return x.VersionTime
}
return nil
}
func (x *Backup) GetExpireTime() *timestamppb.Timestamp {
if x != nil {
return x.ExpireTime
}
return nil
}
func (x *Backup) GetName() string {
if x != nil {
return x.Name
}
return ""
}
func (x *Backup) GetCreateTime() *timestamppb.Timestamp {
if x != nil {
return x.CreateTime
}
return nil
}
func (x *Backup) GetSizeBytes() int64 {
if x != nil {
return x.SizeBytes
}
return 0
}
func (x *Backup) GetState() Backup_State {
if x != nil {
return x.State
}
return Backup_STATE_UNSPECIFIED
}
func (x *Backup) GetReferencingDatabases() []string {
if x != nil {
return x.ReferencingDatabases
}
return nil
}
func (x *Backup) GetEncryptionInfo() *EncryptionInfo {
if x != nil {
return x.EncryptionInfo
}
return nil
}
func (x *Backup) GetEncryptionInformation() []*EncryptionInfo {
if x != nil {
return x.EncryptionInformation
}
return nil
}
func (x *Backup) GetDatabaseDialect() DatabaseDialect {
if x != nil {
return x.DatabaseDialect
}
return DatabaseDialect_DATABASE_DIALECT_UNSPECIFIED
}
func (x *Backup) GetReferencingBackups() []string {
if x != nil {
return x.ReferencingBackups
}
return nil
}
func (x *Backup) GetMaxExpireTime() *timestamppb.Timestamp {
if x != nil {
return x.MaxExpireTime
}
return nil
}
// The request for
// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup].
type CreateBackupRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Required. The name of the instance in which the backup will be
// created. This must be the same instance that contains the database the
// backup will be created from. The backup will be stored in the
// location(s) specified in the instance configuration of this
// instance. Values are of the form
// `projects/<project>/instances/<instance>`.
Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
// Required. The id of the backup to be created. The `backup_id` appended to
// `parent` forms the full backup name of the form
// `projects/<project>/instances/<instance>/backups/<backup_id>`.
BackupId string `protobuf:"bytes,2,opt,name=backup_id,json=backupId,proto3" json:"backup_id,omitempty"`
// Required. The backup to create.
Backup *Backup `protobuf:"bytes,3,opt,name=backup,proto3" json:"backup,omitempty"`
// Optional. The encryption configuration used to encrypt the backup. If this
// field is not specified, the backup will use the same encryption
// configuration as the database by default, namely
// [encryption_type][google.spanner.admin.database.v1.CreateBackupEncryptionConfig.encryption_type]
// = `USE_DATABASE_ENCRYPTION`.
EncryptionConfig *CreateBackupEncryptionConfig `protobuf:"bytes,4,opt,name=encryption_config,json=encryptionConfig,proto3" json:"encryption_config,omitempty"`
}
func (x *CreateBackupRequest) Reset() {
*x = CreateBackupRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *CreateBackupRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CreateBackupRequest) ProtoMessage() {}
func (x *CreateBackupRequest) ProtoReflect() protoreflect.Message {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CreateBackupRequest.ProtoReflect.Descriptor instead.
func (*CreateBackupRequest) Descriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{1}
}
func (x *CreateBackupRequest) GetParent() string {
if x != nil {
return x.Parent
}
return ""
}
func (x *CreateBackupRequest) GetBackupId() string {
if x != nil {
return x.BackupId
}
return ""
}
func (x *CreateBackupRequest) GetBackup() *Backup {
if x != nil {
return x.Backup
}
return nil
}
func (x *CreateBackupRequest) GetEncryptionConfig() *CreateBackupEncryptionConfig {
if x != nil {
return x.EncryptionConfig
}
return nil
}
// Metadata type for the operation returned by
// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup].
type CreateBackupMetadata struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// The name of the backup being created.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// The name of the database the backup is created from.
Database string `protobuf:"bytes,2,opt,name=database,proto3" json:"database,omitempty"`
// The progress of the
// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]
// operation.
Progress *OperationProgress `protobuf:"bytes,3,opt,name=progress,proto3" json:"progress,omitempty"`
// The time at which cancellation of this operation was received.
// [Operations.CancelOperation][google.longrunning.Operations.CancelOperation]
// starts asynchronous cancellation on a long-running operation. The server
// makes a best effort to cancel the operation, but success is not guaranteed.
// Clients can use
// [Operations.GetOperation][google.longrunning.Operations.GetOperation] or
// other methods to check whether the cancellation succeeded or whether the
// operation completed despite cancellation. On successful cancellation,
// the operation is not deleted; instead, it becomes an operation with
// an [Operation.error][google.longrunning.Operation.error] value with a
// [google.rpc.Status.code][google.rpc.Status.code] of 1,
// corresponding to `Code.CANCELLED`.
CancelTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=cancel_time,json=cancelTime,proto3" json:"cancel_time,omitempty"`
}
func (x *CreateBackupMetadata) Reset() {
*x = CreateBackupMetadata{}
if protoimpl.UnsafeEnabled {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *CreateBackupMetadata) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CreateBackupMetadata) ProtoMessage() {}
func (x *CreateBackupMetadata) ProtoReflect() protoreflect.Message {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CreateBackupMetadata.ProtoReflect.Descriptor instead.
func (*CreateBackupMetadata) Descriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{2}
}
func (x *CreateBackupMetadata) GetName() string {
if x != nil {
return x.Name
}
return ""
}
func (x *CreateBackupMetadata) GetDatabase() string {
if x != nil {
return x.Database
}
return ""
}
func (x *CreateBackupMetadata) GetProgress() *OperationProgress {
if x != nil {
return x.Progress
}
return nil
}
func (x *CreateBackupMetadata) GetCancelTime() *timestamppb.Timestamp {
if x != nil {
return x.CancelTime
}
return nil
}
// The request for
// [CopyBackup][google.spanner.admin.database.v1.DatabaseAdmin.CopyBackup].
type CopyBackupRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Required. The name of the destination instance that will contain the backup
// copy. Values are of the form: `projects/<project>/instances/<instance>`.
Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
// Required. The id of the backup copy.
// The `backup_id` appended to `parent` forms the full backup_uri of the form
// `projects/<project>/instances/<instance>/backups/<backup>`.
BackupId string `protobuf:"bytes,2,opt,name=backup_id,json=backupId,proto3" json:"backup_id,omitempty"`
// Required. The source backup to be copied.
// The source backup needs to be in READY state for it to be copied.
// Once CopyBackup is in progress, the source backup cannot be deleted or
// cleaned up on expiration until CopyBackup is finished.
// Values are of the form:
// `projects/<project>/instances/<instance>/backups/<backup>`.
SourceBackup string `protobuf:"bytes,3,opt,name=source_backup,json=sourceBackup,proto3" json:"source_backup,omitempty"`
// Required. The expiration time of the backup in microsecond granularity.
// The expiration time must be at least 6 hours and at most 366 days
// from the `create_time` of the source backup. Once the `expire_time` has
// passed, the backup is eligible to be automatically deleted by Cloud Spanner
// to free the resources used by the backup.
ExpireTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=expire_time,json=expireTime,proto3" json:"expire_time,omitempty"`
// Optional. The encryption configuration used to encrypt the backup. If this
// field is not specified, the backup will use the same encryption
// configuration as the source backup by default, namely
// [encryption_type][google.spanner.admin.database.v1.CopyBackupEncryptionConfig.encryption_type]
// = `USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION`.
EncryptionConfig *CopyBackupEncryptionConfig `protobuf:"bytes,5,opt,name=encryption_config,json=encryptionConfig,proto3" json:"encryption_config,omitempty"`
}
func (x *CopyBackupRequest) Reset() {
*x = CopyBackupRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *CopyBackupRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CopyBackupRequest) ProtoMessage() {}
func (x *CopyBackupRequest) ProtoReflect() protoreflect.Message {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CopyBackupRequest.ProtoReflect.Descriptor instead.
func (*CopyBackupRequest) Descriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{3}
}
func (x *CopyBackupRequest) GetParent() string {
if x != nil {
return x.Parent
}
return ""
}
func (x *CopyBackupRequest) GetBackupId() string {
if x != nil {
return x.BackupId
}
return ""
}
func (x *CopyBackupRequest) GetSourceBackup() string {
if x != nil {
return x.SourceBackup
}
return ""
}
func (x *CopyBackupRequest) GetExpireTime() *timestamppb.Timestamp {
if x != nil {
return x.ExpireTime
}
return nil
}
func (x *CopyBackupRequest) GetEncryptionConfig() *CopyBackupEncryptionConfig {
if x != nil {
return x.EncryptionConfig
}
return nil
}
// Metadata type for the operation returned by
// [CopyBackup][google.spanner.admin.database.v1.DatabaseAdmin.CopyBackup].
type CopyBackupMetadata struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// The name of the backup being created through the copy operation.
// Values are of the form
// `projects/<project>/instances/<instance>/backups/<backup>`.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// The name of the source backup that is being copied.
// Values are of the form
// `projects/<project>/instances/<instance>/backups/<backup>`.
SourceBackup string `protobuf:"bytes,2,opt,name=source_backup,json=sourceBackup,proto3" json:"source_backup,omitempty"`
// The progress of the
// [CopyBackup][google.spanner.admin.database.v1.DatabaseAdmin.CopyBackup]
// operation.
Progress *OperationProgress `protobuf:"bytes,3,opt,name=progress,proto3" json:"progress,omitempty"`
// The time at which cancellation of CopyBackup operation was received.
// [Operations.CancelOperation][google.longrunning.Operations.CancelOperation]
// starts asynchronous cancellation on a long-running operation. The server
// makes a best effort to cancel the operation, but success is not guaranteed.
// Clients can use
// [Operations.GetOperation][google.longrunning.Operations.GetOperation] or
// other methods to check whether the cancellation succeeded or whether the
// operation completed despite cancellation. On successful cancellation,
// the operation is not deleted; instead, it becomes an operation with
// an [Operation.error][google.longrunning.Operation.error] value with a
// [google.rpc.Status.code][google.rpc.Status.code] of 1,
// corresponding to `Code.CANCELLED`.
CancelTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=cancel_time,json=cancelTime,proto3" json:"cancel_time,omitempty"`
}
func (x *CopyBackupMetadata) Reset() {
*x = CopyBackupMetadata{}
if protoimpl.UnsafeEnabled {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *CopyBackupMetadata) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*CopyBackupMetadata) ProtoMessage() {}
func (x *CopyBackupMetadata) ProtoReflect() protoreflect.Message {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use CopyBackupMetadata.ProtoReflect.Descriptor instead.
func (*CopyBackupMetadata) Descriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{4}
}
func (x *CopyBackupMetadata) GetName() string {
if x != nil {
return x.Name
}
return ""
}
func (x *CopyBackupMetadata) GetSourceBackup() string {
if x != nil {
return x.SourceBackup
}
return ""
}
func (x *CopyBackupMetadata) GetProgress() *OperationProgress {
if x != nil {
return x.Progress
}
return nil
}
func (x *CopyBackupMetadata) GetCancelTime() *timestamppb.Timestamp {
if x != nil {
return x.CancelTime
}
return nil
}
// The request for
// [UpdateBackup][google.spanner.admin.database.v1.DatabaseAdmin.UpdateBackup].
type UpdateBackupRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Required. The backup to update. `backup.name`, and the fields to be updated
// as specified by `update_mask` are required. Other fields are ignored.
// Update is only supported for the following fields:
// - `backup.expire_time`.
Backup *Backup `protobuf:"bytes,1,opt,name=backup,proto3" json:"backup,omitempty"`
// Required. A mask specifying which fields (e.g. `expire_time`) in the
// Backup resource should be updated. This mask is relative to the Backup
// resource, not to the request message. The field mask must always be
// specified; this prevents any future fields from being erased accidentally
// by clients that do not know about them.
UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,2,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`
}
func (x *UpdateBackupRequest) Reset() {
*x = UpdateBackupRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UpdateBackupRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UpdateBackupRequest) ProtoMessage() {}
func (x *UpdateBackupRequest) ProtoReflect() protoreflect.Message {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UpdateBackupRequest.ProtoReflect.Descriptor instead.
func (*UpdateBackupRequest) Descriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{5}
}
func (x *UpdateBackupRequest) GetBackup() *Backup {
if x != nil {
return x.Backup
}
return nil
}
func (x *UpdateBackupRequest) GetUpdateMask() *fieldmaskpb.FieldMask {
if x != nil {
return x.UpdateMask
}
return nil
}
// The request for
// [GetBackup][google.spanner.admin.database.v1.DatabaseAdmin.GetBackup].
type GetBackupRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Required. Name of the backup.
// Values are of the form
// `projects/<project>/instances/<instance>/backups/<backup>`.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
}
func (x *GetBackupRequest) Reset() {
*x = GetBackupRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetBackupRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetBackupRequest) ProtoMessage() {}
func (x *GetBackupRequest) ProtoReflect() protoreflect.Message {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[6]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetBackupRequest.ProtoReflect.Descriptor instead.
func (*GetBackupRequest) Descriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{6}
}
func (x *GetBackupRequest) GetName() string {
if x != nil {
return x.Name
}
return ""
}
// The request for
// [DeleteBackup][google.spanner.admin.database.v1.DatabaseAdmin.DeleteBackup].
type DeleteBackupRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Required. Name of the backup to delete.
// Values are of the form
// `projects/<project>/instances/<instance>/backups/<backup>`.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
}
func (x *DeleteBackupRequest) Reset() {
*x = DeleteBackupRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *DeleteBackupRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*DeleteBackupRequest) ProtoMessage() {}
func (x *DeleteBackupRequest) ProtoReflect() protoreflect.Message {
mi := &file_google_spanner_admin_database_v1_backup_proto_msgTypes[7]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use DeleteBackupRequest.ProtoReflect.Descriptor instead.
func (*DeleteBackupRequest) Descriptor() ([]byte, []int) {
return file_google_spanner_admin_database_v1_backup_proto_rawDescGZIP(), []int{7}
}
func (x *DeleteBackupRequest) GetName() string {
if x != nil {
return x.Name
}
return ""
}
// The request for
// [ListBackups][google.spanner.admin.database.v1.DatabaseAdmin.ListBackups].
type ListBackupsRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Required. The instance to list backups from. Values are of the
// form `projects/<project>/instances/<instance>`.
Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
// An expression that filters the list of returned backups.
//
// A filter expression consists of a field name, a comparison operator, and a
// value for filtering.
// The value must be a string, a number, or a boolean. The comparison operator
// must be one of: `<`, `>`, `<=`, `>=`, `!=`, `=`, or `:`.
// Colon `:` is the contains operator. Filter rules are not case sensitive.
//
// The following fields in the
// [Backup][google.spanner.admin.database.v1.Backup] are eligible for
// filtering:
//
// - `name`
// - `database`
// - `state`