1#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4pub struct AclEntry {
5 #[prost(string, tag = "1")]
7 pub value: ::prost::alloc::string::String,
8 #[prost(message, optional, tag = "2")]
12 pub expiration_time: ::core::option::Option<::prost_types::Timestamp>,
13 #[prost(string, tag = "3")]
15 pub name: ::prost::alloc::string::String,
16 #[prost(string, tag = "4")]
18 pub kind: ::prost::alloc::string::String,
19}
20#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
22pub struct ApiWarning {
23 #[prost(enumeration = "api_warning::SqlApiWarningCode", tag = "1")]
25 pub code: i32,
26 #[prost(string, tag = "2")]
28 pub message: ::prost::alloc::string::String,
29 #[prost(string, tag = "3")]
31 pub region: ::prost::alloc::string::String,
32}
33pub mod api_warning {
35 #[derive(
36 Clone,
37 Copy,
38 Debug,
39 PartialEq,
40 Eq,
41 Hash,
42 PartialOrd,
43 Ord,
44 ::prost::Enumeration
45 )]
46 #[repr(i32)]
47 pub enum SqlApiWarningCode {
48 Unspecified = 0,
50 RegionUnreachable = 1,
53 MaxResultsExceedsLimit = 2,
56 CompromisedCredentials = 3,
59 InternalStateFailure = 4,
62 }
63 impl SqlApiWarningCode {
64 pub fn as_str_name(&self) -> &'static str {
69 match self {
70 Self::Unspecified => "SQL_API_WARNING_CODE_UNSPECIFIED",
71 Self::RegionUnreachable => "REGION_UNREACHABLE",
72 Self::MaxResultsExceedsLimit => "MAX_RESULTS_EXCEEDS_LIMIT",
73 Self::CompromisedCredentials => "COMPROMISED_CREDENTIALS",
74 Self::InternalStateFailure => "INTERNAL_STATE_FAILURE",
75 }
76 }
77 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
79 match value {
80 "SQL_API_WARNING_CODE_UNSPECIFIED" => Some(Self::Unspecified),
81 "REGION_UNREACHABLE" => Some(Self::RegionUnreachable),
82 "MAX_RESULTS_EXCEEDS_LIMIT" => Some(Self::MaxResultsExceedsLimit),
83 "COMPROMISED_CREDENTIALS" => Some(Self::CompromisedCredentials),
84 "INTERNAL_STATE_FAILURE" => Some(Self::InternalStateFailure),
85 _ => None,
86 }
87 }
88 }
89}
90#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
93pub struct BackupRetentionSettings {
94 #[prost(enumeration = "backup_retention_settings::RetentionUnit", tag = "1")]
96 pub retention_unit: i32,
97 #[prost(message, optional, tag = "2")]
101 pub retained_backups: ::core::option::Option<i32>,
102}
103pub mod backup_retention_settings {
105 #[derive(
107 Clone,
108 Copy,
109 Debug,
110 PartialEq,
111 Eq,
112 Hash,
113 PartialOrd,
114 Ord,
115 ::prost::Enumeration
116 )]
117 #[repr(i32)]
118 pub enum RetentionUnit {
119 Unspecified = 0,
121 Count = 1,
123 }
124 impl RetentionUnit {
125 pub fn as_str_name(&self) -> &'static str {
130 match self {
131 Self::Unspecified => "RETENTION_UNIT_UNSPECIFIED",
132 Self::Count => "COUNT",
133 }
134 }
135 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
137 match value {
138 "RETENTION_UNIT_UNSPECIFIED" => Some(Self::Unspecified),
139 "COUNT" => Some(Self::Count),
140 _ => None,
141 }
142 }
143 }
144}
145#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
147pub struct BackupConfiguration {
148 #[prost(string, tag = "1")]
151 pub start_time: ::prost::alloc::string::String,
152 #[prost(message, optional, tag = "2")]
154 pub enabled: ::core::option::Option<bool>,
155 #[prost(string, tag = "3")]
157 pub kind: ::prost::alloc::string::String,
158 #[prost(message, optional, tag = "4")]
161 pub binary_log_enabled: ::core::option::Option<bool>,
162 #[prost(message, optional, tag = "5")]
164 pub replication_log_archiving_enabled: ::core::option::Option<bool>,
165 #[prost(string, tag = "6")]
167 pub location: ::prost::alloc::string::String,
168 #[prost(message, optional, tag = "7")]
170 pub point_in_time_recovery_enabled: ::core::option::Option<bool>,
171 #[prost(message, optional, tag = "9")]
174 pub transaction_log_retention_days: ::core::option::Option<i32>,
175 #[prost(message, optional, tag = "10")]
177 pub backup_retention_settings: ::core::option::Option<BackupRetentionSettings>,
178 #[prost(
181 enumeration = "backup_configuration::TransactionalLogStorageState",
182 optional,
183 tag = "11"
184 )]
185 pub transactional_log_storage_state: ::core::option::Option<i32>,
186 #[prost(enumeration = "backup_configuration::BackupTier", optional, tag = "12")]
188 pub backup_tier: ::core::option::Option<i32>,
189}
190pub mod backup_configuration {
192 #[derive(
195 Clone,
196 Copy,
197 Debug,
198 PartialEq,
199 Eq,
200 Hash,
201 PartialOrd,
202 Ord,
203 ::prost::Enumeration
204 )]
205 #[repr(i32)]
206 pub enum TransactionalLogStorageState {
207 Unspecified = 0,
209 Disk = 1,
212 SwitchingToCloudStorage = 2,
216 SwitchedToCloudStorage = 3,
220 CloudStorage = 4,
223 }
224 impl TransactionalLogStorageState {
225 pub fn as_str_name(&self) -> &'static str {
230 match self {
231 Self::Unspecified => "TRANSACTIONAL_LOG_STORAGE_STATE_UNSPECIFIED",
232 Self::Disk => "DISK",
233 Self::SwitchingToCloudStorage => "SWITCHING_TO_CLOUD_STORAGE",
234 Self::SwitchedToCloudStorage => "SWITCHED_TO_CLOUD_STORAGE",
235 Self::CloudStorage => "CLOUD_STORAGE",
236 }
237 }
238 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
240 match value {
241 "TRANSACTIONAL_LOG_STORAGE_STATE_UNSPECIFIED" => Some(Self::Unspecified),
242 "DISK" => Some(Self::Disk),
243 "SWITCHING_TO_CLOUD_STORAGE" => Some(Self::SwitchingToCloudStorage),
244 "SWITCHED_TO_CLOUD_STORAGE" => Some(Self::SwitchedToCloudStorage),
245 "CLOUD_STORAGE" => Some(Self::CloudStorage),
246 _ => None,
247 }
248 }
249 }
250 #[derive(
252 Clone,
253 Copy,
254 Debug,
255 PartialEq,
256 Eq,
257 Hash,
258 PartialOrd,
259 Ord,
260 ::prost::Enumeration
261 )]
262 #[repr(i32)]
263 pub enum BackupTier {
264 Unspecified = 0,
266 Standard = 1,
268 #[deprecated]
270 Advanced = 2,
271 Enhanced = 3,
273 }
274 impl BackupTier {
275 pub fn as_str_name(&self) -> &'static str {
280 match self {
281 Self::Unspecified => "BACKUP_TIER_UNSPECIFIED",
282 Self::Standard => "STANDARD",
283 #[allow(deprecated)]
284 Self::Advanced => "ADVANCED",
285 Self::Enhanced => "ENHANCED",
286 }
287 }
288 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
290 match value {
291 "BACKUP_TIER_UNSPECIFIED" => Some(Self::Unspecified),
292 "STANDARD" => Some(Self::Standard),
293 "ADVANCED" => Some(#[allow(deprecated)] Self::Advanced),
294 "ENHANCED" => Some(Self::Enhanced),
295 _ => None,
296 }
297 }
298 }
299}
300#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
302pub struct BackupRun {
303 #[prost(string, tag = "1")]
305 pub kind: ::prost::alloc::string::String,
306 #[prost(enumeration = "SqlBackupRunStatus", tag = "2")]
308 pub status: i32,
309 #[prost(message, optional, tag = "3")]
313 pub enqueued_time: ::core::option::Option<::prost_types::Timestamp>,
314 #[prost(int64, tag = "4")]
317 pub id: i64,
318 #[prost(message, optional, tag = "5")]
322 pub start_time: ::core::option::Option<::prost_types::Timestamp>,
323 #[prost(message, optional, tag = "6")]
327 pub end_time: ::core::option::Option<::prost_types::Timestamp>,
328 #[prost(message, optional, tag = "7")]
331 pub error: ::core::option::Option<OperationError>,
332 #[prost(enumeration = "SqlBackupRunType", tag = "8")]
336 pub r#type: i32,
337 #[prost(string, tag = "9")]
339 pub description: ::prost::alloc::string::String,
340 #[prost(message, optional, tag = "10")]
344 pub window_start_time: ::core::option::Option<::prost_types::Timestamp>,
345 #[prost(string, tag = "11")]
347 pub instance: ::prost::alloc::string::String,
348 #[prost(string, tag = "12")]
350 pub self_link: ::prost::alloc::string::String,
351 #[prost(string, tag = "13")]
353 pub location: ::prost::alloc::string::String,
354 #[prost(enumeration = "SqlDatabaseVersion", tag = "15")]
357 pub database_version: i32,
358 #[prost(message, optional, tag = "16")]
360 pub disk_encryption_configuration: ::core::option::Option<
361 DiskEncryptionConfiguration,
362 >,
363 #[prost(message, optional, tag = "17")]
365 pub disk_encryption_status: ::core::option::Option<DiskEncryptionStatus>,
366 #[prost(enumeration = "SqlBackupKind", tag = "19")]
368 pub backup_kind: i32,
369 #[prost(string, tag = "23")]
372 pub time_zone: ::prost::alloc::string::String,
373 #[prost(int64, optional, tag = "24")]
375 pub max_chargeable_bytes: ::core::option::Option<i64>,
376}
377#[derive(Clone, PartialEq, ::prost::Message)]
379pub struct Backup {
380 #[prost(string, tag = "1")]
383 pub name: ::prost::alloc::string::String,
384 #[prost(string, tag = "2")]
386 pub kind: ::prost::alloc::string::String,
387 #[prost(string, tag = "3")]
389 pub self_link: ::prost::alloc::string::String,
390 #[prost(enumeration = "backup::SqlBackupType", tag = "4")]
393 pub r#type: i32,
394 #[prost(string, tag = "5")]
396 pub description: ::prost::alloc::string::String,
397 #[prost(string, tag = "6")]
399 pub instance: ::prost::alloc::string::String,
400 #[prost(string, tag = "7")]
402 pub location: ::prost::alloc::string::String,
403 #[prost(message, optional, tag = "8")]
407 pub backup_interval: ::core::option::Option<super::super::super::r#type::Interval>,
408 #[prost(enumeration = "backup::SqlBackupState", tag = "9")]
410 pub state: i32,
411 #[prost(message, optional, tag = "10")]
414 pub error: ::core::option::Option<OperationError>,
415 #[prost(string, tag = "11")]
418 pub kms_key: ::prost::alloc::string::String,
419 #[prost(string, tag = "12")]
422 pub kms_key_version: ::prost::alloc::string::String,
423 #[prost(enumeration = "SqlBackupKind", tag = "13")]
425 pub backup_kind: i32,
426 #[prost(string, tag = "15")]
430 pub time_zone: ::prost::alloc::string::String,
431 #[prost(enumeration = "SqlDatabaseVersion", tag = "20")]
434 pub database_version: i32,
435 #[prost(int64, optional, tag = "23")]
437 pub max_chargeable_bytes: ::core::option::Option<i64>,
438 #[prost(message, optional, tag = "24")]
441 pub instance_deletion_time: ::core::option::Option<::prost_types::Timestamp>,
442 #[prost(message, optional, tag = "25")]
445 pub instance_settings: ::core::option::Option<DatabaseInstance>,
446 #[prost(string, tag = "26")]
448 pub backup_run: ::prost::alloc::string::String,
449 #[prost(message, optional, tag = "27")]
453 pub satisfies_pzs: ::core::option::Option<bool>,
454 #[prost(message, optional, tag = "28")]
458 pub satisfies_pzi: ::core::option::Option<bool>,
459 #[prost(oneof = "backup::Expiration", tags = "16, 17")]
460 pub expiration: ::core::option::Option<backup::Expiration>,
461}
462pub mod backup {
464 #[derive(
466 Clone,
467 Copy,
468 Debug,
469 PartialEq,
470 Eq,
471 Hash,
472 PartialOrd,
473 Ord,
474 ::prost::Enumeration
475 )]
476 #[repr(i32)]
477 pub enum SqlBackupType {
478 Unspecified = 0,
480 Automated = 1,
482 OnDemand = 2,
484 Final = 3,
486 }
487 impl SqlBackupType {
488 pub fn as_str_name(&self) -> &'static str {
493 match self {
494 Self::Unspecified => "SQL_BACKUP_TYPE_UNSPECIFIED",
495 Self::Automated => "AUTOMATED",
496 Self::OnDemand => "ON_DEMAND",
497 Self::Final => "FINAL",
498 }
499 }
500 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
502 match value {
503 "SQL_BACKUP_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
504 "AUTOMATED" => Some(Self::Automated),
505 "ON_DEMAND" => Some(Self::OnDemand),
506 "FINAL" => Some(Self::Final),
507 _ => None,
508 }
509 }
510 }
511 #[derive(
513 Clone,
514 Copy,
515 Debug,
516 PartialEq,
517 Eq,
518 Hash,
519 PartialOrd,
520 Ord,
521 ::prost::Enumeration
522 )]
523 #[repr(i32)]
524 pub enum SqlBackupState {
525 Unspecified = 0,
527 Enqueued = 1,
529 Running = 2,
531 Failed = 3,
533 Successful = 4,
535 Deleting = 5,
537 DeletionFailed = 6,
539 }
540 impl SqlBackupState {
541 pub fn as_str_name(&self) -> &'static str {
546 match self {
547 Self::Unspecified => "SQL_BACKUP_STATE_UNSPECIFIED",
548 Self::Enqueued => "ENQUEUED",
549 Self::Running => "RUNNING",
550 Self::Failed => "FAILED",
551 Self::Successful => "SUCCESSFUL",
552 Self::Deleting => "DELETING",
553 Self::DeletionFailed => "DELETION_FAILED",
554 }
555 }
556 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
558 match value {
559 "SQL_BACKUP_STATE_UNSPECIFIED" => Some(Self::Unspecified),
560 "ENQUEUED" => Some(Self::Enqueued),
561 "RUNNING" => Some(Self::Running),
562 "FAILED" => Some(Self::Failed),
563 "SUCCESSFUL" => Some(Self::Successful),
564 "DELETING" => Some(Self::Deleting),
565 "DELETION_FAILED" => Some(Self::DeletionFailed),
566 _ => None,
567 }
568 }
569 }
570 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
571 pub enum Expiration {
572 #[prost(int64, tag = "16")]
577 TtlDays(i64),
578 #[prost(message, tag = "17")]
581 ExpiryTime(::prost_types::Timestamp),
582 }
583}
584#[derive(Clone, PartialEq, ::prost::Message)]
586pub struct BackupRunsListResponse {
587 #[prost(string, tag = "1")]
589 pub kind: ::prost::alloc::string::String,
590 #[prost(message, repeated, tag = "2")]
592 pub items: ::prost::alloc::vec::Vec<BackupRun>,
593 #[prost(string, tag = "3")]
596 pub next_page_token: ::prost::alloc::string::String,
597}
598#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
600pub struct BinLogCoordinates {
601 #[prost(string, tag = "1")]
603 pub bin_log_file_name: ::prost::alloc::string::String,
604 #[prost(int64, tag = "2")]
606 pub bin_log_position: i64,
607 #[prost(string, tag = "3")]
609 pub kind: ::prost::alloc::string::String,
610}
611#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
613pub struct BackupContext {
614 #[prost(int64, tag = "1")]
616 pub backup_id: i64,
617 #[prost(string, tag = "2")]
619 pub kind: ::prost::alloc::string::String,
620 #[prost(string, tag = "3")]
623 pub name: ::prost::alloc::string::String,
624}
625#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
627pub struct CloneContext {
628 #[prost(string, tag = "1")]
630 pub kind: ::prost::alloc::string::String,
631 #[prost(int64, tag = "2")]
633 pub pitr_timestamp_ms: i64,
634 #[prost(string, tag = "3")]
636 pub destination_instance_name: ::prost::alloc::string::String,
637 #[prost(message, optional, tag = "4")]
641 pub bin_log_coordinates: ::core::option::Option<BinLogCoordinates>,
642 #[prost(message, optional, tag = "5")]
645 pub point_in_time: ::core::option::Option<::prost_types::Timestamp>,
646 #[prost(string, tag = "6")]
654 pub allocated_ip_range: ::prost::alloc::string::String,
655 #[prost(string, repeated, tag = "9")]
658 pub database_names: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
659 #[prost(string, optional, tag = "10")]
663 pub preferred_zone: ::core::option::Option<::prost::alloc::string::String>,
664 #[prost(string, optional, tag = "11")]
669 pub preferred_secondary_zone: ::core::option::Option<::prost::alloc::string::String>,
670 #[prost(message, optional, tag = "12")]
673 pub source_instance_deletion_time: ::core::option::Option<::prost_types::Timestamp>,
674 #[prost(string, optional, tag = "13")]
679 pub destination_project: ::core::option::Option<::prost::alloc::string::String>,
680 #[prost(string, optional, tag = "14")]
685 pub destination_network: ::core::option::Option<::prost::alloc::string::String>,
686}
687#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
689pub struct Database {
690 #[prost(string, tag = "1")]
692 pub kind: ::prost::alloc::string::String,
693 #[prost(string, tag = "2")]
695 pub charset: ::prost::alloc::string::String,
696 #[prost(string, tag = "3")]
698 pub collation: ::prost::alloc::string::String,
699 #[prost(string, tag = "4")]
702 pub etag: ::prost::alloc::string::String,
703 #[prost(string, tag = "5")]
706 pub name: ::prost::alloc::string::String,
707 #[prost(string, tag = "6")]
709 pub instance: ::prost::alloc::string::String,
710 #[prost(string, tag = "7")]
712 pub self_link: ::prost::alloc::string::String,
713 #[prost(string, tag = "8")]
716 pub project: ::prost::alloc::string::String,
717 #[prost(oneof = "database::DatabaseDetails", tags = "9")]
718 pub database_details: ::core::option::Option<database::DatabaseDetails>,
719}
720pub mod database {
722 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
723 pub enum DatabaseDetails {
724 #[prost(message, tag = "9")]
725 SqlserverDatabaseDetails(super::SqlServerDatabaseDetails),
726 }
727}
728#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
730pub struct SqlServerDatabaseDetails {
731 #[prost(int32, tag = "1")]
733 pub compatibility_level: i32,
734 #[prost(string, tag = "2")]
736 pub recovery_model: ::prost::alloc::string::String,
737}
738#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
740pub struct DatabaseFlags {
741 #[prost(string, tag = "1")]
747 pub name: ::prost::alloc::string::String,
748 #[prost(string, tag = "2")]
752 pub value: ::prost::alloc::string::String,
753}
754#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
757pub struct SyncFlags {
758 #[prost(string, tag = "1")]
760 pub name: ::prost::alloc::string::String,
761 #[prost(string, tag = "2")]
764 pub value: ::prost::alloc::string::String,
765}
766#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
768pub struct InstanceReference {
769 #[prost(string, tag = "1")]
772 pub name: ::prost::alloc::string::String,
773 #[prost(string, tag = "2")]
775 pub region: ::prost::alloc::string::String,
776 #[prost(string, tag = "3")]
779 pub project: ::prost::alloc::string::String,
780}
781#[derive(Clone, PartialEq, ::prost::Message)]
783pub struct DatabaseInstance {
784 #[prost(string, tag = "1")]
786 pub kind: ::prost::alloc::string::String,
787 #[prost(enumeration = "database_instance::SqlInstanceState", tag = "2")]
789 pub state: i32,
790 #[prost(enumeration = "SqlDatabaseVersion", tag = "3")]
793 pub database_version: i32,
794 #[prost(message, optional, tag = "4")]
796 pub settings: ::core::option::Option<Settings>,
797 #[prost(string, tag = "5")]
800 pub etag: ::prost::alloc::string::String,
801 #[prost(message, optional, tag = "6")]
803 pub failover_replica: ::core::option::Option<database_instance::SqlFailoverReplica>,
804 #[prost(string, tag = "7")]
807 pub master_instance_name: ::prost::alloc::string::String,
808 #[prost(string, repeated, tag = "8")]
810 pub replica_names: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
811 #[deprecated]
813 #[prost(message, optional, tag = "9")]
814 pub max_disk_size: ::core::option::Option<i64>,
815 #[deprecated]
822 #[prost(message, optional, tag = "10")]
823 pub current_disk_size: ::core::option::Option<i64>,
824 #[prost(message, repeated, tag = "11")]
826 pub ip_addresses: ::prost::alloc::vec::Vec<IpMapping>,
827 #[prost(message, optional, tag = "12")]
829 pub server_ca_cert: ::core::option::Option<SslCert>,
830 #[prost(enumeration = "SqlInstanceType", tag = "13")]
832 pub instance_type: i32,
833 #[prost(string, tag = "14")]
836 pub project: ::prost::alloc::string::String,
837 #[deprecated]
841 #[prost(string, tag = "15")]
842 pub ipv6_address: ::prost::alloc::string::String,
843 #[prost(string, tag = "16")]
846 pub service_account_email_address: ::prost::alloc::string::String,
847 #[prost(message, optional, tag = "17")]
849 pub on_premises_configuration: ::core::option::Option<OnPremisesConfiguration>,
850 #[prost(message, optional, tag = "18")]
852 pub replica_configuration: ::core::option::Option<ReplicaConfiguration>,
853 #[prost(enumeration = "SqlBackendType", tag = "19")]
860 pub backend_type: i32,
861 #[prost(string, tag = "20")]
863 pub self_link: ::prost::alloc::string::String,
864 #[prost(enumeration = "SqlSuspensionReason", repeated, tag = "21")]
866 pub suspension_reason: ::prost::alloc::vec::Vec<i32>,
867 #[prost(string, tag = "22")]
869 pub connection_name: ::prost::alloc::string::String,
870 #[prost(string, tag = "23")]
872 pub name: ::prost::alloc::string::String,
873 #[prost(string, tag = "24")]
882 pub region: ::prost::alloc::string::String,
883 #[prost(string, tag = "25")]
888 pub gce_zone: ::prost::alloc::string::String,
889 #[prost(string, tag = "34")]
894 pub secondary_gce_zone: ::prost::alloc::string::String,
895 #[prost(message, optional, tag = "26")]
897 pub disk_encryption_configuration: ::core::option::Option<
898 DiskEncryptionConfiguration,
899 >,
900 #[prost(message, optional, tag = "27")]
902 pub disk_encryption_status: ::core::option::Option<DiskEncryptionStatus>,
903 #[prost(string, tag = "29")]
906 pub root_password: ::prost::alloc::string::String,
907 #[prost(message, optional, tag = "30")]
909 pub scheduled_maintenance: ::core::option::Option<
910 database_instance::SqlScheduledMaintenance,
911 >,
912 #[prost(message, optional, tag = "35")]
916 pub satisfies_pzs: ::core::option::Option<bool>,
917 #[prost(string, tag = "40")]
920 pub database_installed_version: ::prost::alloc::string::String,
921 #[prost(message, optional, tag = "38")]
929 pub out_of_disk_report: ::core::option::Option<
930 database_instance::SqlOutOfDiskReport,
931 >,
932 #[prost(message, optional, tag = "39")]
936 pub create_time: ::core::option::Option<::prost_types::Timestamp>,
937 #[prost(string, repeated, tag = "41")]
939 pub available_maintenance_versions: ::prost::alloc::vec::Vec<
940 ::prost::alloc::string::String,
941 >,
942 #[prost(string, tag = "42")]
944 pub maintenance_version: ::prost::alloc::string::String,
945 #[prost(message, repeated, tag = "45")]
947 pub upgradable_database_versions: ::prost::alloc::vec::Vec<AvailableDatabaseVersion>,
948 #[prost(
950 enumeration = "database_instance::SqlNetworkArchitecture",
951 optional,
952 tag = "47"
953 )]
954 pub sql_network_architecture: ::core::option::Option<i32>,
955 #[prost(string, optional, tag = "48")]
957 pub psc_service_attachment_link: ::core::option::Option<
958 ::prost::alloc::string::String,
959 >,
960 #[prost(string, optional, tag = "49")]
962 pub dns_name: ::core::option::Option<::prost::alloc::string::String>,
963 #[deprecated]
965 #[prost(string, optional, tag = "51")]
966 pub primary_dns_name: ::core::option::Option<::prost::alloc::string::String>,
967 #[prost(string, optional, tag = "52")]
969 pub write_endpoint: ::core::option::Option<::prost::alloc::string::String>,
970 #[prost(message, optional, tag = "54")]
976 pub replication_cluster: ::core::option::Option<ReplicationCluster>,
977 #[prost(message, optional, tag = "55")]
979 pub gemini_config: ::core::option::Option<GeminiInstanceConfig>,
980 #[prost(message, optional, tag = "56")]
984 pub satisfies_pzi: ::core::option::Option<bool>,
985 #[prost(message, optional, tag = "57")]
988 pub switch_transaction_logs_to_cloud_storage_enabled: ::core::option::Option<bool>,
989 #[prost(message, optional, tag = "59")]
993 pub include_replicas_for_major_version_upgrade: ::core::option::Option<bool>,
994 #[prost(map = "string, string", tag = "60")]
1008 pub tags: ::std::collections::HashMap<
1009 ::prost::alloc::string::String,
1010 ::prost::alloc::string::String,
1011 >,
1012 #[prost(int32, optional, tag = "63")]
1014 pub node_count: ::core::option::Option<i32>,
1015 #[prost(message, repeated, tag = "64")]
1018 pub nodes: ::prost::alloc::vec::Vec<database_instance::PoolNodeConfig>,
1019 #[prost(message, repeated, tag = "67")]
1021 pub dns_names: ::prost::alloc::vec::Vec<DnsNameMapping>,
1022}
1023pub mod database_instance {
1025 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1026 pub struct SqlFailoverReplica {
1027 #[prost(string, tag = "1")]
1031 pub name: ::prost::alloc::string::String,
1032 #[prost(message, optional, tag = "2")]
1036 pub available: ::core::option::Option<bool>,
1037 }
1038 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1040 pub struct SqlScheduledMaintenance {
1041 #[prost(message, optional, tag = "1")]
1043 pub start_time: ::core::option::Option<::prost_types::Timestamp>,
1044 #[deprecated]
1045 #[prost(bool, tag = "2")]
1046 pub can_defer: bool,
1047 #[prost(bool, tag = "3")]
1049 pub can_reschedule: bool,
1050 #[prost(message, optional, tag = "4")]
1052 pub schedule_deadline_time: ::core::option::Option<::prost_types::Timestamp>,
1053 }
1054 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1056 pub struct SqlOutOfDiskReport {
1057 #[prost(
1065 enumeration = "sql_out_of_disk_report::SqlOutOfDiskState",
1066 optional,
1067 tag = "1"
1068 )]
1069 pub sql_out_of_disk_state: ::core::option::Option<i32>,
1070 #[prost(int32, optional, tag = "2")]
1077 pub sql_min_recommended_increase_size_gb: ::core::option::Option<i32>,
1078 }
1079 pub mod sql_out_of_disk_report {
1081 #[derive(
1083 Clone,
1084 Copy,
1085 Debug,
1086 PartialEq,
1087 Eq,
1088 Hash,
1089 PartialOrd,
1090 Ord,
1091 ::prost::Enumeration
1092 )]
1093 #[repr(i32)]
1094 pub enum SqlOutOfDiskState {
1095 Unspecified = 0,
1097 Normal = 1,
1099 SoftShutdown = 2,
1102 }
1103 impl SqlOutOfDiskState {
1104 pub fn as_str_name(&self) -> &'static str {
1109 match self {
1110 Self::Unspecified => "SQL_OUT_OF_DISK_STATE_UNSPECIFIED",
1111 Self::Normal => "NORMAL",
1112 Self::SoftShutdown => "SOFT_SHUTDOWN",
1113 }
1114 }
1115 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1117 match value {
1118 "SQL_OUT_OF_DISK_STATE_UNSPECIFIED" => Some(Self::Unspecified),
1119 "NORMAL" => Some(Self::Normal),
1120 "SOFT_SHUTDOWN" => Some(Self::SoftShutdown),
1121 _ => None,
1122 }
1123 }
1124 }
1125 }
1126 #[derive(Clone, PartialEq, ::prost::Message)]
1128 pub struct PoolNodeConfig {
1129 #[prost(string, optional, tag = "1")]
1132 pub name: ::core::option::Option<::prost::alloc::string::String>,
1133 #[prost(string, optional, tag = "2")]
1135 pub gce_zone: ::core::option::Option<::prost::alloc::string::String>,
1136 #[prost(message, repeated, tag = "3")]
1139 pub ip_addresses: ::prost::alloc::vec::Vec<super::IpMapping>,
1140 #[prost(string, optional, tag = "4")]
1142 pub dns_name: ::core::option::Option<::prost::alloc::string::String>,
1143 #[prost(enumeration = "SqlInstanceState", optional, tag = "5")]
1145 pub state: ::core::option::Option<i32>,
1146 #[prost(message, repeated, tag = "6")]
1148 pub dns_names: ::prost::alloc::vec::Vec<super::DnsNameMapping>,
1149 #[prost(string, optional, tag = "7")]
1152 pub psc_service_attachment_link: ::core::option::Option<
1153 ::prost::alloc::string::String,
1154 >,
1155 #[prost(message, repeated, tag = "8")]
1159 pub psc_auto_connections: ::prost::alloc::vec::Vec<
1160 super::PscAutoConnectionConfig,
1161 >,
1162 }
1163 #[derive(
1165 Clone,
1166 Copy,
1167 Debug,
1168 PartialEq,
1169 Eq,
1170 Hash,
1171 PartialOrd,
1172 Ord,
1173 ::prost::Enumeration
1174 )]
1175 #[repr(i32)]
1176 pub enum SqlInstanceState {
1177 Unspecified = 0,
1179 Runnable = 1,
1181 Suspended = 2,
1183 PendingDelete = 3,
1185 PendingCreate = 4,
1187 Maintenance = 5,
1189 Failed = 6,
1192 #[deprecated]
1194 OnlineMaintenance = 7,
1195 Repairing = 8,
1198 }
1199 impl SqlInstanceState {
1200 pub fn as_str_name(&self) -> &'static str {
1205 match self {
1206 Self::Unspecified => "SQL_INSTANCE_STATE_UNSPECIFIED",
1207 Self::Runnable => "RUNNABLE",
1208 Self::Suspended => "SUSPENDED",
1209 Self::PendingDelete => "PENDING_DELETE",
1210 Self::PendingCreate => "PENDING_CREATE",
1211 Self::Maintenance => "MAINTENANCE",
1212 Self::Failed => "FAILED",
1213 #[allow(deprecated)]
1214 Self::OnlineMaintenance => "ONLINE_MAINTENANCE",
1215 Self::Repairing => "REPAIRING",
1216 }
1217 }
1218 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1220 match value {
1221 "SQL_INSTANCE_STATE_UNSPECIFIED" => Some(Self::Unspecified),
1222 "RUNNABLE" => Some(Self::Runnable),
1223 "SUSPENDED" => Some(Self::Suspended),
1224 "PENDING_DELETE" => Some(Self::PendingDelete),
1225 "PENDING_CREATE" => Some(Self::PendingCreate),
1226 "MAINTENANCE" => Some(Self::Maintenance),
1227 "FAILED" => Some(Self::Failed),
1228 "ONLINE_MAINTENANCE" => {
1229 Some(#[allow(deprecated)] Self::OnlineMaintenance)
1230 }
1231 "REPAIRING" => Some(Self::Repairing),
1232 _ => None,
1233 }
1234 }
1235 }
1236 #[derive(
1238 Clone,
1239 Copy,
1240 Debug,
1241 PartialEq,
1242 Eq,
1243 Hash,
1244 PartialOrd,
1245 Ord,
1246 ::prost::Enumeration
1247 )]
1248 #[repr(i32)]
1249 pub enum SqlNetworkArchitecture {
1250 Unspecified = 0,
1251 NewNetworkArchitecture = 1,
1253 OldNetworkArchitecture = 2,
1255 }
1256 impl SqlNetworkArchitecture {
1257 pub fn as_str_name(&self) -> &'static str {
1262 match self {
1263 Self::Unspecified => "SQL_NETWORK_ARCHITECTURE_UNSPECIFIED",
1264 Self::NewNetworkArchitecture => "NEW_NETWORK_ARCHITECTURE",
1265 Self::OldNetworkArchitecture => "OLD_NETWORK_ARCHITECTURE",
1266 }
1267 }
1268 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1270 match value {
1271 "SQL_NETWORK_ARCHITECTURE_UNSPECIFIED" => Some(Self::Unspecified),
1272 "NEW_NETWORK_ARCHITECTURE" => Some(Self::NewNetworkArchitecture),
1273 "OLD_NETWORK_ARCHITECTURE" => Some(Self::OldNetworkArchitecture),
1274 _ => None,
1275 }
1276 }
1277 }
1278}
1279#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1281pub struct DnsNameMapping {
1282 #[prost(string, tag = "1")]
1284 pub name: ::prost::alloc::string::String,
1285 #[prost(enumeration = "dns_name_mapping::ConnectionType", tag = "2")]
1287 pub connection_type: i32,
1288 #[prost(enumeration = "dns_name_mapping::DnsScope", tag = "3")]
1290 pub dns_scope: i32,
1291 #[prost(enumeration = "dns_name_mapping::RecordManager", tag = "4")]
1293 pub record_manager: i32,
1294}
1295pub mod dns_name_mapping {
1297 #[derive(
1299 Clone,
1300 Copy,
1301 Debug,
1302 PartialEq,
1303 Eq,
1304 Hash,
1305 PartialOrd,
1306 Ord,
1307 ::prost::Enumeration
1308 )]
1309 #[repr(i32)]
1310 pub enum ConnectionType {
1311 Unspecified = 0,
1313 Public = 1,
1315 PrivateServicesAccess = 2,
1317 PrivateServiceConnect = 3,
1319 }
1320 impl ConnectionType {
1321 pub fn as_str_name(&self) -> &'static str {
1326 match self {
1327 Self::Unspecified => "CONNECTION_TYPE_UNSPECIFIED",
1328 Self::Public => "PUBLIC",
1329 Self::PrivateServicesAccess => "PRIVATE_SERVICES_ACCESS",
1330 Self::PrivateServiceConnect => "PRIVATE_SERVICE_CONNECT",
1331 }
1332 }
1333 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1335 match value {
1336 "CONNECTION_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
1337 "PUBLIC" => Some(Self::Public),
1338 "PRIVATE_SERVICES_ACCESS" => Some(Self::PrivateServicesAccess),
1339 "PRIVATE_SERVICE_CONNECT" => Some(Self::PrivateServiceConnect),
1340 _ => None,
1341 }
1342 }
1343 }
1344 #[derive(
1346 Clone,
1347 Copy,
1348 Debug,
1349 PartialEq,
1350 Eq,
1351 Hash,
1352 PartialOrd,
1353 Ord,
1354 ::prost::Enumeration
1355 )]
1356 #[repr(i32)]
1357 pub enum DnsScope {
1358 Unspecified = 0,
1360 Instance = 1,
1362 Cluster = 2,
1364 }
1365 impl DnsScope {
1366 pub fn as_str_name(&self) -> &'static str {
1371 match self {
1372 Self::Unspecified => "DNS_SCOPE_UNSPECIFIED",
1373 Self::Instance => "INSTANCE",
1374 Self::Cluster => "CLUSTER",
1375 }
1376 }
1377 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1379 match value {
1380 "DNS_SCOPE_UNSPECIFIED" => Some(Self::Unspecified),
1381 "INSTANCE" => Some(Self::Instance),
1382 "CLUSTER" => Some(Self::Cluster),
1383 _ => None,
1384 }
1385 }
1386 }
1387 #[derive(
1389 Clone,
1390 Copy,
1391 Debug,
1392 PartialEq,
1393 Eq,
1394 Hash,
1395 PartialOrd,
1396 Ord,
1397 ::prost::Enumeration
1398 )]
1399 #[repr(i32)]
1400 pub enum RecordManager {
1401 Unspecified = 0,
1403 Customer = 1,
1406 CloudSqlAutomation = 2,
1410 }
1411 impl RecordManager {
1412 pub fn as_str_name(&self) -> &'static str {
1417 match self {
1418 Self::Unspecified => "RECORD_MANAGER_UNSPECIFIED",
1419 Self::Customer => "CUSTOMER",
1420 Self::CloudSqlAutomation => "CLOUD_SQL_AUTOMATION",
1421 }
1422 }
1423 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1425 match value {
1426 "RECORD_MANAGER_UNSPECIFIED" => Some(Self::Unspecified),
1427 "CUSTOMER" => Some(Self::Customer),
1428 "CLOUD_SQL_AUTOMATION" => Some(Self::CloudSqlAutomation),
1429 _ => None,
1430 }
1431 }
1432 }
1433}
1434#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1436pub struct GeminiInstanceConfig {
1437 #[prost(bool, optional, tag = "1")]
1439 pub entitled: ::core::option::Option<bool>,
1440 #[prost(bool, optional, tag = "2")]
1442 pub google_vacuum_mgmt_enabled: ::core::option::Option<bool>,
1443 #[prost(bool, optional, tag = "3")]
1445 pub oom_session_cancel_enabled: ::core::option::Option<bool>,
1446 #[prost(bool, optional, tag = "4")]
1448 pub active_query_enabled: ::core::option::Option<bool>,
1449 #[prost(bool, optional, tag = "5")]
1451 pub index_advisor_enabled: ::core::option::Option<bool>,
1452 #[prost(bool, optional, tag = "6")]
1454 pub flag_recommender_enabled: ::core::option::Option<bool>,
1455}
1456#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1461pub struct ReplicationCluster {
1462 #[prost(string, optional, tag = "1")]
1471 pub psa_write_endpoint: ::core::option::Option<::prost::alloc::string::String>,
1472 #[prost(string, optional, tag = "2")]
1479 pub failover_dr_replica_name: ::core::option::Option<::prost::alloc::string::String>,
1480 #[prost(bool, optional, tag = "4")]
1483 pub dr_replica: ::core::option::Option<bool>,
1484}
1485#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1487pub struct AvailableDatabaseVersion {
1488 #[prost(string, optional, tag = "3")]
1490 pub major_version: ::core::option::Option<::prost::alloc::string::String>,
1491 #[prost(string, optional, tag = "8")]
1494 pub name: ::core::option::Option<::prost::alloc::string::String>,
1495 #[prost(string, optional, tag = "9")]
1497 pub display_name: ::core::option::Option<::prost::alloc::string::String>,
1498}
1499#[derive(Clone, PartialEq, ::prost::Message)]
1501pub struct DatabasesListResponse {
1502 #[prost(string, tag = "1")]
1504 pub kind: ::prost::alloc::string::String,
1505 #[prost(message, repeated, tag = "2")]
1507 pub items: ::prost::alloc::vec::Vec<Database>,
1508}
1509#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1512pub struct DemoteMasterConfiguration {
1513 #[prost(string, tag = "1")]
1515 pub kind: ::prost::alloc::string::String,
1516 #[prost(message, optional, tag = "2")]
1523 pub mysql_replica_configuration: ::core::option::Option<
1524 DemoteMasterMySqlReplicaConfiguration,
1525 >,
1526}
1527#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1529pub struct DemoteMasterContext {
1530 #[prost(string, tag = "1")]
1532 pub kind: ::prost::alloc::string::String,
1533 #[prost(message, optional, tag = "2")]
1541 pub verify_gtid_consistency: ::core::option::Option<bool>,
1542 #[prost(string, tag = "3")]
1545 pub master_instance_name: ::prost::alloc::string::String,
1546 #[prost(message, optional, tag = "4")]
1549 pub replica_configuration: ::core::option::Option<DemoteMasterConfiguration>,
1550 #[prost(bool, tag = "5")]
1552 pub skip_replication_setup: bool,
1553}
1554#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1556pub struct DemoteMasterMySqlReplicaConfiguration {
1557 #[prost(string, tag = "1")]
1559 pub kind: ::prost::alloc::string::String,
1560 #[prost(string, tag = "2")]
1562 pub username: ::prost::alloc::string::String,
1563 #[prost(string, tag = "3")]
1565 pub password: ::prost::alloc::string::String,
1566 #[prost(string, tag = "4")]
1570 pub client_key: ::prost::alloc::string::String,
1571 #[prost(string, tag = "5")]
1573 pub client_certificate: ::prost::alloc::string::String,
1574 #[prost(string, tag = "6")]
1576 pub ca_certificate: ::prost::alloc::string::String,
1577}
1578#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1581pub struct DemoteContext {
1582 #[prost(string, tag = "1")]
1584 pub kind: ::prost::alloc::string::String,
1585 #[prost(string, tag = "2")]
1588 pub source_representative_instance_name: ::prost::alloc::string::String,
1589}
1590#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1592pub struct ExportContext {
1593 #[prost(string, tag = "1")]
1599 pub uri: ::prost::alloc::string::String,
1600 #[prost(string, repeated, tag = "2")]
1615 pub databases: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1616 #[prost(string, tag = "3")]
1618 pub kind: ::prost::alloc::string::String,
1619 #[prost(message, optional, tag = "4")]
1621 pub sql_export_options: ::core::option::Option<export_context::SqlExportOptions>,
1622 #[prost(message, optional, tag = "5")]
1625 pub csv_export_options: ::core::option::Option<export_context::SqlCsvExportOptions>,
1626 #[prost(enumeration = "SqlFileType", tag = "6")]
1628 pub file_type: i32,
1629 #[prost(message, optional, tag = "8")]
1631 pub offload: ::core::option::Option<bool>,
1632 #[prost(message, optional, tag = "9")]
1634 pub bak_export_options: ::core::option::Option<export_context::SqlBakExportOptions>,
1635 #[prost(message, optional, tag = "10")]
1637 pub tde_export_options: ::core::option::Option<export_context::SqlTdeExportOptions>,
1638}
1639pub mod export_context {
1641 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1642 pub struct SqlCsvExportOptions {
1643 #[prost(string, tag = "1")]
1645 pub select_query: ::prost::alloc::string::String,
1646 #[prost(string, tag = "2")]
1649 pub escape_character: ::prost::alloc::string::String,
1650 #[prost(string, tag = "3")]
1652 pub quote_character: ::prost::alloc::string::String,
1653 #[prost(string, tag = "4")]
1656 pub fields_terminated_by: ::prost::alloc::string::String,
1657 #[prost(string, tag = "6")]
1660 pub lines_terminated_by: ::prost::alloc::string::String,
1661 }
1662 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1663 pub struct SqlExportOptions {
1664 #[prost(string, repeated, tag = "1")]
1668 pub tables: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1669 #[prost(message, optional, tag = "2")]
1671 pub schema_only: ::core::option::Option<bool>,
1672 #[prost(message, optional, tag = "3")]
1673 pub mysql_export_options: ::core::option::Option<
1674 sql_export_options::MysqlExportOptions,
1675 >,
1676 #[prost(message, optional, tag = "4")]
1678 pub threads: ::core::option::Option<i32>,
1679 #[prost(message, optional, tag = "5")]
1681 pub parallel: ::core::option::Option<bool>,
1682 #[prost(message, optional, tag = "6")]
1684 pub postgres_export_options: ::core::option::Option<
1685 sql_export_options::PostgresExportOptions,
1686 >,
1687 }
1688 pub mod sql_export_options {
1690 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1692 pub struct MysqlExportOptions {
1693 #[prost(message, optional, tag = "1")]
1700 pub master_data: ::core::option::Option<i32>,
1701 }
1702 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1704 pub struct PostgresExportOptions {
1705 #[prost(message, optional, tag = "1")]
1709 pub clean: ::core::option::Option<bool>,
1710 #[prost(message, optional, tag = "2")]
1713 pub if_exists: ::core::option::Option<bool>,
1714 }
1715 }
1716 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1718 pub struct SqlBakExportOptions {
1719 #[prost(message, optional, tag = "1")]
1721 pub striped: ::core::option::Option<bool>,
1722 #[prost(message, optional, tag = "2")]
1726 pub stripe_count: ::core::option::Option<i32>,
1727 #[prost(enumeration = "super::BakType", tag = "4")]
1729 pub bak_type: i32,
1730 #[deprecated]
1732 #[prost(message, optional, tag = "5")]
1733 pub copy_only: ::core::option::Option<bool>,
1734 #[prost(message, optional, tag = "6")]
1737 pub differential_base: ::core::option::Option<bool>,
1738 #[prost(message, optional, tag = "7")]
1744 pub export_log_start_time: ::core::option::Option<::prost_types::Timestamp>,
1745 #[prost(message, optional, tag = "8")]
1751 pub export_log_end_time: ::core::option::Option<::prost_types::Timestamp>,
1752 }
1753 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1754 pub struct SqlTdeExportOptions {
1755 #[prost(string, tag = "1")]
1760 pub certificate_path: ::prost::alloc::string::String,
1761 #[prost(string, tag = "2")]
1766 pub private_key_path: ::prost::alloc::string::String,
1767 #[prost(string, tag = "3")]
1769 pub private_key_password: ::prost::alloc::string::String,
1770 #[prost(string, tag = "5")]
1773 pub name: ::prost::alloc::string::String,
1774 }
1775}
1776#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1778pub struct FailoverContext {
1779 #[prost(int64, tag = "1")]
1782 pub settings_version: i64,
1783 #[prost(string, tag = "2")]
1785 pub kind: ::prost::alloc::string::String,
1786}
1787#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1789pub struct Flag {
1790 #[prost(string, tag = "1")]
1793 pub name: ::prost::alloc::string::String,
1794 #[prost(enumeration = "SqlFlagType", tag = "2")]
1798 pub r#type: i32,
1799 #[prost(enumeration = "SqlDatabaseVersion", repeated, tag = "3")]
1810 pub applies_to: ::prost::alloc::vec::Vec<i32>,
1811 #[prost(string, repeated, tag = "4")]
1813 pub allowed_string_values: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1814 #[prost(message, optional, tag = "5")]
1816 pub min_value: ::core::option::Option<i64>,
1817 #[prost(message, optional, tag = "6")]
1819 pub max_value: ::core::option::Option<i64>,
1820 #[prost(message, optional, tag = "7")]
1823 pub requires_restart: ::core::option::Option<bool>,
1824 #[prost(string, tag = "8")]
1826 pub kind: ::prost::alloc::string::String,
1827 #[prost(message, optional, tag = "9")]
1829 pub in_beta: ::core::option::Option<bool>,
1830 #[prost(int64, repeated, tag = "10")]
1833 pub allowed_int_values: ::prost::alloc::vec::Vec<i64>,
1834 #[prost(enumeration = "SqlFlagScope", tag = "15")]
1836 pub flag_scope: i32,
1837 #[prost(oneof = "flag::RecommendedValue", tags = "16, 17")]
1839 pub recommended_value: ::core::option::Option<flag::RecommendedValue>,
1840}
1841pub mod flag {
1843 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
1845 pub enum RecommendedValue {
1846 #[prost(string, tag = "16")]
1848 RecommendedStringValue(::prost::alloc::string::String),
1849 #[prost(message, tag = "17")]
1851 RecommendedIntValue(i64),
1852 }
1853}
1854#[derive(Clone, PartialEq, ::prost::Message)]
1856pub struct FlagsListResponse {
1857 #[prost(string, tag = "1")]
1859 pub kind: ::prost::alloc::string::String,
1860 #[prost(message, repeated, tag = "2")]
1862 pub items: ::prost::alloc::vec::Vec<Flag>,
1863}
1864#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1866pub struct ImportContext {
1867 #[prost(string, tag = "1")]
1872 pub uri: ::prost::alloc::string::String,
1873 #[prost(string, tag = "2")]
1880 pub database: ::prost::alloc::string::String,
1881 #[prost(string, tag = "3")]
1883 pub kind: ::prost::alloc::string::String,
1884 #[prost(enumeration = "SqlFileType", tag = "4")]
1890 pub file_type: i32,
1891 #[prost(message, optional, tag = "5")]
1893 pub csv_import_options: ::core::option::Option<import_context::SqlCsvImportOptions>,
1894 #[prost(string, tag = "6")]
1896 pub import_user: ::prost::alloc::string::String,
1897 #[prost(message, optional, tag = "7")]
1899 pub bak_import_options: ::core::option::Option<import_context::SqlBakImportOptions>,
1900 #[prost(message, optional, tag = "8")]
1902 pub sql_import_options: ::core::option::Option<import_context::SqlImportOptions>,
1903 #[prost(message, optional, tag = "9")]
1906 pub tde_import_options: ::core::option::Option<import_context::SqlTdeImportOptions>,
1907}
1908pub mod import_context {
1910 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1911 pub struct SqlImportOptions {
1912 #[prost(message, optional, tag = "1")]
1914 pub threads: ::core::option::Option<i32>,
1915 #[prost(message, optional, tag = "2")]
1917 pub parallel: ::core::option::Option<bool>,
1918 #[prost(message, optional, tag = "3")]
1920 pub postgres_import_options: ::core::option::Option<
1921 sql_import_options::PostgresImportOptions,
1922 >,
1923 }
1924 pub mod sql_import_options {
1926 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
1927 pub struct PostgresImportOptions {
1928 #[prost(message, optional, tag = "1")]
1931 pub clean: ::core::option::Option<bool>,
1932 #[prost(message, optional, tag = "2")]
1935 pub if_exists: ::core::option::Option<bool>,
1936 }
1937 }
1938 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1939 pub struct SqlCsvImportOptions {
1940 #[prost(string, tag = "1")]
1942 pub table: ::prost::alloc::string::String,
1943 #[prost(string, repeated, tag = "2")]
1946 pub columns: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
1947 #[prost(string, tag = "4")]
1950 pub escape_character: ::prost::alloc::string::String,
1951 #[prost(string, tag = "5")]
1953 pub quote_character: ::prost::alloc::string::String,
1954 #[prost(string, tag = "6")]
1957 pub fields_terminated_by: ::prost::alloc::string::String,
1958 #[prost(string, tag = "8")]
1961 pub lines_terminated_by: ::prost::alloc::string::String,
1962 }
1963 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1964 pub struct SqlBakImportOptions {
1965 #[prost(message, optional, tag = "1")]
1966 pub encryption_options: ::core::option::Option<
1967 sql_bak_import_options::EncryptionOptions,
1968 >,
1969 #[prost(message, optional, tag = "2")]
1972 pub striped: ::core::option::Option<bool>,
1973 #[prost(message, optional, tag = "4")]
1977 pub no_recovery: ::core::option::Option<bool>,
1978 #[prost(message, optional, tag = "5")]
1983 pub recovery_only: ::core::option::Option<bool>,
1984 #[prost(enumeration = "super::BakType", tag = "6")]
1986 pub bak_type: i32,
1987 #[prost(message, optional, tag = "7")]
1992 pub stop_at: ::core::option::Option<::prost_types::Timestamp>,
1993 #[prost(string, tag = "8")]
1997 pub stop_at_mark: ::prost::alloc::string::String,
1998 }
1999 pub mod sql_bak_import_options {
2001 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2002 pub struct EncryptionOptions {
2003 #[prost(string, tag = "1")]
2007 pub cert_path: ::prost::alloc::string::String,
2008 #[prost(string, tag = "2")]
2012 pub pvk_path: ::prost::alloc::string::String,
2013 #[prost(string, tag = "3")]
2015 pub pvk_password: ::prost::alloc::string::String,
2016 #[prost(message, optional, tag = "5")]
2018 pub keep_encrypted: ::core::option::Option<bool>,
2019 }
2020 }
2021 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2022 pub struct SqlTdeImportOptions {
2023 #[prost(string, tag = "1")]
2028 pub certificate_path: ::prost::alloc::string::String,
2029 #[prost(string, tag = "2")]
2034 pub private_key_path: ::prost::alloc::string::String,
2035 #[prost(string, tag = "3")]
2037 pub private_key_password: ::prost::alloc::string::String,
2038 #[prost(string, tag = "5")]
2041 pub name: ::prost::alloc::string::String,
2042 }
2043}
2044#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2046pub struct InstancesCloneRequest {
2047 #[prost(message, optional, tag = "1")]
2049 pub clone_context: ::core::option::Option<CloneContext>,
2050}
2051#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2053pub struct InstancesDemoteMasterRequest {
2054 #[prost(message, optional, tag = "1")]
2056 pub demote_master_context: ::core::option::Option<DemoteMasterContext>,
2057}
2058#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2061pub struct InstancesDemoteRequest {
2062 #[prost(message, optional, tag = "1")]
2065 pub demote_context: ::core::option::Option<DemoteContext>,
2066}
2067#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2069pub struct InstancesExportRequest {
2070 #[prost(message, optional, tag = "1")]
2072 pub export_context: ::core::option::Option<ExportContext>,
2073}
2074#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2076pub struct InstancesFailoverRequest {
2077 #[prost(message, optional, tag = "1")]
2079 pub failover_context: ::core::option::Option<FailoverContext>,
2080}
2081#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2083pub struct InstancesImportRequest {
2084 #[prost(message, optional, tag = "1")]
2086 pub import_context: ::core::option::Option<ImportContext>,
2087}
2088#[derive(Clone, PartialEq, ::prost::Message)]
2090pub struct InstancesPreCheckMajorVersionUpgradeRequest {
2091 #[prost(message, optional, tag = "1")]
2094 pub pre_check_major_version_upgrade_context: ::core::option::Option<
2095 PreCheckMajorVersionUpgradeContext,
2096 >,
2097}
2098#[derive(Clone, PartialEq, ::prost::Message)]
2100pub struct MySqlSyncConfig {
2101 #[prost(message, repeated, tag = "1")]
2103 pub initial_sync_flags: ::prost::alloc::vec::Vec<SyncFlags>,
2104}
2105#[derive(Clone, PartialEq, ::prost::Message)]
2107pub struct InstancesListResponse {
2108 #[prost(string, tag = "1")]
2110 pub kind: ::prost::alloc::string::String,
2111 #[prost(message, repeated, tag = "2")]
2113 pub warnings: ::prost::alloc::vec::Vec<ApiWarning>,
2114 #[prost(message, repeated, tag = "3")]
2116 pub items: ::prost::alloc::vec::Vec<DatabaseInstance>,
2117 #[prost(string, tag = "4")]
2120 pub next_page_token: ::prost::alloc::string::String,
2121}
2122#[derive(Clone, PartialEq, ::prost::Message)]
2124pub struct InstancesListServerCasResponse {
2125 #[prost(message, repeated, tag = "1")]
2127 pub certs: ::prost::alloc::vec::Vec<SslCert>,
2128 #[prost(string, tag = "2")]
2129 pub active_version: ::prost::alloc::string::String,
2130 #[prost(string, tag = "3")]
2132 pub kind: ::prost::alloc::string::String,
2133}
2134#[derive(Clone, PartialEq, ::prost::Message)]
2136pub struct InstancesListServerCertificatesResponse {
2137 #[prost(message, repeated, tag = "1")]
2139 pub ca_certs: ::prost::alloc::vec::Vec<SslCert>,
2140 #[prost(message, repeated, tag = "2")]
2143 pub server_certs: ::prost::alloc::vec::Vec<SslCert>,
2144 #[prost(string, tag = "3")]
2146 pub active_version: ::prost::alloc::string::String,
2147 #[prost(string, tag = "4")]
2149 pub kind: ::prost::alloc::string::String,
2150}
2151#[derive(Clone, PartialEq, ::prost::Message)]
2153pub struct InstancesListEntraIdCertificatesResponse {
2154 #[prost(message, repeated, tag = "1")]
2156 pub certs: ::prost::alloc::vec::Vec<SslCert>,
2157 #[prost(string, tag = "2")]
2159 pub active_version: ::prost::alloc::string::String,
2160 #[prost(string, tag = "3")]
2162 pub kind: ::prost::alloc::string::String,
2163}
2164#[derive(Clone, PartialEq, ::prost::Message)]
2166pub struct InstancesRestoreBackupRequest {
2167 #[prost(message, optional, tag = "1")]
2169 pub restore_backup_context: ::core::option::Option<RestoreBackupContext>,
2170 #[prost(string, tag = "2")]
2174 pub backup: ::prost::alloc::string::String,
2175 #[prost(string, tag = "4")]
2181 pub backupdr_backup: ::prost::alloc::string::String,
2182 #[prost(message, optional, tag = "3")]
2188 pub restore_instance_settings: ::core::option::Option<DatabaseInstance>,
2189 #[prost(string, repeated, tag = "5")]
2193 pub restore_instance_clear_overrides_field_names: ::prost::alloc::vec::Vec<
2194 ::prost::alloc::string::String,
2195 >,
2196}
2197#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2199pub struct InstancesRotateServerCaRequest {
2200 #[prost(message, optional, tag = "1")]
2202 pub rotate_server_ca_context: ::core::option::Option<RotateServerCaContext>,
2203}
2204#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2206pub struct InstancesRotateServerCertificateRequest {
2207 #[prost(message, optional, tag = "1")]
2209 pub rotate_server_certificate_context: ::core::option::Option<
2210 RotateServerCertificateContext,
2211 >,
2212}
2213#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2215pub struct InstancesRotateEntraIdCertificateRequest {
2216 #[prost(message, optional, tag = "1")]
2218 pub rotate_entra_id_certificate_context: ::core::option::Option<
2219 RotateEntraIdCertificateContext,
2220 >,
2221}
2222#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2224pub struct InstancesTruncateLogRequest {
2225 #[prost(message, optional, tag = "1")]
2227 pub truncate_log_context: ::core::option::Option<TruncateLogContext>,
2228}
2229#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2231pub struct InstancesAcquireSsrsLeaseRequest {
2232 #[prost(message, optional, tag = "1")]
2234 pub acquire_ssrs_lease_context: ::core::option::Option<AcquireSsrsLeaseContext>,
2235}
2236#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2239pub struct PointInTimeRestoreContext {
2240 #[prost(string, optional, tag = "1")]
2244 pub datasource: ::core::option::Option<::prost::alloc::string::String>,
2245 #[prost(message, optional, tag = "2")]
2247 pub point_in_time: ::core::option::Option<::prost_types::Timestamp>,
2248 #[prost(string, optional, tag = "3")]
2250 pub target_instance: ::core::option::Option<::prost::alloc::string::String>,
2251 #[prost(string, optional, tag = "4")]
2255 pub private_network: ::core::option::Option<::prost::alloc::string::String>,
2256 #[prost(string, optional, tag = "5")]
2264 pub allocated_ip_range: ::core::option::Option<::prost::alloc::string::String>,
2265 #[prost(string, optional, tag = "6")]
2269 pub preferred_zone: ::core::option::Option<::prost::alloc::string::String>,
2270 #[prost(string, optional, tag = "9")]
2274 pub preferred_secondary_zone: ::core::option::Option<::prost::alloc::string::String>,
2275}
2276#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
2278pub struct PerformDiskShrinkContext {
2279 #[prost(int64, tag = "1")]
2281 pub target_size_gb: i64,
2282}
2283#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2286pub struct PreCheckResponse {
2287 #[prost(string, optional, tag = "2")]
2289 pub message: ::core::option::Option<::prost::alloc::string::String>,
2290 #[prost(enumeration = "pre_check_response::MessageType", optional, tag = "3")]
2292 pub message_type: ::core::option::Option<i32>,
2293 #[prost(string, repeated, tag = "4")]
2296 pub actions_required: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
2297}
2298pub mod pre_check_response {
2300 #[derive(
2303 Clone,
2304 Copy,
2305 Debug,
2306 PartialEq,
2307 Eq,
2308 Hash,
2309 PartialOrd,
2310 Ord,
2311 ::prost::Enumeration
2312 )]
2313 #[repr(i32)]
2314 pub enum MessageType {
2315 Unspecified = 0,
2317 Info = 1,
2319 Warning = 2,
2321 Error = 3,
2323 }
2324 impl MessageType {
2325 pub fn as_str_name(&self) -> &'static str {
2330 match self {
2331 Self::Unspecified => "MESSAGE_TYPE_UNSPECIFIED",
2332 Self::Info => "INFO",
2333 Self::Warning => "WARNING",
2334 Self::Error => "ERROR",
2335 }
2336 }
2337 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2339 match value {
2340 "MESSAGE_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
2341 "INFO" => Some(Self::Info),
2342 "WARNING" => Some(Self::Warning),
2343 "ERROR" => Some(Self::Error),
2344 _ => None,
2345 }
2346 }
2347 }
2348}
2349#[derive(Clone, PartialEq, ::prost::Message)]
2351pub struct PreCheckMajorVersionUpgradeContext {
2352 #[prost(enumeration = "SqlDatabaseVersion", tag = "1")]
2354 pub target_database_version: i32,
2355 #[prost(message, repeated, tag = "2")]
2357 pub pre_check_response: ::prost::alloc::vec::Vec<PreCheckResponse>,
2358 #[prost(string, tag = "3")]
2360 pub kind: ::prost::alloc::string::String,
2361}
2362#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2364pub struct SqlInstancesGetDiskShrinkConfigResponse {
2365 #[prost(string, tag = "1")]
2367 pub kind: ::prost::alloc::string::String,
2368 #[prost(int64, tag = "2")]
2370 pub minimal_target_size_gb: i64,
2371 #[prost(string, tag = "3")]
2373 pub message: ::prost::alloc::string::String,
2374}
2375#[derive(Clone, PartialEq, ::prost::Message)]
2377pub struct SqlInstancesVerifyExternalSyncSettingsResponse {
2378 #[prost(string, tag = "1")]
2380 pub kind: ::prost::alloc::string::String,
2381 #[prost(message, repeated, tag = "2")]
2383 pub errors: ::prost::alloc::vec::Vec<SqlExternalSyncSettingError>,
2384 #[prost(message, repeated, tag = "3")]
2386 pub warnings: ::prost::alloc::vec::Vec<SqlExternalSyncSettingError>,
2387}
2388#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
2390pub struct SqlExternalSyncSettingError {
2391 #[prost(string, tag = "1")]
2394 pub kind: ::prost::alloc::string::String,
2395 #[prost(
2397 enumeration = "sql_external_sync_setting_error::SqlExternalSyncSettingErrorType",
2398 tag = "2"
2399 )]
2400 pub r#type: i32,
2401 #[prost(string, tag = "3")]
2403 pub detail: ::prost::alloc::string::String,
2404}
2405pub mod sql_external_sync_setting_error {
2407 #[derive(
2408 Clone,
2409 Copy,
2410 Debug,
2411 PartialEq,
2412 Eq,
2413 Hash,
2414 PartialOrd,
2415 Ord,
2416 ::prost::Enumeration
2417 )]
2418 #[repr(i32)]
2419 pub enum SqlExternalSyncSettingErrorType {
2420 Unspecified = 0,
2421 ConnectionFailure = 1,
2422 BinlogNotEnabled = 2,
2423 IncompatibleDatabaseVersion = 3,
2424 ReplicaAlreadySetup = 4,
2425 InsufficientPrivilege = 5,
2427 UnsupportedMigrationType = 6,
2429 NoPglogicalInstalled = 7,
2431 PglogicalNodeAlreadyExists = 8,
2433 InvalidWalLevel = 9,
2435 InvalidSharedPreloadLibrary = 10,
2438 InsufficientMaxReplicationSlots = 11,
2440 InsufficientMaxWalSenders = 12,
2442 InsufficientMaxWorkerProcesses = 13,
2444 UnsupportedExtensions = 14,
2447 InvalidRdsLogicalReplication = 15,
2449 InvalidLoggingSetup = 16,
2451 InvalidDbParam = 17,
2453 UnsupportedGtidMode = 18,
2455 SqlserverAgentNotRunning = 19,
2457 UnsupportedTableDefinition = 20,
2461 UnsupportedDefiner = 21,
2463 SqlserverServernameMismatch = 22,
2465 PrimaryAlreadySetup = 23,
2467 UnsupportedBinlogFormat = 24,
2469 BinlogRetentionSetting = 25,
2471 UnsupportedStorageEngine = 26,
2473 LimitedSupportTables = 27,
2476 ExistingDataInReplica = 28,
2478 MissingOptionalPrivileges = 29,
2480 RiskyBackupAdminPrivilege = 30,
2483 InsufficientGcsPermissions = 31,
2485 InvalidFileInfo = 32,
2488 UnsupportedDatabaseSettings = 33,
2490 MysqlParallelImportInsufficientPrivilege = 34,
2493 LocalInfileOff = 35,
2495 TurnOnPitrAfterPromote = 36,
2498 IncompatibleDatabaseMinorVersion = 37,
2500 SourceMaxSubscriptions = 38,
2503 UnableToVerifyDefiners = 39,
2505 SubscriptionCalculationStatus = 40,
2508 PgSubscriptionCount = 41,
2511 PgSyncParallelLevel = 42,
2513 InsufficientDiskSize = 43,
2516 InsufficientMachineTier = 44,
2520 UnsupportedExtensionsNotMigrated = 45,
2523 ExtensionsNotMigrated = 46,
2526 PgCronFlagEnabledInReplica = 47,
2529 ExtensionsNotEnabledInReplica = 48,
2534 UnsupportedColumns = 49,
2537 UsersNotCreatedInReplica = 50,
2542 UnsupportedSystemObjects = 51,
2545 UnsupportedTablesWithReplicaIdentity = 52,
2549 SelectedObjectsNotExistOnSource = 53,
2551 PscOnlyInstanceWithNoNetworkAttachmentUri = 54,
2553 SelectedObjectsReferenceUnselectedObjects = 55,
2557 PromptDeleteExisting = 56,
2561 WillDeleteExisting = 57,
2566 PgDdlReplicationInsufficientPrivilege = 58,
2569 }
2570 impl SqlExternalSyncSettingErrorType {
2571 pub fn as_str_name(&self) -> &'static str {
2576 match self {
2577 Self::Unspecified => "SQL_EXTERNAL_SYNC_SETTING_ERROR_TYPE_UNSPECIFIED",
2578 Self::ConnectionFailure => "CONNECTION_FAILURE",
2579 Self::BinlogNotEnabled => "BINLOG_NOT_ENABLED",
2580 Self::IncompatibleDatabaseVersion => "INCOMPATIBLE_DATABASE_VERSION",
2581 Self::ReplicaAlreadySetup => "REPLICA_ALREADY_SETUP",
2582 Self::InsufficientPrivilege => "INSUFFICIENT_PRIVILEGE",
2583 Self::UnsupportedMigrationType => "UNSUPPORTED_MIGRATION_TYPE",
2584 Self::NoPglogicalInstalled => "NO_PGLOGICAL_INSTALLED",
2585 Self::PglogicalNodeAlreadyExists => "PGLOGICAL_NODE_ALREADY_EXISTS",
2586 Self::InvalidWalLevel => "INVALID_WAL_LEVEL",
2587 Self::InvalidSharedPreloadLibrary => "INVALID_SHARED_PRELOAD_LIBRARY",
2588 Self::InsufficientMaxReplicationSlots => {
2589 "INSUFFICIENT_MAX_REPLICATION_SLOTS"
2590 }
2591 Self::InsufficientMaxWalSenders => "INSUFFICIENT_MAX_WAL_SENDERS",
2592 Self::InsufficientMaxWorkerProcesses => {
2593 "INSUFFICIENT_MAX_WORKER_PROCESSES"
2594 }
2595 Self::UnsupportedExtensions => "UNSUPPORTED_EXTENSIONS",
2596 Self::InvalidRdsLogicalReplication => "INVALID_RDS_LOGICAL_REPLICATION",
2597 Self::InvalidLoggingSetup => "INVALID_LOGGING_SETUP",
2598 Self::InvalidDbParam => "INVALID_DB_PARAM",
2599 Self::UnsupportedGtidMode => "UNSUPPORTED_GTID_MODE",
2600 Self::SqlserverAgentNotRunning => "SQLSERVER_AGENT_NOT_RUNNING",
2601 Self::UnsupportedTableDefinition => "UNSUPPORTED_TABLE_DEFINITION",
2602 Self::UnsupportedDefiner => "UNSUPPORTED_DEFINER",
2603 Self::SqlserverServernameMismatch => "SQLSERVER_SERVERNAME_MISMATCH",
2604 Self::PrimaryAlreadySetup => "PRIMARY_ALREADY_SETUP",
2605 Self::UnsupportedBinlogFormat => "UNSUPPORTED_BINLOG_FORMAT",
2606 Self::BinlogRetentionSetting => "BINLOG_RETENTION_SETTING",
2607 Self::UnsupportedStorageEngine => "UNSUPPORTED_STORAGE_ENGINE",
2608 Self::LimitedSupportTables => "LIMITED_SUPPORT_TABLES",
2609 Self::ExistingDataInReplica => "EXISTING_DATA_IN_REPLICA",
2610 Self::MissingOptionalPrivileges => "MISSING_OPTIONAL_PRIVILEGES",
2611 Self::RiskyBackupAdminPrivilege => "RISKY_BACKUP_ADMIN_PRIVILEGE",
2612 Self::InsufficientGcsPermissions => "INSUFFICIENT_GCS_PERMISSIONS",
2613 Self::InvalidFileInfo => "INVALID_FILE_INFO",
2614 Self::UnsupportedDatabaseSettings => "UNSUPPORTED_DATABASE_SETTINGS",
2615 Self::MysqlParallelImportInsufficientPrivilege => {
2616 "MYSQL_PARALLEL_IMPORT_INSUFFICIENT_PRIVILEGE"
2617 }
2618 Self::LocalInfileOff => "LOCAL_INFILE_OFF",
2619 Self::TurnOnPitrAfterPromote => "TURN_ON_PITR_AFTER_PROMOTE",
2620 Self::IncompatibleDatabaseMinorVersion => {
2621 "INCOMPATIBLE_DATABASE_MINOR_VERSION"
2622 }
2623 Self::SourceMaxSubscriptions => "SOURCE_MAX_SUBSCRIPTIONS",
2624 Self::UnableToVerifyDefiners => "UNABLE_TO_VERIFY_DEFINERS",
2625 Self::SubscriptionCalculationStatus => "SUBSCRIPTION_CALCULATION_STATUS",
2626 Self::PgSubscriptionCount => "PG_SUBSCRIPTION_COUNT",
2627 Self::PgSyncParallelLevel => "PG_SYNC_PARALLEL_LEVEL",
2628 Self::InsufficientDiskSize => "INSUFFICIENT_DISK_SIZE",
2629 Self::InsufficientMachineTier => "INSUFFICIENT_MACHINE_TIER",
2630 Self::UnsupportedExtensionsNotMigrated => {
2631 "UNSUPPORTED_EXTENSIONS_NOT_MIGRATED"
2632 }
2633 Self::ExtensionsNotMigrated => "EXTENSIONS_NOT_MIGRATED",
2634 Self::PgCronFlagEnabledInReplica => "PG_CRON_FLAG_ENABLED_IN_REPLICA",
2635 Self::ExtensionsNotEnabledInReplica => {
2636 "EXTENSIONS_NOT_ENABLED_IN_REPLICA"
2637 }
2638 Self::UnsupportedColumns => "UNSUPPORTED_COLUMNS",
2639 Self::UsersNotCreatedInReplica => "USERS_NOT_CREATED_IN_REPLICA",
2640 Self::UnsupportedSystemObjects => "UNSUPPORTED_SYSTEM_OBJECTS",
2641 Self::UnsupportedTablesWithReplicaIdentity => {
2642 "UNSUPPORTED_TABLES_WITH_REPLICA_IDENTITY"
2643 }
2644 Self::SelectedObjectsNotExistOnSource => {
2645 "SELECTED_OBJECTS_NOT_EXIST_ON_SOURCE"
2646 }
2647 Self::PscOnlyInstanceWithNoNetworkAttachmentUri => {
2648 "PSC_ONLY_INSTANCE_WITH_NO_NETWORK_ATTACHMENT_URI"
2649 }
2650 Self::SelectedObjectsReferenceUnselectedObjects => {
2651 "SELECTED_OBJECTS_REFERENCE_UNSELECTED_OBJECTS"
2652 }
2653 Self::PromptDeleteExisting => "PROMPT_DELETE_EXISTING",
2654 Self::WillDeleteExisting => "WILL_DELETE_EXISTING",
2655 Self::PgDdlReplicationInsufficientPrivilege => {
2656 "PG_DDL_REPLICATION_INSUFFICIENT_PRIVILEGE"
2657 }
2658 }
2659 }
2660 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2662 match value {
2663 "SQL_EXTERNAL_SYNC_SETTING_ERROR_TYPE_UNSPECIFIED" => {
2664 Some(Self::Unspecified)
2665 }
2666 "CONNECTION_FAILURE" => Some(Self::ConnectionFailure),
2667 "BINLOG_NOT_ENABLED" => Some(Self::BinlogNotEnabled),
2668 "INCOMPATIBLE_DATABASE_VERSION" => {
2669 Some(Self::IncompatibleDatabaseVersion)
2670 }
2671 "REPLICA_ALREADY_SETUP" => Some(Self::ReplicaAlreadySetup),
2672 "INSUFFICIENT_PRIVILEGE" => Some(Self::InsufficientPrivilege),
2673 "UNSUPPORTED_MIGRATION_TYPE" => Some(Self::UnsupportedMigrationType),
2674 "NO_PGLOGICAL_INSTALLED" => Some(Self::NoPglogicalInstalled),
2675 "PGLOGICAL_NODE_ALREADY_EXISTS" => Some(Self::PglogicalNodeAlreadyExists),
2676 "INVALID_WAL_LEVEL" => Some(Self::InvalidWalLevel),
2677 "INVALID_SHARED_PRELOAD_LIBRARY" => {
2678 Some(Self::InvalidSharedPreloadLibrary)
2679 }
2680 "INSUFFICIENT_MAX_REPLICATION_SLOTS" => {
2681 Some(Self::InsufficientMaxReplicationSlots)
2682 }
2683 "INSUFFICIENT_MAX_WAL_SENDERS" => Some(Self::InsufficientMaxWalSenders),
2684 "INSUFFICIENT_MAX_WORKER_PROCESSES" => {
2685 Some(Self::InsufficientMaxWorkerProcesses)
2686 }
2687 "UNSUPPORTED_EXTENSIONS" => Some(Self::UnsupportedExtensions),
2688 "INVALID_RDS_LOGICAL_REPLICATION" => {
2689 Some(Self::InvalidRdsLogicalReplication)
2690 }
2691 "INVALID_LOGGING_SETUP" => Some(Self::InvalidLoggingSetup),
2692 "INVALID_DB_PARAM" => Some(Self::InvalidDbParam),
2693 "UNSUPPORTED_GTID_MODE" => Some(Self::UnsupportedGtidMode),
2694 "SQLSERVER_AGENT_NOT_RUNNING" => Some(Self::SqlserverAgentNotRunning),
2695 "UNSUPPORTED_TABLE_DEFINITION" => Some(Self::UnsupportedTableDefinition),
2696 "UNSUPPORTED_DEFINER" => Some(Self::UnsupportedDefiner),
2697 "SQLSERVER_SERVERNAME_MISMATCH" => {
2698 Some(Self::SqlserverServernameMismatch)
2699 }
2700 "PRIMARY_ALREADY_SETUP" => Some(Self::PrimaryAlreadySetup),
2701 "UNSUPPORTED_BINLOG_FORMAT" => Some(Self::UnsupportedBinlogFormat),
2702 "BINLOG_RETENTION_SETTING" => Some(Self::BinlogRetentionSetting),
2703 "UNSUPPORTED_STORAGE_ENGINE" => Some(Self::UnsupportedStorageEngine),
2704 "LIMITED_SUPPORT_TABLES" => Some(Self::LimitedSupportTables),
2705 "EXISTING_DATA_IN_REPLICA" => Some(Self::ExistingDataInReplica),
2706 "MISSING_OPTIONAL_PRIVILEGES" => Some(Self::MissingOptionalPrivileges),
2707 "RISKY_BACKUP_ADMIN_PRIVILEGE" => Some(Self::RiskyBackupAdminPrivilege),
2708 "INSUFFICIENT_GCS_PERMISSIONS" => Some(Self::InsufficientGcsPermissions),
2709 "INVALID_FILE_INFO" => Some(Self::InvalidFileInfo),
2710 "UNSUPPORTED_DATABASE_SETTINGS" => {
2711 Some(Self::UnsupportedDatabaseSettings)
2712 }
2713 "MYSQL_PARALLEL_IMPORT_INSUFFICIENT_PRIVILEGE" => {
2714 Some(Self::MysqlParallelImportInsufficientPrivilege)
2715 }
2716 "LOCAL_INFILE_OFF" => Some(Self::LocalInfileOff),
2717 "TURN_ON_PITR_AFTER_PROMOTE" => Some(Self::TurnOnPitrAfterPromote),
2718 "INCOMPATIBLE_DATABASE_MINOR_VERSION" => {
2719 Some(Self::IncompatibleDatabaseMinorVersion)
2720 }
2721 "SOURCE_MAX_SUBSCRIPTIONS" => Some(Self::SourceMaxSubscriptions),
2722 "UNABLE_TO_VERIFY_DEFINERS" => Some(Self::UnableToVerifyDefiners),
2723 "SUBSCRIPTION_CALCULATION_STATUS" => {
2724 Some(Self::SubscriptionCalculationStatus)
2725 }
2726 "PG_SUBSCRIPTION_COUNT" => Some(Self::PgSubscriptionCount),
2727 "PG_SYNC_PARALLEL_LEVEL" => Some(Self::PgSyncParallelLevel),
2728 "INSUFFICIENT_DISK_SIZE" => Some(Self::InsufficientDiskSize),
2729 "INSUFFICIENT_MACHINE_TIER" => Some(Self::InsufficientMachineTier),
2730 "UNSUPPORTED_EXTENSIONS_NOT_MIGRATED" => {
2731 Some(Self::UnsupportedExtensionsNotMigrated)
2732 }
2733 "EXTENSIONS_NOT_MIGRATED" => Some(Self::ExtensionsNotMigrated),
2734 "PG_CRON_FLAG_ENABLED_IN_REPLICA" => {
2735 Some(Self::PgCronFlagEnabledInReplica)
2736 }
2737 "EXTENSIONS_NOT_ENABLED_IN_REPLICA" => {
2738 Some(Self::ExtensionsNotEnabledInReplica)
2739 }
2740 "UNSUPPORTED_COLUMNS" => Some(Self::UnsupportedColumns),
2741 "USERS_NOT_CREATED_IN_REPLICA" => Some(Self::UsersNotCreatedInReplica),
2742 "UNSUPPORTED_SYSTEM_OBJECTS" => Some(Self::UnsupportedSystemObjects),
2743 "UNSUPPORTED_TABLES_WITH_REPLICA_IDENTITY" => {
2744 Some(Self::UnsupportedTablesWithReplicaIdentity)
2745 }
2746 "SELECTED_OBJECTS_NOT_EXIST_ON_SOURCE" => {
2747 Some(Self::SelectedObjectsNotExistOnSource)
2748 }
2749 "PSC_ONLY_INSTANCE_WITH_NO_NETWORK_ATTACHMENT_URI" => {
2750 Some(Self::PscOnlyInstanceWithNoNetworkAttachmentUri)
2751 }
2752 "SELECTED_OBJECTS_REFERENCE_UNSELECTED_OBJECTS" => {
2753 Some(Self::SelectedObjectsReferenceUnselectedObjects)
2754 }
2755 "PROMPT_DELETE_EXISTING" => Some(Self::PromptDeleteExisting),
2756 "WILL_DELETE_EXISTING" => Some(Self::WillDeleteExisting),
2757 "PG_DDL_REPLICATION_INSUFFICIENT_PRIVILEGE" => {
2758 Some(Self::PgDdlReplicationInsufficientPrivilege)
2759 }
2760 _ => None,
2761 }
2762 }
2763 }
2764}
2765#[derive(Clone, PartialEq, ::prost::Message)]
2767pub struct IpConfiguration {
2768 #[prost(message, optional, tag = "1")]
2770 pub ipv4_enabled: ::core::option::Option<bool>,
2771 #[prost(string, tag = "2")]
2776 pub private_network: ::prost::alloc::string::String,
2777 #[prost(message, optional, tag = "3")]
2787 pub require_ssl: ::core::option::Option<bool>,
2788 #[prost(message, repeated, tag = "4")]
2792 pub authorized_networks: ::prost::alloc::vec::Vec<AclEntry>,
2793 #[prost(string, tag = "6")]
2800 pub allocated_ip_range: ::prost::alloc::string::String,
2801 #[prost(message, optional, tag = "7")]
2804 pub enable_private_path_for_google_cloud_services: ::core::option::Option<bool>,
2805 #[prost(enumeration = "ip_configuration::SslMode", tag = "8")]
2828 pub ssl_mode: i32,
2829 #[prost(message, optional, tag = "9")]
2831 pub psc_config: ::core::option::Option<PscConfig>,
2832 #[prost(enumeration = "ip_configuration::CaMode", optional, tag = "10")]
2834 pub server_ca_mode: ::core::option::Option<i32>,
2835 #[prost(string, repeated, tag = "11")]
2837 pub custom_subject_alternative_names: ::prost::alloc::vec::Vec<
2838 ::prost::alloc::string::String,
2839 >,
2840 #[prost(string, optional, tag = "12")]
2844 pub server_ca_pool: ::core::option::Option<::prost::alloc::string::String>,
2845 #[prost(
2852 enumeration = "ip_configuration::ServerCertificateRotationMode",
2853 optional,
2854 tag = "16"
2855 )]
2856 pub server_certificate_rotation_mode: ::core::option::Option<i32>,
2857}
2858pub mod ip_configuration {
2860 #[derive(
2862 Clone,
2863 Copy,
2864 Debug,
2865 PartialEq,
2866 Eq,
2867 Hash,
2868 PartialOrd,
2869 Ord,
2870 ::prost::Enumeration
2871 )]
2872 #[repr(i32)]
2873 pub enum SslMode {
2874 Unspecified = 0,
2876 AllowUnencryptedAndEncrypted = 1,
2883 EncryptedOnly = 2,
2890 TrustedClientCertificateRequired = 3,
2905 }
2906 impl SslMode {
2907 pub fn as_str_name(&self) -> &'static str {
2912 match self {
2913 Self::Unspecified => "SSL_MODE_UNSPECIFIED",
2914 Self::AllowUnencryptedAndEncrypted => "ALLOW_UNENCRYPTED_AND_ENCRYPTED",
2915 Self::EncryptedOnly => "ENCRYPTED_ONLY",
2916 Self::TrustedClientCertificateRequired => {
2917 "TRUSTED_CLIENT_CERTIFICATE_REQUIRED"
2918 }
2919 }
2920 }
2921 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2923 match value {
2924 "SSL_MODE_UNSPECIFIED" => Some(Self::Unspecified),
2925 "ALLOW_UNENCRYPTED_AND_ENCRYPTED" => {
2926 Some(Self::AllowUnencryptedAndEncrypted)
2927 }
2928 "ENCRYPTED_ONLY" => Some(Self::EncryptedOnly),
2929 "TRUSTED_CLIENT_CERTIFICATE_REQUIRED" => {
2930 Some(Self::TrustedClientCertificateRequired)
2931 }
2932 _ => None,
2933 }
2934 }
2935 }
2936 #[derive(
2938 Clone,
2939 Copy,
2940 Debug,
2941 PartialEq,
2942 Eq,
2943 Hash,
2944 PartialOrd,
2945 Ord,
2946 ::prost::Enumeration
2947 )]
2948 #[repr(i32)]
2949 pub enum CaMode {
2950 Unspecified = 0,
2953 GoogleManagedInternalCa = 1,
2955 GoogleManagedCasCa = 2,
2958 CustomerManagedCasCa = 3,
2961 }
2962 impl CaMode {
2963 pub fn as_str_name(&self) -> &'static str {
2968 match self {
2969 Self::Unspecified => "CA_MODE_UNSPECIFIED",
2970 Self::GoogleManagedInternalCa => "GOOGLE_MANAGED_INTERNAL_CA",
2971 Self::GoogleManagedCasCa => "GOOGLE_MANAGED_CAS_CA",
2972 Self::CustomerManagedCasCa => "CUSTOMER_MANAGED_CAS_CA",
2973 }
2974 }
2975 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2977 match value {
2978 "CA_MODE_UNSPECIFIED" => Some(Self::Unspecified),
2979 "GOOGLE_MANAGED_INTERNAL_CA" => Some(Self::GoogleManagedInternalCa),
2980 "GOOGLE_MANAGED_CAS_CA" => Some(Self::GoogleManagedCasCa),
2981 "CUSTOMER_MANAGED_CAS_CA" => Some(Self::CustomerManagedCasCa),
2982 _ => None,
2983 }
2984 }
2985 }
2986 #[derive(
2988 Clone,
2989 Copy,
2990 Debug,
2991 PartialEq,
2992 Eq,
2993 Hash,
2994 PartialOrd,
2995 Ord,
2996 ::prost::Enumeration
2997 )]
2998 #[repr(i32)]
2999 pub enum ServerCertificateRotationMode {
3000 Unspecified = 0,
3002 NoAutomaticRotation = 1,
3007 AutomaticRotationDuringMaintenance = 2,
3012 }
3013 impl ServerCertificateRotationMode {
3014 pub fn as_str_name(&self) -> &'static str {
3019 match self {
3020 Self::Unspecified => "SERVER_CERTIFICATE_ROTATION_MODE_UNSPECIFIED",
3021 Self::NoAutomaticRotation => "NO_AUTOMATIC_ROTATION",
3022 Self::AutomaticRotationDuringMaintenance => {
3023 "AUTOMATIC_ROTATION_DURING_MAINTENANCE"
3024 }
3025 }
3026 }
3027 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3029 match value {
3030 "SERVER_CERTIFICATE_ROTATION_MODE_UNSPECIFIED" => Some(Self::Unspecified),
3031 "NO_AUTOMATIC_ROTATION" => Some(Self::NoAutomaticRotation),
3032 "AUTOMATIC_ROTATION_DURING_MAINTENANCE" => {
3033 Some(Self::AutomaticRotationDuringMaintenance)
3034 }
3035 _ => None,
3036 }
3037 }
3038 }
3039}
3040#[derive(Clone, PartialEq, ::prost::Message)]
3042pub struct PscConfig {
3043 #[prost(bool, optional, tag = "1")]
3045 pub psc_enabled: ::core::option::Option<bool>,
3046 #[prost(string, repeated, tag = "2")]
3053 pub allowed_consumer_projects: ::prost::alloc::vec::Vec<
3054 ::prost::alloc::string::String,
3055 >,
3056 #[prost(message, repeated, tag = "3")]
3059 pub psc_auto_connections: ::prost::alloc::vec::Vec<PscAutoConnectionConfig>,
3060 #[prost(string, tag = "4")]
3065 pub network_attachment_uri: ::prost::alloc::string::String,
3066}
3067#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3070pub struct PscAutoConnectionConfig {
3071 #[prost(string, tag = "1")]
3077 pub consumer_project: ::prost::alloc::string::String,
3078 #[prost(string, tag = "2")]
3086 pub consumer_network: ::prost::alloc::string::String,
3087 #[prost(string, optional, tag = "3")]
3089 pub ip_address: ::core::option::Option<::prost::alloc::string::String>,
3090 #[prost(string, optional, tag = "4")]
3092 pub status: ::core::option::Option<::prost::alloc::string::String>,
3093 #[prost(string, optional, tag = "5")]
3095 pub consumer_network_status: ::core::option::Option<::prost::alloc::string::String>,
3096}
3097#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3099pub struct IpMapping {
3100 #[prost(enumeration = "SqlIpAddressType", tag = "1")]
3105 pub r#type: i32,
3106 #[prost(string, tag = "2")]
3108 pub ip_address: ::prost::alloc::string::String,
3109 #[prost(message, optional, tag = "3")]
3114 pub time_to_retire: ::core::option::Option<::prost_types::Timestamp>,
3115}
3116#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3121pub struct LocationPreference {
3122 #[deprecated]
3125 #[prost(string, tag = "1")]
3126 pub follow_gae_application: ::prost::alloc::string::String,
3127 #[prost(string, tag = "2")]
3130 pub zone: ::prost::alloc::string::String,
3131 #[prost(string, tag = "4")]
3135 pub secondary_zone: ::prost::alloc::string::String,
3136 #[prost(string, tag = "3")]
3138 pub kind: ::prost::alloc::string::String,
3139}
3140#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3143pub struct MaintenanceWindow {
3144 #[prost(message, optional, tag = "1")]
3146 pub hour: ::core::option::Option<i32>,
3147 #[prost(message, optional, tag = "2")]
3151 pub day: ::core::option::Option<i32>,
3152 #[prost(enumeration = "SqlUpdateTrack", tag = "3")]
3156 pub update_track: i32,
3157 #[prost(string, tag = "4")]
3159 pub kind: ::prost::alloc::string::String,
3160}
3161#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3164pub struct DenyMaintenancePeriod {
3165 #[prost(string, tag = "1")]
3170 pub start_date: ::prost::alloc::string::String,
3171 #[prost(string, tag = "2")]
3176 pub end_date: ::prost::alloc::string::String,
3177 #[prost(string, tag = "3")]
3180 pub time: ::prost::alloc::string::String,
3181}
3182#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
3185pub struct InsightsConfig {
3186 #[prost(bool, tag = "1")]
3188 pub query_insights_enabled: bool,
3189 #[prost(bool, tag = "2")]
3191 pub record_client_address: bool,
3192 #[prost(bool, tag = "3")]
3195 pub record_application_tags: bool,
3196 #[prost(message, optional, tag = "4")]
3201 pub query_string_length: ::core::option::Option<i32>,
3202 #[prost(message, optional, tag = "5")]
3205 pub query_plans_per_minute: ::core::option::Option<i32>,
3206 #[prost(message, optional, tag = "8")]
3208 pub enhanced_query_insights_enabled: ::core::option::Option<bool>,
3209}
3210#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3212pub struct MySqlReplicaConfiguration {
3213 #[prost(string, tag = "1")]
3220 pub dump_file_path: ::prost::alloc::string::String,
3221 #[prost(string, tag = "2")]
3223 pub username: ::prost::alloc::string::String,
3224 #[prost(string, tag = "3")]
3226 pub password: ::prost::alloc::string::String,
3227 #[prost(message, optional, tag = "4")]
3229 pub connect_retry_interval: ::core::option::Option<i32>,
3230 #[prost(message, optional, tag = "5")]
3232 pub master_heartbeat_period: ::core::option::Option<i64>,
3233 #[prost(string, tag = "6")]
3235 pub ca_certificate: ::prost::alloc::string::String,
3236 #[prost(string, tag = "7")]
3238 pub client_certificate: ::prost::alloc::string::String,
3239 #[prost(string, tag = "8")]
3242 pub client_key: ::prost::alloc::string::String,
3243 #[prost(string, tag = "9")]
3245 pub ssl_cipher: ::prost::alloc::string::String,
3246 #[prost(message, optional, tag = "10")]
3249 pub verify_server_certificate: ::core::option::Option<bool>,
3250 #[prost(string, tag = "11")]
3252 pub kind: ::prost::alloc::string::String,
3253}
3254#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3257pub struct SelectedObjects {
3258 #[prost(string, tag = "1")]
3260 pub database: ::prost::alloc::string::String,
3261}
3262#[derive(Clone, PartialEq, ::prost::Message)]
3264pub struct OnPremisesConfiguration {
3265 #[prost(string, tag = "1")]
3267 pub host_port: ::prost::alloc::string::String,
3268 #[prost(string, tag = "2")]
3270 pub kind: ::prost::alloc::string::String,
3271 #[prost(string, tag = "3")]
3273 pub username: ::prost::alloc::string::String,
3274 #[prost(string, tag = "4")]
3276 pub password: ::prost::alloc::string::String,
3277 #[prost(string, tag = "5")]
3279 pub ca_certificate: ::prost::alloc::string::String,
3280 #[prost(string, tag = "6")]
3282 pub client_certificate: ::prost::alloc::string::String,
3283 #[prost(string, tag = "7")]
3286 pub client_key: ::prost::alloc::string::String,
3287 #[prost(string, tag = "8")]
3289 pub dump_file_path: ::prost::alloc::string::String,
3290 #[prost(message, optional, tag = "15")]
3292 pub source_instance: ::core::option::Option<InstanceReference>,
3293 #[prost(message, repeated, tag = "16")]
3296 pub selected_objects: ::prost::alloc::vec::Vec<SelectedObjects>,
3297 #[prost(enumeration = "on_premises_configuration::SslOption", tag = "18")]
3299 pub ssl_option: i32,
3300}
3301pub mod on_premises_configuration {
3303 #[derive(
3306 Clone,
3307 Copy,
3308 Debug,
3309 PartialEq,
3310 Eq,
3311 Hash,
3312 PartialOrd,
3313 Ord,
3314 ::prost::Enumeration
3315 )]
3316 #[repr(i32)]
3317 pub enum SslOption {
3318 Unspecified = 0,
3320 Disable = 1,
3322 Require = 2,
3324 VerifyCa = 3,
3326 }
3327 impl SslOption {
3328 pub fn as_str_name(&self) -> &'static str {
3333 match self {
3334 Self::Unspecified => "SSL_OPTION_UNSPECIFIED",
3335 Self::Disable => "DISABLE",
3336 Self::Require => "REQUIRE",
3337 Self::VerifyCa => "VERIFY_CA",
3338 }
3339 }
3340 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3342 match value {
3343 "SSL_OPTION_UNSPECIFIED" => Some(Self::Unspecified),
3344 "DISABLE" => Some(Self::Disable),
3345 "REQUIRE" => Some(Self::Require),
3346 "VERIFY_CA" => Some(Self::VerifyCa),
3347 _ => None,
3348 }
3349 }
3350 }
3351}
3352#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3354pub struct DiskEncryptionConfiguration {
3355 #[prost(string, tag = "1")]
3357 pub kms_key_name: ::prost::alloc::string::String,
3358 #[prost(string, tag = "2")]
3360 pub kind: ::prost::alloc::string::String,
3361}
3362#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3364pub struct DiskEncryptionStatus {
3365 #[prost(string, tag = "1")]
3367 pub kms_key_version_name: ::prost::alloc::string::String,
3368 #[prost(string, tag = "2")]
3370 pub kind: ::prost::alloc::string::String,
3371}
3372#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
3374pub struct SqlSubOperationType {
3375 #[prost(oneof = "sql_sub_operation_type::SubOperationDetails", tags = "1")]
3377 pub sub_operation_details: ::core::option::Option<
3378 sql_sub_operation_type::SubOperationDetails,
3379 >,
3380}
3381pub mod sql_sub_operation_type {
3383 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
3385 pub enum SubOperationDetails {
3386 #[prost(enumeration = "super::SqlMaintenanceType", tag = "1")]
3388 MaintenanceType(i32),
3389 }
3390}
3391#[derive(Clone, PartialEq, ::prost::Message)]
3395pub struct Operation {
3396 #[prost(string, tag = "1")]
3398 pub kind: ::prost::alloc::string::String,
3399 #[prost(string, tag = "2")]
3400 pub target_link: ::prost::alloc::string::String,
3401 #[prost(enumeration = "operation::SqlOperationStatus", tag = "3")]
3403 pub status: i32,
3404 #[prost(string, tag = "4")]
3406 pub user: ::prost::alloc::string::String,
3407 #[prost(message, optional, tag = "5")]
3411 pub insert_time: ::core::option::Option<::prost_types::Timestamp>,
3412 #[prost(message, optional, tag = "6")]
3416 pub start_time: ::core::option::Option<::prost_types::Timestamp>,
3417 #[prost(message, optional, tag = "7")]
3421 pub end_time: ::core::option::Option<::prost_types::Timestamp>,
3422 #[prost(message, optional, tag = "8")]
3425 pub error: ::core::option::Option<OperationErrors>,
3426 #[prost(message, optional, tag = "19")]
3428 pub api_warning: ::core::option::Option<ApiWarning>,
3429 #[prost(enumeration = "operation::SqlOperationType", tag = "9")]
3444 pub operation_type: i32,
3445 #[prost(message, optional, tag = "10")]
3447 pub import_context: ::core::option::Option<ImportContext>,
3448 #[prost(message, optional, tag = "11")]
3450 pub export_context: ::core::option::Option<ExportContext>,
3451 #[prost(message, optional, tag = "17")]
3453 pub backup_context: ::core::option::Option<BackupContext>,
3454 #[prost(message, optional, tag = "50")]
3461 pub pre_check_major_version_upgrade_context: ::core::option::Option<
3462 PreCheckMajorVersionUpgradeContext,
3463 >,
3464 #[prost(string, tag = "12")]
3468 pub name: ::prost::alloc::string::String,
3469 #[prost(string, tag = "13")]
3471 pub target_id: ::prost::alloc::string::String,
3472 #[prost(string, tag = "14")]
3474 pub self_link: ::prost::alloc::string::String,
3475 #[prost(string, tag = "15")]
3477 pub target_project: ::prost::alloc::string::String,
3478 #[prost(message, optional, tag = "20")]
3480 pub acquire_ssrs_lease_context: ::core::option::Option<AcquireSsrsLeaseContext>,
3481 #[prost(message, optional, tag = "48")]
3483 pub sub_operation_type: ::core::option::Option<SqlSubOperationType>,
3484}
3485pub mod operation {
3487 #[derive(
3489 Clone,
3490 Copy,
3491 Debug,
3492 PartialEq,
3493 Eq,
3494 Hash,
3495 PartialOrd,
3496 Ord,
3497 ::prost::Enumeration
3498 )]
3499 #[repr(i32)]
3500 pub enum SqlOperationType {
3501 Unspecified = 0,
3503 Import = 1,
3505 Export = 2,
3508 Create = 3,
3510 Update = 4,
3512 Delete = 5,
3514 Restart = 6,
3516 #[deprecated]
3517 Backup = 7,
3518 #[deprecated]
3519 Snapshot = 8,
3520 BackupVolume = 9,
3522 DeleteVolume = 10,
3524 RestoreVolume = 11,
3526 InjectUser = 12,
3528 Clone = 14,
3530 StopReplica = 15,
3532 StartReplica = 16,
3534 PromoteReplica = 17,
3536 CreateReplica = 18,
3538 CreateUser = 19,
3540 DeleteUser = 20,
3542 UpdateUser = 21,
3545 CreateDatabase = 22,
3547 DeleteDatabase = 23,
3549 UpdateDatabase = 24,
3551 Failover = 25,
3554 DeleteBackup = 26,
3556 RecreateReplica = 27,
3557 TruncateLog = 28,
3559 DemoteMaster = 29,
3562 Maintenance = 30,
3565 #[deprecated]
3567 EnablePrivateIp = 31,
3568 #[deprecated]
3569 DeferMaintenance = 32,
3570 #[deprecated]
3572 CreateClone = 33,
3573 RescheduleMaintenance = 34,
3575 StartExternalSync = 35,
3578 LogCleanup = 36,
3580 AutoRestart = 37,
3583 Reencrypt = 38,
3585 Switchover = 39,
3588 UpdateBackup = 40,
3590 AcquireSsrsLease = 42,
3592 ReleaseSsrsLease = 43,
3594 ReconfigureOldPrimary = 44,
3599 #[deprecated]
3605 ClusterMaintenance = 45,
3606 #[deprecated]
3611 SelfServiceMaintenance = 46,
3612 SwitchoverToReplica = 47,
3615 MajorVersionUpgrade = 48,
3617 #[deprecated]
3619 AdvancedBackup = 49,
3620 ManageBackup = 50,
3622 EnhancedBackup = 51,
3624 RepairReadPool = 52,
3626 CreateReadPool = 53,
3628 }
3629 impl SqlOperationType {
3630 pub fn as_str_name(&self) -> &'static str {
3635 match self {
3636 Self::Unspecified => "SQL_OPERATION_TYPE_UNSPECIFIED",
3637 Self::Import => "IMPORT",
3638 Self::Export => "EXPORT",
3639 Self::Create => "CREATE",
3640 Self::Update => "UPDATE",
3641 Self::Delete => "DELETE",
3642 Self::Restart => "RESTART",
3643 #[allow(deprecated)]
3644 Self::Backup => "BACKUP",
3645 #[allow(deprecated)]
3646 Self::Snapshot => "SNAPSHOT",
3647 Self::BackupVolume => "BACKUP_VOLUME",
3648 Self::DeleteVolume => "DELETE_VOLUME",
3649 Self::RestoreVolume => "RESTORE_VOLUME",
3650 Self::InjectUser => "INJECT_USER",
3651 Self::Clone => "CLONE",
3652 Self::StopReplica => "STOP_REPLICA",
3653 Self::StartReplica => "START_REPLICA",
3654 Self::PromoteReplica => "PROMOTE_REPLICA",
3655 Self::CreateReplica => "CREATE_REPLICA",
3656 Self::CreateUser => "CREATE_USER",
3657 Self::DeleteUser => "DELETE_USER",
3658 Self::UpdateUser => "UPDATE_USER",
3659 Self::CreateDatabase => "CREATE_DATABASE",
3660 Self::DeleteDatabase => "DELETE_DATABASE",
3661 Self::UpdateDatabase => "UPDATE_DATABASE",
3662 Self::Failover => "FAILOVER",
3663 Self::DeleteBackup => "DELETE_BACKUP",
3664 Self::RecreateReplica => "RECREATE_REPLICA",
3665 Self::TruncateLog => "TRUNCATE_LOG",
3666 Self::DemoteMaster => "DEMOTE_MASTER",
3667 Self::Maintenance => "MAINTENANCE",
3668 #[allow(deprecated)]
3669 Self::EnablePrivateIp => "ENABLE_PRIVATE_IP",
3670 #[allow(deprecated)]
3671 Self::DeferMaintenance => "DEFER_MAINTENANCE",
3672 #[allow(deprecated)]
3673 Self::CreateClone => "CREATE_CLONE",
3674 Self::RescheduleMaintenance => "RESCHEDULE_MAINTENANCE",
3675 Self::StartExternalSync => "START_EXTERNAL_SYNC",
3676 Self::LogCleanup => "LOG_CLEANUP",
3677 Self::AutoRestart => "AUTO_RESTART",
3678 Self::Reencrypt => "REENCRYPT",
3679 Self::Switchover => "SWITCHOVER",
3680 Self::UpdateBackup => "UPDATE_BACKUP",
3681 Self::AcquireSsrsLease => "ACQUIRE_SSRS_LEASE",
3682 Self::ReleaseSsrsLease => "RELEASE_SSRS_LEASE",
3683 Self::ReconfigureOldPrimary => "RECONFIGURE_OLD_PRIMARY",
3684 #[allow(deprecated)]
3685 Self::ClusterMaintenance => "CLUSTER_MAINTENANCE",
3686 #[allow(deprecated)]
3687 Self::SelfServiceMaintenance => "SELF_SERVICE_MAINTENANCE",
3688 Self::SwitchoverToReplica => "SWITCHOVER_TO_REPLICA",
3689 Self::MajorVersionUpgrade => "MAJOR_VERSION_UPGRADE",
3690 #[allow(deprecated)]
3691 Self::AdvancedBackup => "ADVANCED_BACKUP",
3692 Self::ManageBackup => "MANAGE_BACKUP",
3693 Self::EnhancedBackup => "ENHANCED_BACKUP",
3694 Self::RepairReadPool => "REPAIR_READ_POOL",
3695 Self::CreateReadPool => "CREATE_READ_POOL",
3696 }
3697 }
3698 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3700 match value {
3701 "SQL_OPERATION_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
3702 "IMPORT" => Some(Self::Import),
3703 "EXPORT" => Some(Self::Export),
3704 "CREATE" => Some(Self::Create),
3705 "UPDATE" => Some(Self::Update),
3706 "DELETE" => Some(Self::Delete),
3707 "RESTART" => Some(Self::Restart),
3708 "BACKUP" => Some(#[allow(deprecated)] Self::Backup),
3709 "SNAPSHOT" => Some(#[allow(deprecated)] Self::Snapshot),
3710 "BACKUP_VOLUME" => Some(Self::BackupVolume),
3711 "DELETE_VOLUME" => Some(Self::DeleteVolume),
3712 "RESTORE_VOLUME" => Some(Self::RestoreVolume),
3713 "INJECT_USER" => Some(Self::InjectUser),
3714 "CLONE" => Some(Self::Clone),
3715 "STOP_REPLICA" => Some(Self::StopReplica),
3716 "START_REPLICA" => Some(Self::StartReplica),
3717 "PROMOTE_REPLICA" => Some(Self::PromoteReplica),
3718 "CREATE_REPLICA" => Some(Self::CreateReplica),
3719 "CREATE_USER" => Some(Self::CreateUser),
3720 "DELETE_USER" => Some(Self::DeleteUser),
3721 "UPDATE_USER" => Some(Self::UpdateUser),
3722 "CREATE_DATABASE" => Some(Self::CreateDatabase),
3723 "DELETE_DATABASE" => Some(Self::DeleteDatabase),
3724 "UPDATE_DATABASE" => Some(Self::UpdateDatabase),
3725 "FAILOVER" => Some(Self::Failover),
3726 "DELETE_BACKUP" => Some(Self::DeleteBackup),
3727 "RECREATE_REPLICA" => Some(Self::RecreateReplica),
3728 "TRUNCATE_LOG" => Some(Self::TruncateLog),
3729 "DEMOTE_MASTER" => Some(Self::DemoteMaster),
3730 "MAINTENANCE" => Some(Self::Maintenance),
3731 "ENABLE_PRIVATE_IP" => Some(#[allow(deprecated)] Self::EnablePrivateIp),
3732 "DEFER_MAINTENANCE" => Some(#[allow(deprecated)] Self::DeferMaintenance),
3733 "CREATE_CLONE" => Some(#[allow(deprecated)] Self::CreateClone),
3734 "RESCHEDULE_MAINTENANCE" => Some(Self::RescheduleMaintenance),
3735 "START_EXTERNAL_SYNC" => Some(Self::StartExternalSync),
3736 "LOG_CLEANUP" => Some(Self::LogCleanup),
3737 "AUTO_RESTART" => Some(Self::AutoRestart),
3738 "REENCRYPT" => Some(Self::Reencrypt),
3739 "SWITCHOVER" => Some(Self::Switchover),
3740 "UPDATE_BACKUP" => Some(Self::UpdateBackup),
3741 "ACQUIRE_SSRS_LEASE" => Some(Self::AcquireSsrsLease),
3742 "RELEASE_SSRS_LEASE" => Some(Self::ReleaseSsrsLease),
3743 "RECONFIGURE_OLD_PRIMARY" => Some(Self::ReconfigureOldPrimary),
3744 "CLUSTER_MAINTENANCE" => {
3745 Some(#[allow(deprecated)] Self::ClusterMaintenance)
3746 }
3747 "SELF_SERVICE_MAINTENANCE" => {
3748 Some(#[allow(deprecated)] Self::SelfServiceMaintenance)
3749 }
3750 "SWITCHOVER_TO_REPLICA" => Some(Self::SwitchoverToReplica),
3751 "MAJOR_VERSION_UPGRADE" => Some(Self::MajorVersionUpgrade),
3752 "ADVANCED_BACKUP" => Some(#[allow(deprecated)] Self::AdvancedBackup),
3753 "MANAGE_BACKUP" => Some(Self::ManageBackup),
3754 "ENHANCED_BACKUP" => Some(Self::EnhancedBackup),
3755 "REPAIR_READ_POOL" => Some(Self::RepairReadPool),
3756 "CREATE_READ_POOL" => Some(Self::CreateReadPool),
3757 _ => None,
3758 }
3759 }
3760 }
3761 #[derive(
3763 Clone,
3764 Copy,
3765 Debug,
3766 PartialEq,
3767 Eq,
3768 Hash,
3769 PartialOrd,
3770 Ord,
3771 ::prost::Enumeration
3772 )]
3773 #[repr(i32)]
3774 pub enum SqlOperationStatus {
3775 Unspecified = 0,
3777 Pending = 1,
3779 Running = 2,
3781 Done = 3,
3783 }
3784 impl SqlOperationStatus {
3785 pub fn as_str_name(&self) -> &'static str {
3790 match self {
3791 Self::Unspecified => "SQL_OPERATION_STATUS_UNSPECIFIED",
3792 Self::Pending => "PENDING",
3793 Self::Running => "RUNNING",
3794 Self::Done => "DONE",
3795 }
3796 }
3797 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3799 match value {
3800 "SQL_OPERATION_STATUS_UNSPECIFIED" => Some(Self::Unspecified),
3801 "PENDING" => Some(Self::Pending),
3802 "RUNNING" => Some(Self::Running),
3803 "DONE" => Some(Self::Done),
3804 _ => None,
3805 }
3806 }
3807 }
3808}
3809#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3811pub struct OperationError {
3812 #[prost(string, tag = "1")]
3814 pub kind: ::prost::alloc::string::String,
3815 #[prost(string, tag = "2")]
3817 pub code: ::prost::alloc::string::String,
3818 #[prost(string, tag = "3")]
3820 pub message: ::prost::alloc::string::String,
3821}
3822#[derive(Clone, PartialEq, ::prost::Message)]
3824pub struct OperationErrors {
3825 #[prost(string, tag = "1")]
3827 pub kind: ::prost::alloc::string::String,
3828 #[prost(message, repeated, tag = "2")]
3830 pub errors: ::prost::alloc::vec::Vec<OperationError>,
3831}
3832#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
3837pub struct PasswordValidationPolicy {
3838 #[prost(message, optional, tag = "1")]
3840 pub min_length: ::core::option::Option<i32>,
3841 #[prost(enumeration = "password_validation_policy::Complexity", tag = "2")]
3843 pub complexity: i32,
3844 #[prost(message, optional, tag = "3")]
3846 pub reuse_interval: ::core::option::Option<i32>,
3847 #[prost(message, optional, tag = "4")]
3849 pub disallow_username_substring: ::core::option::Option<bool>,
3850 #[prost(message, optional, tag = "5")]
3853 pub password_change_interval: ::core::option::Option<::prost_types::Duration>,
3854 #[prost(message, optional, tag = "6")]
3858 pub enable_password_policy: ::core::option::Option<bool>,
3859 #[deprecated]
3862 #[prost(message, optional, tag = "7")]
3863 pub disallow_compromised_credentials: ::core::option::Option<bool>,
3864}
3865pub mod password_validation_policy {
3867 #[derive(
3869 Clone,
3870 Copy,
3871 Debug,
3872 PartialEq,
3873 Eq,
3874 Hash,
3875 PartialOrd,
3876 Ord,
3877 ::prost::Enumeration
3878 )]
3879 #[repr(i32)]
3880 pub enum Complexity {
3881 Unspecified = 0,
3883 Default = 1,
3886 }
3887 impl Complexity {
3888 pub fn as_str_name(&self) -> &'static str {
3893 match self {
3894 Self::Unspecified => "COMPLEXITY_UNSPECIFIED",
3895 Self::Default => "COMPLEXITY_DEFAULT",
3896 }
3897 }
3898 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
3900 match value {
3901 "COMPLEXITY_UNSPECIFIED" => Some(Self::Unspecified),
3902 "COMPLEXITY_DEFAULT" => Some(Self::Default),
3903 _ => None,
3904 }
3905 }
3906 }
3907}
3908#[derive(Clone, PartialEq, ::prost::Message)]
3910pub struct OperationsListResponse {
3911 #[prost(string, tag = "1")]
3913 pub kind: ::prost::alloc::string::String,
3914 #[prost(message, repeated, tag = "2")]
3916 pub items: ::prost::alloc::vec::Vec<Operation>,
3917 #[prost(string, tag = "3")]
3920 pub next_page_token: ::prost::alloc::string::String,
3921}
3922#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3924pub struct ReplicaConfiguration {
3925 #[prost(string, tag = "1")]
3927 pub kind: ::prost::alloc::string::String,
3928 #[prost(message, optional, tag = "2")]
3935 pub mysql_replica_configuration: ::core::option::Option<MySqlReplicaConfiguration>,
3936 #[prost(message, optional, tag = "3")]
3942 pub failover_target: ::core::option::Option<bool>,
3943 #[prost(message, optional, tag = "5")]
3947 pub cascadable_replica: ::core::option::Option<bool>,
3948}
3949#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3952pub struct RestoreBackupContext {
3953 #[prost(string, tag = "1")]
3955 pub kind: ::prost::alloc::string::String,
3956 #[prost(int64, tag = "2")]
3958 pub backup_run_id: i64,
3959 #[prost(string, tag = "3")]
3961 pub instance_id: ::prost::alloc::string::String,
3962 #[prost(string, tag = "4")]
3964 pub project: ::prost::alloc::string::String,
3965}
3966#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3968pub struct RotateServerCaContext {
3969 #[prost(string, tag = "1")]
3971 pub kind: ::prost::alloc::string::String,
3972 #[prost(string, tag = "2")]
3975 pub next_version: ::prost::alloc::string::String,
3976}
3977#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3979pub struct RotateServerCertificateContext {
3980 #[prost(string, tag = "1")]
3982 pub kind: ::prost::alloc::string::String,
3983 #[prost(string, tag = "2")]
3987 pub next_version: ::prost::alloc::string::String,
3988}
3989#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
3991pub struct RotateEntraIdCertificateContext {
3992 #[prost(string, tag = "1")]
3994 pub kind: ::prost::alloc::string::String,
3995 #[prost(string, tag = "2")]
3999 pub next_version: ::prost::alloc::string::String,
4000}
4001#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4003pub struct DataCacheConfig {
4004 #[prost(bool, tag = "1")]
4006 pub data_cache_enabled: bool,
4007}
4008#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4010pub struct FinalBackupConfig {
4011 #[prost(bool, optional, tag = "1")]
4013 pub enabled: ::core::option::Option<bool>,
4014 #[prost(int32, optional, tag = "3")]
4018 pub retention_days: ::core::option::Option<i32>,
4019}
4020#[derive(Clone, PartialEq, ::prost::Message)]
4022pub struct Settings {
4023 #[prost(message, optional, tag = "1")]
4028 pub settings_version: ::core::option::Option<i64>,
4029 #[deprecated]
4032 #[prost(string, repeated, tag = "2")]
4033 pub authorized_gae_applications: ::prost::alloc::vec::Vec<
4034 ::prost::alloc::string::String,
4035 >,
4036 #[prost(string, tag = "3")]
4039 pub tier: ::prost::alloc::string::String,
4040 #[prost(string, tag = "4")]
4042 pub kind: ::prost::alloc::string::String,
4043 #[prost(map = "string, string", tag = "5")]
4046 pub user_labels: ::std::collections::HashMap<
4047 ::prost::alloc::string::String,
4048 ::prost::alloc::string::String,
4049 >,
4050 #[prost(enumeration = "SqlAvailabilityType", tag = "6")]
4060 pub availability_type: i32,
4061 #[prost(enumeration = "SqlPricingPlan", tag = "7")]
4064 pub pricing_plan: i32,
4065 #[deprecated]
4069 #[prost(enumeration = "SqlReplicationType", tag = "8")]
4070 pub replication_type: i32,
4071 #[prost(message, optional, tag = "9")]
4074 pub storage_auto_resize_limit: ::core::option::Option<i64>,
4075 #[prost(enumeration = "settings::SqlActivationPolicy", tag = "10")]
4083 pub activation_policy: i32,
4084 #[prost(message, optional, tag = "11")]
4088 pub ip_configuration: ::core::option::Option<IpConfiguration>,
4089 #[prost(message, optional, tag = "12")]
4092 pub storage_auto_resize: ::core::option::Option<bool>,
4093 #[prost(message, optional, tag = "13")]
4098 pub location_preference: ::core::option::Option<LocationPreference>,
4099 #[prost(message, repeated, tag = "14")]
4101 pub database_flags: ::prost::alloc::vec::Vec<DatabaseFlags>,
4102 #[prost(enumeration = "SqlDataDiskType", tag = "15")]
4105 pub data_disk_type: i32,
4106 #[prost(message, optional, tag = "16")]
4109 pub maintenance_window: ::core::option::Option<MaintenanceWindow>,
4110 #[prost(message, optional, tag = "17")]
4112 pub backup_configuration: ::core::option::Option<BackupConfiguration>,
4113 #[prost(message, optional, tag = "18")]
4117 pub database_replication_enabled: ::core::option::Option<bool>,
4118 #[deprecated]
4122 #[prost(message, optional, tag = "19")]
4123 pub crash_safe_replication_enabled: ::core::option::Option<bool>,
4124 #[prost(message, optional, tag = "20")]
4126 pub data_disk_size_gb: ::core::option::Option<i64>,
4127 #[prost(message, optional, tag = "22")]
4129 pub active_directory_config: ::core::option::Option<SqlActiveDirectoryConfig>,
4130 #[prost(string, tag = "23")]
4132 pub collation: ::prost::alloc::string::String,
4133 #[prost(message, repeated, tag = "24")]
4135 pub deny_maintenance_periods: ::prost::alloc::vec::Vec<DenyMaintenancePeriod>,
4136 #[prost(message, optional, tag = "25")]
4138 pub insights_config: ::core::option::Option<InsightsConfig>,
4139 #[prost(message, optional, tag = "27")]
4141 pub password_validation_policy: ::core::option::Option<PasswordValidationPolicy>,
4142 #[prost(message, optional, tag = "29")]
4144 pub sql_server_audit_config: ::core::option::Option<SqlServerAuditConfig>,
4145 #[prost(enumeration = "settings::Edition", tag = "38")]
4147 pub edition: i32,
4148 #[prost(enumeration = "settings::ConnectorEnforcement", tag = "32")]
4159 pub connector_enforcement: i32,
4160 #[prost(message, optional, tag = "33")]
4162 pub deletion_protection_enabled: ::core::option::Option<bool>,
4163 #[prost(string, tag = "34")]
4165 pub time_zone: ::prost::alloc::string::String,
4166 #[prost(message, optional, tag = "35")]
4169 pub advanced_machine_features: ::core::option::Option<AdvancedMachineFeatures>,
4170 #[prost(message, optional, tag = "37")]
4172 pub data_cache_config: ::core::option::Option<DataCacheConfig>,
4173 #[prost(message, optional, tag = "39")]
4176 pub replication_lag_max_seconds: ::core::option::Option<i32>,
4177 #[prost(message, optional, tag = "40")]
4182 pub enable_google_ml_integration: ::core::option::Option<bool>,
4183 #[prost(message, optional, tag = "41")]
4187 pub enable_dataplex_integration: ::core::option::Option<bool>,
4188 #[prost(message, optional, tag = "42")]
4193 pub retain_backups_on_delete: ::core::option::Option<bool>,
4194 #[prost(int64, optional, tag = "43")]
4197 pub data_disk_provisioned_iops: ::core::option::Option<i64>,
4198 #[prost(int64, optional, tag = "44")]
4201 pub data_disk_provisioned_throughput: ::core::option::Option<i64>,
4202 #[prost(message, optional, tag = "45")]
4204 pub connection_pool_config: ::core::option::Option<ConnectionPoolConfig>,
4205 #[prost(message, optional, tag = "47")]
4207 pub final_backup_config: ::core::option::Option<FinalBackupConfig>,
4208 #[prost(message, optional, tag = "48")]
4210 pub read_pool_auto_scale_config: ::core::option::Option<ReadPoolAutoScaleConfig>,
4211 #[prost(bool, optional, tag = "50")]
4215 pub auto_upgrade_enabled: ::core::option::Option<bool>,
4216 #[prost(message, optional, tag = "52")]
4218 pub entraid_config: ::core::option::Option<SqlServerEntraIdConfig>,
4219 #[prost(enumeration = "settings::DataApiAccess", optional, tag = "53")]
4222 pub data_api_access: ::core::option::Option<i32>,
4223 #[prost(message, optional, tag = "54")]
4226 pub performance_capture_config: ::core::option::Option<PerformanceCaptureConfig>,
4227}
4228pub mod settings {
4230 #[derive(
4232 Clone,
4233 Copy,
4234 Debug,
4235 PartialEq,
4236 Eq,
4237 Hash,
4238 PartialOrd,
4239 Ord,
4240 ::prost::Enumeration
4241 )]
4242 #[repr(i32)]
4243 pub enum SqlActivationPolicy {
4244 Unspecified = 0,
4246 Always = 1,
4248 Never = 2,
4250 #[deprecated]
4252 OnDemand = 3,
4253 }
4254 impl SqlActivationPolicy {
4255 pub fn as_str_name(&self) -> &'static str {
4260 match self {
4261 Self::Unspecified => "SQL_ACTIVATION_POLICY_UNSPECIFIED",
4262 Self::Always => "ALWAYS",
4263 Self::Never => "NEVER",
4264 #[allow(deprecated)]
4265 Self::OnDemand => "ON_DEMAND",
4266 }
4267 }
4268 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4270 match value {
4271 "SQL_ACTIVATION_POLICY_UNSPECIFIED" => Some(Self::Unspecified),
4272 "ALWAYS" => Some(Self::Always),
4273 "NEVER" => Some(Self::Never),
4274 "ON_DEMAND" => Some(#[allow(deprecated)] Self::OnDemand),
4275 _ => None,
4276 }
4277 }
4278 }
4279 #[derive(
4281 Clone,
4282 Copy,
4283 Debug,
4284 PartialEq,
4285 Eq,
4286 Hash,
4287 PartialOrd,
4288 Ord,
4289 ::prost::Enumeration
4290 )]
4291 #[repr(i32)]
4292 pub enum Edition {
4293 Unspecified = 0,
4295 Enterprise = 2,
4297 EnterprisePlus = 3,
4299 }
4300 impl Edition {
4301 pub fn as_str_name(&self) -> &'static str {
4306 match self {
4307 Self::Unspecified => "EDITION_UNSPECIFIED",
4308 Self::Enterprise => "ENTERPRISE",
4309 Self::EnterprisePlus => "ENTERPRISE_PLUS",
4310 }
4311 }
4312 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4314 match value {
4315 "EDITION_UNSPECIFIED" => Some(Self::Unspecified),
4316 "ENTERPRISE" => Some(Self::Enterprise),
4317 "ENTERPRISE_PLUS" => Some(Self::EnterprisePlus),
4318 _ => None,
4319 }
4320 }
4321 }
4322 #[derive(
4324 Clone,
4325 Copy,
4326 Debug,
4327 PartialEq,
4328 Eq,
4329 Hash,
4330 PartialOrd,
4331 Ord,
4332 ::prost::Enumeration
4333 )]
4334 #[repr(i32)]
4335 pub enum ConnectorEnforcement {
4336 Unspecified = 0,
4338 NotRequired = 1,
4340 Required = 2,
4344 }
4345 impl ConnectorEnforcement {
4346 pub fn as_str_name(&self) -> &'static str {
4351 match self {
4352 Self::Unspecified => "CONNECTOR_ENFORCEMENT_UNSPECIFIED",
4353 Self::NotRequired => "NOT_REQUIRED",
4354 Self::Required => "REQUIRED",
4355 }
4356 }
4357 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4359 match value {
4360 "CONNECTOR_ENFORCEMENT_UNSPECIFIED" => Some(Self::Unspecified),
4361 "NOT_REQUIRED" => Some(Self::NotRequired),
4362 "REQUIRED" => Some(Self::Required),
4363 _ => None,
4364 }
4365 }
4366 }
4367 #[derive(
4369 Clone,
4370 Copy,
4371 Debug,
4372 PartialEq,
4373 Eq,
4374 Hash,
4375 PartialOrd,
4376 Ord,
4377 ::prost::Enumeration
4378 )]
4379 #[repr(i32)]
4380 pub enum DataApiAccess {
4381 Unspecified = 0,
4383 DisallowDataApi = 1,
4385 AllowDataApi = 2,
4389 }
4390 impl DataApiAccess {
4391 pub fn as_str_name(&self) -> &'static str {
4396 match self {
4397 Self::Unspecified => "DATA_API_ACCESS_UNSPECIFIED",
4398 Self::DisallowDataApi => "DISALLOW_DATA_API",
4399 Self::AllowDataApi => "ALLOW_DATA_API",
4400 }
4401 }
4402 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4404 match value {
4405 "DATA_API_ACCESS_UNSPECIFIED" => Some(Self::Unspecified),
4406 "DISALLOW_DATA_API" => Some(Self::DisallowDataApi),
4407 "ALLOW_DATA_API" => Some(Self::AllowDataApi),
4408 _ => None,
4409 }
4410 }
4411 }
4412}
4413#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4415pub struct PerformanceCaptureConfig {
4416 #[prost(bool, optional, tag = "1")]
4418 pub enabled: ::core::option::Option<bool>,
4419 #[prost(int32, optional, tag = "2")]
4421 pub probing_interval_seconds: ::core::option::Option<i32>,
4422 #[prost(int32, optional, tag = "3")]
4425 pub probe_threshold: ::core::option::Option<i32>,
4426 #[prost(int32, optional, tag = "4")]
4429 pub running_threads_threshold: ::core::option::Option<i32>,
4430 #[prost(int32, optional, tag = "5")]
4433 pub seconds_behind_source_threshold: ::core::option::Option<i32>,
4434 #[prost(int32, optional, tag = "8")]
4437 pub transaction_duration_threshold: ::core::option::Option<i32>,
4438}
4439#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4441pub struct AdvancedMachineFeatures {
4442 #[prost(int32, tag = "1")]
4444 pub threads_per_core: i32,
4445}
4446#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4448pub struct SslCert {
4449 #[prost(string, tag = "1")]
4451 pub kind: ::prost::alloc::string::String,
4452 #[prost(string, tag = "2")]
4454 pub cert_serial_number: ::prost::alloc::string::String,
4455 #[prost(string, tag = "3")]
4457 pub cert: ::prost::alloc::string::String,
4458 #[prost(message, optional, tag = "4")]
4462 pub create_time: ::core::option::Option<::prost_types::Timestamp>,
4463 #[prost(string, tag = "5")]
4465 pub common_name: ::prost::alloc::string::String,
4466 #[prost(message, optional, tag = "6")]
4470 pub expiration_time: ::core::option::Option<::prost_types::Timestamp>,
4471 #[prost(string, tag = "7")]
4473 pub sha1_fingerprint: ::prost::alloc::string::String,
4474 #[prost(string, tag = "8")]
4476 pub instance: ::prost::alloc::string::String,
4477 #[prost(string, tag = "9")]
4479 pub self_link: ::prost::alloc::string::String,
4480}
4481#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4483pub struct SslCertDetail {
4484 #[prost(message, optional, tag = "1")]
4486 pub cert_info: ::core::option::Option<SslCert>,
4487 #[prost(string, tag = "2")]
4490 pub cert_private_key: ::prost::alloc::string::String,
4491}
4492#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4494pub struct SslCertsCreateEphemeralRequest {
4495 #[prost(string, tag = "1")]
4497 pub public_key: ::prost::alloc::string::String,
4498 #[prost(string, tag = "2")]
4500 pub access_token: ::prost::alloc::string::String,
4501}
4502#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4504pub struct SslCertsInsertRequest {
4505 #[prost(string, tag = "1")]
4508 pub common_name: ::prost::alloc::string::String,
4509}
4510#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4512pub struct SqlInstancesRescheduleMaintenanceRequestBody {
4513 #[prost(message, optional, tag = "3")]
4515 pub reschedule: ::core::option::Option<
4516 sql_instances_reschedule_maintenance_request_body::Reschedule,
4517 >,
4518}
4519pub mod sql_instances_reschedule_maintenance_request_body {
4521 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
4522 pub struct Reschedule {
4523 #[prost(enumeration = "RescheduleType", tag = "1")]
4525 pub reschedule_type: i32,
4526 #[prost(message, optional, tag = "2")]
4531 pub schedule_time: ::core::option::Option<::prost_types::Timestamp>,
4532 }
4533 #[derive(
4534 Clone,
4535 Copy,
4536 Debug,
4537 PartialEq,
4538 Eq,
4539 Hash,
4540 PartialOrd,
4541 Ord,
4542 ::prost::Enumeration
4543 )]
4544 #[repr(i32)]
4545 pub enum RescheduleType {
4546 Unspecified = 0,
4547 Immediate = 1,
4549 NextAvailableWindow = 2,
4552 SpecificTime = 3,
4554 }
4555 impl RescheduleType {
4556 pub fn as_str_name(&self) -> &'static str {
4561 match self {
4562 Self::Unspecified => "RESCHEDULE_TYPE_UNSPECIFIED",
4563 Self::Immediate => "IMMEDIATE",
4564 Self::NextAvailableWindow => "NEXT_AVAILABLE_WINDOW",
4565 Self::SpecificTime => "SPECIFIC_TIME",
4566 }
4567 }
4568 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4570 match value {
4571 "RESCHEDULE_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
4572 "IMMEDIATE" => Some(Self::Immediate),
4573 "NEXT_AVAILABLE_WINDOW" => Some(Self::NextAvailableWindow),
4574 "SPECIFIC_TIME" => Some(Self::SpecificTime),
4575 _ => None,
4576 }
4577 }
4578 }
4579}
4580#[derive(Clone, PartialEq, ::prost::Message)]
4582pub struct SslCertsInsertResponse {
4583 #[prost(string, tag = "1")]
4585 pub kind: ::prost::alloc::string::String,
4586 #[prost(message, optional, tag = "2")]
4588 pub operation: ::core::option::Option<Operation>,
4589 #[prost(message, optional, tag = "3")]
4593 pub server_ca_cert: ::core::option::Option<SslCert>,
4594 #[prost(message, optional, tag = "4")]
4596 pub client_cert: ::core::option::Option<SslCertDetail>,
4597}
4598#[derive(Clone, PartialEq, ::prost::Message)]
4600pub struct SslCertsListResponse {
4601 #[prost(string, tag = "1")]
4603 pub kind: ::prost::alloc::string::String,
4604 #[prost(message, repeated, tag = "2")]
4606 pub items: ::prost::alloc::vec::Vec<SslCert>,
4607}
4608#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4610pub struct TruncateLogContext {
4611 #[prost(string, tag = "1")]
4613 pub kind: ::prost::alloc::string::String,
4614 #[prost(string, tag = "2")]
4617 pub log_type: ::prost::alloc::string::String,
4618}
4619#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4621pub struct SqlActiveDirectoryConfig {
4622 #[prost(string, tag = "1")]
4624 pub kind: ::prost::alloc::string::String,
4625 #[prost(string, tag = "2")]
4627 pub domain: ::prost::alloc::string::String,
4628 #[prost(enumeration = "sql_active_directory_config::ActiveDirectoryMode", tag = "3")]
4630 pub mode: i32,
4631 #[prost(string, repeated, tag = "4")]
4634 pub dns_servers: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
4635 #[prost(string, tag = "5")]
4638 pub admin_credential_secret_name: ::prost::alloc::string::String,
4639 #[prost(string, tag = "6")]
4642 pub organizational_unit: ::prost::alloc::string::String,
4643}
4644pub mod sql_active_directory_config {
4646 #[derive(
4648 Clone,
4649 Copy,
4650 Debug,
4651 PartialEq,
4652 Eq,
4653 Hash,
4654 PartialOrd,
4655 Ord,
4656 ::prost::Enumeration
4657 )]
4658 #[repr(i32)]
4659 pub enum ActiveDirectoryMode {
4660 Unspecified = 0,
4662 ManagedActiveDirectory = 1,
4665 #[deprecated]
4667 SelfManagedActiveDirectory = 2,
4668 CustomerManagedActiveDirectory = 3,
4670 }
4671 impl ActiveDirectoryMode {
4672 pub fn as_str_name(&self) -> &'static str {
4677 match self {
4678 Self::Unspecified => "ACTIVE_DIRECTORY_MODE_UNSPECIFIED",
4679 Self::ManagedActiveDirectory => "MANAGED_ACTIVE_DIRECTORY",
4680 #[allow(deprecated)]
4681 Self::SelfManagedActiveDirectory => "SELF_MANAGED_ACTIVE_DIRECTORY",
4682 Self::CustomerManagedActiveDirectory => {
4683 "CUSTOMER_MANAGED_ACTIVE_DIRECTORY"
4684 }
4685 }
4686 }
4687 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4689 match value {
4690 "ACTIVE_DIRECTORY_MODE_UNSPECIFIED" => Some(Self::Unspecified),
4691 "MANAGED_ACTIVE_DIRECTORY" => Some(Self::ManagedActiveDirectory),
4692 "SELF_MANAGED_ACTIVE_DIRECTORY" => {
4693 Some(#[allow(deprecated)] Self::SelfManagedActiveDirectory)
4694 }
4695 "CUSTOMER_MANAGED_ACTIVE_DIRECTORY" => {
4696 Some(Self::CustomerManagedActiveDirectory)
4697 }
4698 _ => None,
4699 }
4700 }
4701 }
4702}
4703#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4705pub struct SqlServerAuditConfig {
4706 #[prost(string, tag = "1")]
4708 pub kind: ::prost::alloc::string::String,
4709 #[prost(string, tag = "2")]
4711 pub bucket: ::prost::alloc::string::String,
4712 #[prost(message, optional, tag = "3")]
4714 pub retention_interval: ::core::option::Option<::prost_types::Duration>,
4715 #[prost(message, optional, tag = "4")]
4717 pub upload_interval: ::core::option::Option<::prost_types::Duration>,
4718}
4719#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4721pub struct SqlServerEntraIdConfig {
4722 #[prost(string, tag = "1")]
4724 pub kind: ::prost::alloc::string::String,
4725 #[prost(string, tag = "2")]
4727 pub tenant_id: ::prost::alloc::string::String,
4728 #[prost(string, tag = "3")]
4730 pub application_id: ::prost::alloc::string::String,
4731}
4732#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4735pub struct ConnectionPoolFlags {
4736 #[prost(string, tag = "1")]
4738 pub name: ::prost::alloc::string::String,
4739 #[prost(string, tag = "2")]
4743 pub value: ::prost::alloc::string::String,
4744}
4745#[derive(Clone, PartialEq, ::prost::Message)]
4747pub struct ReadPoolAutoScaleConfig {
4748 #[prost(bool, optional, tag = "1")]
4750 pub enabled: ::core::option::Option<bool>,
4751 #[prost(int32, optional, tag = "2")]
4753 pub min_node_count: ::core::option::Option<i32>,
4754 #[prost(int32, optional, tag = "3")]
4756 pub max_node_count: ::core::option::Option<i32>,
4757 #[prost(message, repeated, tag = "4")]
4759 pub target_metrics: ::prost::alloc::vec::Vec<
4760 read_pool_auto_scale_config::TargetMetric,
4761 >,
4762 #[prost(bool, optional, tag = "5")]
4765 pub disable_scale_in: ::core::option::Option<bool>,
4766 #[prost(int32, optional, tag = "6")]
4768 pub scale_in_cooldown_seconds: ::core::option::Option<i32>,
4769 #[prost(int32, optional, tag = "7")]
4771 pub scale_out_cooldown_seconds: ::core::option::Option<i32>,
4772}
4773pub mod read_pool_auto_scale_config {
4775 #[derive(Clone, PartialEq, ::prost::Message)]
4777 pub struct TargetMetric {
4778 #[prost(string, optional, tag = "1")]
4780 pub metric: ::core::option::Option<::prost::alloc::string::String>,
4781 #[prost(float, optional, tag = "2")]
4783 pub target_value: ::core::option::Option<f32>,
4784 }
4785}
4786#[derive(Clone, PartialEq, ::prost::Message)]
4788pub struct ConnectionPoolConfig {
4789 #[prost(bool, optional, tag = "1")]
4791 pub connection_pooling_enabled: ::core::option::Option<bool>,
4792 #[prost(message, repeated, tag = "8")]
4794 pub flags: ::prost::alloc::vec::Vec<ConnectionPoolFlags>,
4795 #[prost(int32, optional, tag = "9")]
4797 pub pooler_count: ::core::option::Option<i32>,
4798}
4799#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
4801pub struct AcquireSsrsLeaseContext {
4802 #[prost(string, optional, tag = "1")]
4805 pub setup_login: ::core::option::Option<::prost::alloc::string::String>,
4806 #[prost(string, optional, tag = "2")]
4809 pub service_login: ::core::option::Option<::prost::alloc::string::String>,
4810 #[prost(string, optional, tag = "3")]
4812 pub report_database: ::core::option::Option<::prost::alloc::string::String>,
4813 #[prost(message, optional, tag = "4")]
4815 pub duration: ::core::option::Option<::prost_types::Duration>,
4816}
4817#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
4818#[repr(i32)]
4819pub enum SqlFileType {
4820 Unspecified = 0,
4822 Sql = 1,
4824 Csv = 2,
4826 Bak = 4,
4827 Tde = 8,
4829}
4830impl SqlFileType {
4831 pub fn as_str_name(&self) -> &'static str {
4836 match self {
4837 Self::Unspecified => "SQL_FILE_TYPE_UNSPECIFIED",
4838 Self::Sql => "SQL",
4839 Self::Csv => "CSV",
4840 Self::Bak => "BAK",
4841 Self::Tde => "TDE",
4842 }
4843 }
4844 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4846 match value {
4847 "SQL_FILE_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
4848 "SQL" => Some(Self::Sql),
4849 "CSV" => Some(Self::Csv),
4850 "BAK" => Some(Self::Bak),
4851 "TDE" => Some(Self::Tde),
4852 _ => None,
4853 }
4854 }
4855}
4856#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
4857#[repr(i32)]
4858pub enum BakType {
4859 Unspecified = 0,
4861 Full = 1,
4863 Diff = 2,
4865 Tlog = 3,
4867}
4868impl BakType {
4869 pub fn as_str_name(&self) -> &'static str {
4874 match self {
4875 Self::Unspecified => "BAK_TYPE_UNSPECIFIED",
4876 Self::Full => "FULL",
4877 Self::Diff => "DIFF",
4878 Self::Tlog => "TLOG",
4879 }
4880 }
4881 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4883 match value {
4884 "BAK_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
4885 "FULL" => Some(Self::Full),
4886 "DIFF" => Some(Self::Diff),
4887 "TLOG" => Some(Self::Tlog),
4888 _ => None,
4889 }
4890 }
4891}
4892#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
4894#[repr(i32)]
4895pub enum SqlMaintenanceType {
4896 Unspecified = 0,
4898 InstanceMaintenance = 1,
4901 ReplicaIncludedMaintenance = 2,
4905 InstanceSelfServiceMaintenance = 3,
4909 ReplicaIncludedSelfServiceMaintenance = 4,
4913}
4914impl SqlMaintenanceType {
4915 pub fn as_str_name(&self) -> &'static str {
4920 match self {
4921 Self::Unspecified => "SQL_MAINTENANCE_TYPE_UNSPECIFIED",
4922 Self::InstanceMaintenance => "INSTANCE_MAINTENANCE",
4923 Self::ReplicaIncludedMaintenance => "REPLICA_INCLUDED_MAINTENANCE",
4924 Self::InstanceSelfServiceMaintenance => "INSTANCE_SELF_SERVICE_MAINTENANCE",
4925 Self::ReplicaIncludedSelfServiceMaintenance => {
4926 "REPLICA_INCLUDED_SELF_SERVICE_MAINTENANCE"
4927 }
4928 }
4929 }
4930 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4932 match value {
4933 "SQL_MAINTENANCE_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
4934 "INSTANCE_MAINTENANCE" => Some(Self::InstanceMaintenance),
4935 "REPLICA_INCLUDED_MAINTENANCE" => Some(Self::ReplicaIncludedMaintenance),
4936 "INSTANCE_SELF_SERVICE_MAINTENANCE" => {
4937 Some(Self::InstanceSelfServiceMaintenance)
4938 }
4939 "REPLICA_INCLUDED_SELF_SERVICE_MAINTENANCE" => {
4940 Some(Self::ReplicaIncludedSelfServiceMaintenance)
4941 }
4942 _ => None,
4943 }
4944 }
4945}
4946#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
4948#[repr(i32)]
4949pub enum SqlBackupRunStatus {
4950 Unspecified = 0,
4952 Enqueued = 1,
4954 Overdue = 2,
4958 Running = 3,
4960 Failed = 4,
4962 Successful = 5,
4964 Skipped = 6,
4967 DeletionPending = 7,
4969 DeletionFailed = 8,
4971 Deleted = 9,
4973}
4974impl SqlBackupRunStatus {
4975 pub fn as_str_name(&self) -> &'static str {
4980 match self {
4981 Self::Unspecified => "SQL_BACKUP_RUN_STATUS_UNSPECIFIED",
4982 Self::Enqueued => "ENQUEUED",
4983 Self::Overdue => "OVERDUE",
4984 Self::Running => "RUNNING",
4985 Self::Failed => "FAILED",
4986 Self::Successful => "SUCCESSFUL",
4987 Self::Skipped => "SKIPPED",
4988 Self::DeletionPending => "DELETION_PENDING",
4989 Self::DeletionFailed => "DELETION_FAILED",
4990 Self::Deleted => "DELETED",
4991 }
4992 }
4993 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
4995 match value {
4996 "SQL_BACKUP_RUN_STATUS_UNSPECIFIED" => Some(Self::Unspecified),
4997 "ENQUEUED" => Some(Self::Enqueued),
4998 "OVERDUE" => Some(Self::Overdue),
4999 "RUNNING" => Some(Self::Running),
5000 "FAILED" => Some(Self::Failed),
5001 "SUCCESSFUL" => Some(Self::Successful),
5002 "SKIPPED" => Some(Self::Skipped),
5003 "DELETION_PENDING" => Some(Self::DeletionPending),
5004 "DELETION_FAILED" => Some(Self::DeletionFailed),
5005 "DELETED" => Some(Self::Deleted),
5006 _ => None,
5007 }
5008 }
5009}
5010#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5011#[repr(i32)]
5012pub enum SqlBackupRunType {
5013 Unspecified = 0,
5015 Automated = 1,
5017 OnDemand = 2,
5019}
5020impl SqlBackupRunType {
5021 pub fn as_str_name(&self) -> &'static str {
5026 match self {
5027 Self::Unspecified => "SQL_BACKUP_RUN_TYPE_UNSPECIFIED",
5028 Self::Automated => "AUTOMATED",
5029 Self::OnDemand => "ON_DEMAND",
5030 }
5031 }
5032 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5034 match value {
5035 "SQL_BACKUP_RUN_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
5036 "AUTOMATED" => Some(Self::Automated),
5037 "ON_DEMAND" => Some(Self::OnDemand),
5038 _ => None,
5039 }
5040 }
5041}
5042#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5044#[repr(i32)]
5045pub enum SqlBackupKind {
5046 Unspecified = 0,
5048 Snapshot = 1,
5050 Physical = 2,
5052}
5053impl SqlBackupKind {
5054 pub fn as_str_name(&self) -> &'static str {
5059 match self {
5060 Self::Unspecified => "SQL_BACKUP_KIND_UNSPECIFIED",
5061 Self::Snapshot => "SNAPSHOT",
5062 Self::Physical => "PHYSICAL",
5063 }
5064 }
5065 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5067 match value {
5068 "SQL_BACKUP_KIND_UNSPECIFIED" => Some(Self::Unspecified),
5069 "SNAPSHOT" => Some(Self::Snapshot),
5070 "PHYSICAL" => Some(Self::Physical),
5071 _ => None,
5072 }
5073 }
5074}
5075#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5076#[repr(i32)]
5077pub enum SqlBackendType {
5078 Unspecified = 0,
5080 #[deprecated]
5082 FirstGen = 1,
5083 SecondGen = 2,
5085 External = 3,
5087}
5088impl SqlBackendType {
5089 pub fn as_str_name(&self) -> &'static str {
5094 match self {
5095 Self::Unspecified => "SQL_BACKEND_TYPE_UNSPECIFIED",
5096 #[allow(deprecated)]
5097 Self::FirstGen => "FIRST_GEN",
5098 Self::SecondGen => "SECOND_GEN",
5099 Self::External => "EXTERNAL",
5100 }
5101 }
5102 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5104 match value {
5105 "SQL_BACKEND_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
5106 "FIRST_GEN" => Some(#[allow(deprecated)] Self::FirstGen),
5107 "SECOND_GEN" => Some(Self::SecondGen),
5108 "EXTERNAL" => Some(Self::External),
5109 _ => None,
5110 }
5111 }
5112}
5113#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5114#[repr(i32)]
5115pub enum SqlIpAddressType {
5116 Unspecified = 0,
5118 Primary = 1,
5121 Outgoing = 2,
5126 Private = 3,
5128 Migrated1stGen = 4,
5132}
5133impl SqlIpAddressType {
5134 pub fn as_str_name(&self) -> &'static str {
5139 match self {
5140 Self::Unspecified => "SQL_IP_ADDRESS_TYPE_UNSPECIFIED",
5141 Self::Primary => "PRIMARY",
5142 Self::Outgoing => "OUTGOING",
5143 Self::Private => "PRIVATE",
5144 Self::Migrated1stGen => "MIGRATED_1ST_GEN",
5145 }
5146 }
5147 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5149 match value {
5150 "SQL_IP_ADDRESS_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
5151 "PRIMARY" => Some(Self::Primary),
5152 "OUTGOING" => Some(Self::Outgoing),
5153 "PRIVATE" => Some(Self::Private),
5154 "MIGRATED_1ST_GEN" => Some(Self::Migrated1stGen),
5155 _ => None,
5156 }
5157 }
5158}
5159#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5160#[repr(i32)]
5161pub enum SqlInstanceType {
5162 Unspecified = 0,
5164 CloudSqlInstance = 1,
5167 OnPremisesInstance = 2,
5170 ReadReplicaInstance = 3,
5172 ReadPoolInstance = 5,
5174}
5175impl SqlInstanceType {
5176 pub fn as_str_name(&self) -> &'static str {
5181 match self {
5182 Self::Unspecified => "SQL_INSTANCE_TYPE_UNSPECIFIED",
5183 Self::CloudSqlInstance => "CLOUD_SQL_INSTANCE",
5184 Self::OnPremisesInstance => "ON_PREMISES_INSTANCE",
5185 Self::ReadReplicaInstance => "READ_REPLICA_INSTANCE",
5186 Self::ReadPoolInstance => "READ_POOL_INSTANCE",
5187 }
5188 }
5189 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5191 match value {
5192 "SQL_INSTANCE_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
5193 "CLOUD_SQL_INSTANCE" => Some(Self::CloudSqlInstance),
5194 "ON_PREMISES_INSTANCE" => Some(Self::OnPremisesInstance),
5195 "READ_REPLICA_INSTANCE" => Some(Self::ReadReplicaInstance),
5196 "READ_POOL_INSTANCE" => Some(Self::ReadPoolInstance),
5197 _ => None,
5198 }
5199 }
5200}
5201#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5203#[repr(i32)]
5204pub enum SqlDatabaseVersion {
5205 Unspecified = 0,
5207 #[deprecated]
5209 Mysql51 = 2,
5210 #[deprecated]
5212 Mysql55 = 3,
5213 Mysql56 = 5,
5215 Mysql57 = 6,
5217 Mysql80 = 20,
5219 Mysql8018 = 41,
5221 Mysql8026 = 85,
5223 Mysql8027 = 111,
5225 Mysql8028 = 132,
5227 #[deprecated]
5229 Mysql8029 = 148,
5230 Mysql8030 = 174,
5232 Mysql8031 = 197,
5234 Mysql8032 = 213,
5236 Mysql8033 = 238,
5238 Mysql8034 = 239,
5240 Mysql8035 = 240,
5242 Mysql8036 = 241,
5244 Mysql8037 = 355,
5246 Mysql8039 = 357,
5248 Mysql8040 = 358,
5250 Mysql8041 = 488,
5252 Mysql8042 = 489,
5254 Mysql8043 = 553,
5256 Mysql8044 = 554,
5258 Mysql8045 = 555,
5260 Mysql8046 = 556,
5262 Mysql84 = 398,
5264 Mysql97 = 654,
5266 Sqlserver2017Standard = 11,
5268 Sqlserver2017Enterprise = 14,
5270 Sqlserver2017Express = 15,
5272 Sqlserver2017Web = 16,
5274 Postgres96 = 9,
5276 Postgres10 = 18,
5278 Postgres11 = 10,
5280 Postgres12 = 19,
5282 Postgres13 = 23,
5284 Postgres14 = 110,
5286 Postgres15 = 172,
5288 Postgres16 = 272,
5290 Postgres17 = 408,
5292 Postgres18 = 557,
5294 Sqlserver2019Standard = 26,
5296 Sqlserver2019Enterprise = 27,
5298 Sqlserver2019Express = 28,
5300 Sqlserver2019Web = 29,
5302 Sqlserver2022Standard = 199,
5304 Sqlserver2022Enterprise = 200,
5306 Sqlserver2022Express = 201,
5308 Sqlserver2022Web = 202,
5310}
5311impl SqlDatabaseVersion {
5312 pub fn as_str_name(&self) -> &'static str {
5317 match self {
5318 Self::Unspecified => "SQL_DATABASE_VERSION_UNSPECIFIED",
5319 #[allow(deprecated)]
5320 Self::Mysql51 => "MYSQL_5_1",
5321 #[allow(deprecated)]
5322 Self::Mysql55 => "MYSQL_5_5",
5323 Self::Mysql56 => "MYSQL_5_6",
5324 Self::Mysql57 => "MYSQL_5_7",
5325 Self::Mysql80 => "MYSQL_8_0",
5326 Self::Mysql8018 => "MYSQL_8_0_18",
5327 Self::Mysql8026 => "MYSQL_8_0_26",
5328 Self::Mysql8027 => "MYSQL_8_0_27",
5329 Self::Mysql8028 => "MYSQL_8_0_28",
5330 #[allow(deprecated)]
5331 Self::Mysql8029 => "MYSQL_8_0_29",
5332 Self::Mysql8030 => "MYSQL_8_0_30",
5333 Self::Mysql8031 => "MYSQL_8_0_31",
5334 Self::Mysql8032 => "MYSQL_8_0_32",
5335 Self::Mysql8033 => "MYSQL_8_0_33",
5336 Self::Mysql8034 => "MYSQL_8_0_34",
5337 Self::Mysql8035 => "MYSQL_8_0_35",
5338 Self::Mysql8036 => "MYSQL_8_0_36",
5339 Self::Mysql8037 => "MYSQL_8_0_37",
5340 Self::Mysql8039 => "MYSQL_8_0_39",
5341 Self::Mysql8040 => "MYSQL_8_0_40",
5342 Self::Mysql8041 => "MYSQL_8_0_41",
5343 Self::Mysql8042 => "MYSQL_8_0_42",
5344 Self::Mysql8043 => "MYSQL_8_0_43",
5345 Self::Mysql8044 => "MYSQL_8_0_44",
5346 Self::Mysql8045 => "MYSQL_8_0_45",
5347 Self::Mysql8046 => "MYSQL_8_0_46",
5348 Self::Mysql84 => "MYSQL_8_4",
5349 Self::Mysql97 => "MYSQL_9_7",
5350 Self::Sqlserver2017Standard => "SQLSERVER_2017_STANDARD",
5351 Self::Sqlserver2017Enterprise => "SQLSERVER_2017_ENTERPRISE",
5352 Self::Sqlserver2017Express => "SQLSERVER_2017_EXPRESS",
5353 Self::Sqlserver2017Web => "SQLSERVER_2017_WEB",
5354 Self::Postgres96 => "POSTGRES_9_6",
5355 Self::Postgres10 => "POSTGRES_10",
5356 Self::Postgres11 => "POSTGRES_11",
5357 Self::Postgres12 => "POSTGRES_12",
5358 Self::Postgres13 => "POSTGRES_13",
5359 Self::Postgres14 => "POSTGRES_14",
5360 Self::Postgres15 => "POSTGRES_15",
5361 Self::Postgres16 => "POSTGRES_16",
5362 Self::Postgres17 => "POSTGRES_17",
5363 Self::Postgres18 => "POSTGRES_18",
5364 Self::Sqlserver2019Standard => "SQLSERVER_2019_STANDARD",
5365 Self::Sqlserver2019Enterprise => "SQLSERVER_2019_ENTERPRISE",
5366 Self::Sqlserver2019Express => "SQLSERVER_2019_EXPRESS",
5367 Self::Sqlserver2019Web => "SQLSERVER_2019_WEB",
5368 Self::Sqlserver2022Standard => "SQLSERVER_2022_STANDARD",
5369 Self::Sqlserver2022Enterprise => "SQLSERVER_2022_ENTERPRISE",
5370 Self::Sqlserver2022Express => "SQLSERVER_2022_EXPRESS",
5371 Self::Sqlserver2022Web => "SQLSERVER_2022_WEB",
5372 }
5373 }
5374 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5376 match value {
5377 "SQL_DATABASE_VERSION_UNSPECIFIED" => Some(Self::Unspecified),
5378 "MYSQL_5_1" => Some(#[allow(deprecated)] Self::Mysql51),
5379 "MYSQL_5_5" => Some(#[allow(deprecated)] Self::Mysql55),
5380 "MYSQL_5_6" => Some(Self::Mysql56),
5381 "MYSQL_5_7" => Some(Self::Mysql57),
5382 "MYSQL_8_0" => Some(Self::Mysql80),
5383 "MYSQL_8_0_18" => Some(Self::Mysql8018),
5384 "MYSQL_8_0_26" => Some(Self::Mysql8026),
5385 "MYSQL_8_0_27" => Some(Self::Mysql8027),
5386 "MYSQL_8_0_28" => Some(Self::Mysql8028),
5387 "MYSQL_8_0_29" => Some(#[allow(deprecated)] Self::Mysql8029),
5388 "MYSQL_8_0_30" => Some(Self::Mysql8030),
5389 "MYSQL_8_0_31" => Some(Self::Mysql8031),
5390 "MYSQL_8_0_32" => Some(Self::Mysql8032),
5391 "MYSQL_8_0_33" => Some(Self::Mysql8033),
5392 "MYSQL_8_0_34" => Some(Self::Mysql8034),
5393 "MYSQL_8_0_35" => Some(Self::Mysql8035),
5394 "MYSQL_8_0_36" => Some(Self::Mysql8036),
5395 "MYSQL_8_0_37" => Some(Self::Mysql8037),
5396 "MYSQL_8_0_39" => Some(Self::Mysql8039),
5397 "MYSQL_8_0_40" => Some(Self::Mysql8040),
5398 "MYSQL_8_0_41" => Some(Self::Mysql8041),
5399 "MYSQL_8_0_42" => Some(Self::Mysql8042),
5400 "MYSQL_8_0_43" => Some(Self::Mysql8043),
5401 "MYSQL_8_0_44" => Some(Self::Mysql8044),
5402 "MYSQL_8_0_45" => Some(Self::Mysql8045),
5403 "MYSQL_8_0_46" => Some(Self::Mysql8046),
5404 "MYSQL_8_4" => Some(Self::Mysql84),
5405 "MYSQL_9_7" => Some(Self::Mysql97),
5406 "SQLSERVER_2017_STANDARD" => Some(Self::Sqlserver2017Standard),
5407 "SQLSERVER_2017_ENTERPRISE" => Some(Self::Sqlserver2017Enterprise),
5408 "SQLSERVER_2017_EXPRESS" => Some(Self::Sqlserver2017Express),
5409 "SQLSERVER_2017_WEB" => Some(Self::Sqlserver2017Web),
5410 "POSTGRES_9_6" => Some(Self::Postgres96),
5411 "POSTGRES_10" => Some(Self::Postgres10),
5412 "POSTGRES_11" => Some(Self::Postgres11),
5413 "POSTGRES_12" => Some(Self::Postgres12),
5414 "POSTGRES_13" => Some(Self::Postgres13),
5415 "POSTGRES_14" => Some(Self::Postgres14),
5416 "POSTGRES_15" => Some(Self::Postgres15),
5417 "POSTGRES_16" => Some(Self::Postgres16),
5418 "POSTGRES_17" => Some(Self::Postgres17),
5419 "POSTGRES_18" => Some(Self::Postgres18),
5420 "SQLSERVER_2019_STANDARD" => Some(Self::Sqlserver2019Standard),
5421 "SQLSERVER_2019_ENTERPRISE" => Some(Self::Sqlserver2019Enterprise),
5422 "SQLSERVER_2019_EXPRESS" => Some(Self::Sqlserver2019Express),
5423 "SQLSERVER_2019_WEB" => Some(Self::Sqlserver2019Web),
5424 "SQLSERVER_2022_STANDARD" => Some(Self::Sqlserver2022Standard),
5425 "SQLSERVER_2022_ENTERPRISE" => Some(Self::Sqlserver2022Enterprise),
5426 "SQLSERVER_2022_EXPRESS" => Some(Self::Sqlserver2022Express),
5427 "SQLSERVER_2022_WEB" => Some(Self::Sqlserver2022Web),
5428 _ => None,
5429 }
5430 }
5431}
5432#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5434#[repr(i32)]
5435pub enum SqlSuspensionReason {
5436 Unspecified = 0,
5438 BillingIssue = 2,
5441 LegalIssue = 3,
5444 OperationalIssue = 4,
5447 KmsKeyIssue = 5,
5449}
5450impl SqlSuspensionReason {
5451 pub fn as_str_name(&self) -> &'static str {
5456 match self {
5457 Self::Unspecified => "SQL_SUSPENSION_REASON_UNSPECIFIED",
5458 Self::BillingIssue => "BILLING_ISSUE",
5459 Self::LegalIssue => "LEGAL_ISSUE",
5460 Self::OperationalIssue => "OPERATIONAL_ISSUE",
5461 Self::KmsKeyIssue => "KMS_KEY_ISSUE",
5462 }
5463 }
5464 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5466 match value {
5467 "SQL_SUSPENSION_REASON_UNSPECIFIED" => Some(Self::Unspecified),
5468 "BILLING_ISSUE" => Some(Self::BillingIssue),
5469 "LEGAL_ISSUE" => Some(Self::LegalIssue),
5470 "OPERATIONAL_ISSUE" => Some(Self::OperationalIssue),
5471 "KMS_KEY_ISSUE" => Some(Self::KmsKeyIssue),
5472 _ => None,
5473 }
5474 }
5475}
5476#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5478#[repr(i32)]
5479pub enum SqlPricingPlan {
5480 Unspecified = 0,
5482 Package = 1,
5484 PerUse = 2,
5486}
5487impl SqlPricingPlan {
5488 pub fn as_str_name(&self) -> &'static str {
5493 match self {
5494 Self::Unspecified => "SQL_PRICING_PLAN_UNSPECIFIED",
5495 Self::Package => "PACKAGE",
5496 Self::PerUse => "PER_USE",
5497 }
5498 }
5499 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5501 match value {
5502 "SQL_PRICING_PLAN_UNSPECIFIED" => Some(Self::Unspecified),
5503 "PACKAGE" => Some(Self::Package),
5504 "PER_USE" => Some(Self::PerUse),
5505 _ => None,
5506 }
5507 }
5508}
5509#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5510#[repr(i32)]
5511pub enum SqlReplicationType {
5512 Unspecified = 0,
5514 Synchronous = 1,
5517 Asynchronous = 2,
5522}
5523impl SqlReplicationType {
5524 pub fn as_str_name(&self) -> &'static str {
5529 match self {
5530 Self::Unspecified => "SQL_REPLICATION_TYPE_UNSPECIFIED",
5531 Self::Synchronous => "SYNCHRONOUS",
5532 Self::Asynchronous => "ASYNCHRONOUS",
5533 }
5534 }
5535 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5537 match value {
5538 "SQL_REPLICATION_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
5539 "SYNCHRONOUS" => Some(Self::Synchronous),
5540 "ASYNCHRONOUS" => Some(Self::Asynchronous),
5541 _ => None,
5542 }
5543 }
5544}
5545#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5547#[repr(i32)]
5548pub enum SqlDataDiskType {
5549 Unspecified = 0,
5551 PdSsd = 1,
5553 PdHdd = 2,
5555 #[deprecated]
5558 ObsoleteLocalSsd = 3,
5559 HyperdiskBalanced = 4,
5561}
5562impl SqlDataDiskType {
5563 pub fn as_str_name(&self) -> &'static str {
5568 match self {
5569 Self::Unspecified => "SQL_DATA_DISK_TYPE_UNSPECIFIED",
5570 Self::PdSsd => "PD_SSD",
5571 Self::PdHdd => "PD_HDD",
5572 #[allow(deprecated)]
5573 Self::ObsoleteLocalSsd => "OBSOLETE_LOCAL_SSD",
5574 Self::HyperdiskBalanced => "HYPERDISK_BALANCED",
5575 }
5576 }
5577 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5579 match value {
5580 "SQL_DATA_DISK_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
5581 "PD_SSD" => Some(Self::PdSsd),
5582 "PD_HDD" => Some(Self::PdHdd),
5583 "OBSOLETE_LOCAL_SSD" => Some(#[allow(deprecated)] Self::ObsoleteLocalSsd),
5584 "HYPERDISK_BALANCED" => Some(Self::HyperdiskBalanced),
5585 _ => None,
5586 }
5587 }
5588}
5589#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5591#[repr(i32)]
5592pub enum SqlAvailabilityType {
5593 Unspecified = 0,
5595 Zonal = 1,
5597 Regional = 2,
5599}
5600impl SqlAvailabilityType {
5601 pub fn as_str_name(&self) -> &'static str {
5606 match self {
5607 Self::Unspecified => "SQL_AVAILABILITY_TYPE_UNSPECIFIED",
5608 Self::Zonal => "ZONAL",
5609 Self::Regional => "REGIONAL",
5610 }
5611 }
5612 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5614 match value {
5615 "SQL_AVAILABILITY_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
5616 "ZONAL" => Some(Self::Zonal),
5617 "REGIONAL" => Some(Self::Regional),
5618 _ => None,
5619 }
5620 }
5621}
5622#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5623#[repr(i32)]
5624pub enum SqlUpdateTrack {
5625 Unspecified = 0,
5627 Canary = 1,
5632 Stable = 2,
5637 Week5 = 3,
5641}
5642impl SqlUpdateTrack {
5643 pub fn as_str_name(&self) -> &'static str {
5648 match self {
5649 Self::Unspecified => "SQL_UPDATE_TRACK_UNSPECIFIED",
5650 Self::Canary => "canary",
5651 Self::Stable => "stable",
5652 Self::Week5 => "week5",
5653 }
5654 }
5655 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5657 match value {
5658 "SQL_UPDATE_TRACK_UNSPECIFIED" => Some(Self::Unspecified),
5659 "canary" => Some(Self::Canary),
5660 "stable" => Some(Self::Stable),
5661 "week5" => Some(Self::Week5),
5662 _ => None,
5663 }
5664 }
5665}
5666#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5667#[repr(i32)]
5668pub enum SqlFlagType {
5669 Unspecified = 0,
5671 Boolean = 1,
5673 String = 2,
5675 Integer = 3,
5677 None = 4,
5679 MysqlTimezoneOffset = 5,
5682 Float = 6,
5684 RepeatedString = 7,
5686}
5687impl SqlFlagType {
5688 pub fn as_str_name(&self) -> &'static str {
5693 match self {
5694 Self::Unspecified => "SQL_FLAG_TYPE_UNSPECIFIED",
5695 Self::Boolean => "BOOLEAN",
5696 Self::String => "STRING",
5697 Self::Integer => "INTEGER",
5698 Self::None => "NONE",
5699 Self::MysqlTimezoneOffset => "MYSQL_TIMEZONE_OFFSET",
5700 Self::Float => "FLOAT",
5701 Self::RepeatedString => "REPEATED_STRING",
5702 }
5703 }
5704 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5706 match value {
5707 "SQL_FLAG_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
5708 "BOOLEAN" => Some(Self::Boolean),
5709 "STRING" => Some(Self::String),
5710 "INTEGER" => Some(Self::Integer),
5711 "NONE" => Some(Self::None),
5712 "MYSQL_TIMEZONE_OFFSET" => Some(Self::MysqlTimezoneOffset),
5713 "FLOAT" => Some(Self::Float),
5714 "REPEATED_STRING" => Some(Self::RepeatedString),
5715 _ => None,
5716 }
5717 }
5718}
5719#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
5721#[repr(i32)]
5722pub enum SqlFlagScope {
5723 Unspecified = 0,
5725 Database = 1,
5727 ConnectionPool = 2,
5729}
5730impl SqlFlagScope {
5731 pub fn as_str_name(&self) -> &'static str {
5736 match self {
5737 Self::Unspecified => "SQL_FLAG_SCOPE_UNSPECIFIED",
5738 Self::Database => "SQL_FLAG_SCOPE_DATABASE",
5739 Self::ConnectionPool => "SQL_FLAG_SCOPE_CONNECTION_POOL",
5740 }
5741 }
5742 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
5744 match value {
5745 "SQL_FLAG_SCOPE_UNSPECIFIED" => Some(Self::Unspecified),
5746 "SQL_FLAG_SCOPE_DATABASE" => Some(Self::Database),
5747 "SQL_FLAG_SCOPE_CONNECTION_POOL" => Some(Self::ConnectionPool),
5748 _ => None,
5749 }
5750 }
5751}
5752#[derive(Clone, PartialEq, ::prost::Message)]
5754pub struct CreateBackupRequest {
5755 #[prost(string, tag = "1")]
5758 pub parent: ::prost::alloc::string::String,
5759 #[prost(message, optional, tag = "2")]
5761 pub backup: ::core::option::Option<Backup>,
5762}
5763#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5765pub struct GetBackupRequest {
5766 #[prost(string, tag = "1")]
5769 pub name: ::prost::alloc::string::String,
5770}
5771#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5773pub struct ListBackupsRequest {
5774 #[prost(string, tag = "1")]
5777 pub parent: ::prost::alloc::string::String,
5778 #[prost(int32, tag = "2")]
5784 pub page_size: i32,
5785 #[prost(string, tag = "3")]
5791 pub page_token: ::prost::alloc::string::String,
5792 #[prost(string, tag = "4")]
5797 pub filter: ::prost::alloc::string::String,
5798}
5799#[derive(Clone, PartialEq, ::prost::Message)]
5801pub struct ListBackupsResponse {
5802 #[prost(message, repeated, tag = "1")]
5804 pub backups: ::prost::alloc::vec::Vec<Backup>,
5805 #[prost(string, tag = "2")]
5808 pub next_page_token: ::prost::alloc::string::String,
5809 #[prost(message, repeated, tag = "3")]
5812 pub warnings: ::prost::alloc::vec::Vec<ApiWarning>,
5813}
5814#[derive(Clone, PartialEq, ::prost::Message)]
5816pub struct UpdateBackupRequest {
5817 #[prost(message, optional, tag = "1")]
5821 pub backup: ::core::option::Option<Backup>,
5822 #[prost(message, optional, tag = "2")]
5825 pub update_mask: ::core::option::Option<::prost_types::FieldMask>,
5826}
5827#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5829pub struct DeleteBackupRequest {
5830 #[prost(string, tag = "1")]
5833 pub name: ::prost::alloc::string::String,
5834}
5835#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5836pub struct SqlBackupRunsDeleteRequest {
5837 #[prost(int64, tag = "1")]
5841 pub id: i64,
5842 #[prost(string, tag = "2")]
5844 pub instance: ::prost::alloc::string::String,
5845 #[prost(string, tag = "3")]
5847 pub project: ::prost::alloc::string::String,
5848}
5849#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5850pub struct SqlBackupRunsGetRequest {
5851 #[prost(int64, tag = "1")]
5853 pub id: i64,
5854 #[prost(string, tag = "2")]
5856 pub instance: ::prost::alloc::string::String,
5857 #[prost(string, tag = "3")]
5859 pub project: ::prost::alloc::string::String,
5860}
5861#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5862pub struct SqlBackupRunsInsertRequest {
5863 #[prost(string, tag = "1")]
5865 pub instance: ::prost::alloc::string::String,
5866 #[prost(string, tag = "2")]
5868 pub project: ::prost::alloc::string::String,
5869 #[prost(message, optional, tag = "100")]
5870 pub body: ::core::option::Option<BackupRun>,
5871}
5872#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5873pub struct SqlBackupRunsListRequest {
5874 #[prost(string, tag = "1")]
5877 pub instance: ::prost::alloc::string::String,
5878 #[prost(int32, tag = "2")]
5880 pub max_results: i32,
5881 #[prost(string, tag = "3")]
5884 pub page_token: ::prost::alloc::string::String,
5885 #[prost(string, tag = "4")]
5887 pub project: ::prost::alloc::string::String,
5888}
5889#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5890pub struct SqlDatabasesDeleteRequest {
5891 #[prost(string, tag = "1")]
5893 pub database: ::prost::alloc::string::String,
5894 #[prost(string, tag = "2")]
5896 pub instance: ::prost::alloc::string::String,
5897 #[prost(string, tag = "3")]
5899 pub project: ::prost::alloc::string::String,
5900}
5901#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5902pub struct SqlDatabasesGetRequest {
5903 #[prost(string, tag = "1")]
5905 pub database: ::prost::alloc::string::String,
5906 #[prost(string, tag = "2")]
5908 pub instance: ::prost::alloc::string::String,
5909 #[prost(string, tag = "3")]
5911 pub project: ::prost::alloc::string::String,
5912}
5913#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5914pub struct SqlDatabasesInsertRequest {
5915 #[prost(string, tag = "1")]
5917 pub instance: ::prost::alloc::string::String,
5918 #[prost(string, tag = "2")]
5920 pub project: ::prost::alloc::string::String,
5921 #[prost(message, optional, tag = "100")]
5922 pub body: ::core::option::Option<Database>,
5923}
5924#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5925pub struct SqlDatabasesListRequest {
5926 #[prost(string, tag = "1")]
5928 pub instance: ::prost::alloc::string::String,
5929 #[prost(string, tag = "2")]
5931 pub project: ::prost::alloc::string::String,
5932}
5933#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5934pub struct SqlDatabasesUpdateRequest {
5935 #[prost(string, tag = "1")]
5937 pub database: ::prost::alloc::string::String,
5938 #[prost(string, tag = "2")]
5940 pub instance: ::prost::alloc::string::String,
5941 #[prost(string, tag = "3")]
5943 pub project: ::prost::alloc::string::String,
5944 #[prost(message, optional, tag = "100")]
5945 pub body: ::core::option::Option<Database>,
5946}
5947#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5948pub struct SqlFlagsListRequest {
5949 #[prost(string, tag = "1")]
5952 pub database_version: ::prost::alloc::string::String,
5953 #[prost(enumeration = "SqlFlagScope", optional, tag = "3")]
5956 pub flag_scope: ::core::option::Option<i32>,
5957}
5958#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5959pub struct SqlInstancesAddServerCaRequest {
5960 #[prost(string, tag = "1")]
5962 pub instance: ::prost::alloc::string::String,
5963 #[prost(string, tag = "2")]
5965 pub project: ::prost::alloc::string::String,
5966}
5967#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5969pub struct SqlInstancesAddServerCertificateRequest {
5970 #[prost(string, tag = "1")]
5972 pub instance: ::prost::alloc::string::String,
5973 #[prost(string, tag = "2")]
5975 pub project: ::prost::alloc::string::String,
5976}
5977#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5979pub struct SqlInstancesAddEntraIdCertificateRequest {
5980 #[prost(string, tag = "1")]
5982 pub instance: ::prost::alloc::string::String,
5983 #[prost(string, tag = "2")]
5985 pub project: ::prost::alloc::string::String,
5986}
5987#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5988pub struct SqlInstancesCloneRequest {
5989 #[prost(string, tag = "1")]
5992 pub instance: ::prost::alloc::string::String,
5993 #[prost(string, tag = "2")]
5995 pub project: ::prost::alloc::string::String,
5996 #[prost(message, optional, tag = "100")]
5997 pub body: ::core::option::Option<InstancesCloneRequest>,
5998}
5999#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6000pub struct SqlInstancesDeleteRequest {
6001 #[prost(string, tag = "1")]
6003 pub instance: ::prost::alloc::string::String,
6004 #[prost(string, tag = "2")]
6006 pub project: ::prost::alloc::string::String,
6007 #[prost(bool, optional, tag = "7")]
6009 pub enable_final_backup: ::core::option::Option<bool>,
6010 #[prost(string, tag = "5")]
6012 pub final_backup_description: ::prost::alloc::string::String,
6013 #[prost(oneof = "sql_instances_delete_request::Expiration", tags = "4, 6")]
6014 pub expiration: ::core::option::Option<sql_instances_delete_request::Expiration>,
6015}
6016pub mod sql_instances_delete_request {
6018 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
6019 pub enum Expiration {
6020 #[prost(int64, tag = "4")]
6022 FinalBackupTtlDays(i64),
6023 #[prost(message, tag = "6")]
6026 FinalBackupExpiryTime(::prost_types::Timestamp),
6027 }
6028}
6029#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6030pub struct SqlInstancesDemoteMasterRequest {
6031 #[prost(string, tag = "1")]
6033 pub instance: ::prost::alloc::string::String,
6034 #[prost(string, tag = "2")]
6036 pub project: ::prost::alloc::string::String,
6037 #[prost(message, optional, tag = "100")]
6038 pub body: ::core::option::Option<InstancesDemoteMasterRequest>,
6039}
6040#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6042pub struct SqlInstancesDemoteRequest {
6043 #[prost(string, tag = "1")]
6045 pub instance: ::prost::alloc::string::String,
6046 #[prost(string, tag = "2")]
6048 pub project: ::prost::alloc::string::String,
6049 #[prost(message, optional, tag = "100")]
6051 pub body: ::core::option::Option<InstancesDemoteRequest>,
6052}
6053#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6054pub struct SqlInstancesExportRequest {
6055 #[prost(string, tag = "1")]
6057 pub instance: ::prost::alloc::string::String,
6058 #[prost(string, tag = "2")]
6060 pub project: ::prost::alloc::string::String,
6061 #[prost(message, optional, tag = "100")]
6062 pub body: ::core::option::Option<InstancesExportRequest>,
6063}
6064#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6065pub struct SqlInstancesFailoverRequest {
6066 #[prost(string, tag = "1")]
6068 pub instance: ::prost::alloc::string::String,
6069 #[prost(string, tag = "2")]
6071 pub project: ::prost::alloc::string::String,
6072 #[prost(message, optional, tag = "100")]
6073 pub body: ::core::option::Option<InstancesFailoverRequest>,
6074}
6075#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6076pub struct SqlInstancesGetRequest {
6077 #[prost(string, tag = "1")]
6079 pub instance: ::prost::alloc::string::String,
6080 #[prost(string, tag = "2")]
6082 pub project: ::prost::alloc::string::String,
6083}
6084#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6085pub struct SqlInstancesImportRequest {
6086 #[prost(string, tag = "1")]
6088 pub instance: ::prost::alloc::string::String,
6089 #[prost(string, tag = "2")]
6091 pub project: ::prost::alloc::string::String,
6092 #[prost(message, optional, tag = "100")]
6093 pub body: ::core::option::Option<InstancesImportRequest>,
6094}
6095#[derive(Clone, PartialEq, ::prost::Message)]
6096pub struct SqlInstancesInsertRequest {
6097 #[prost(string, tag = "1")]
6100 pub project: ::prost::alloc::string::String,
6101 #[prost(message, optional, tag = "100")]
6102 pub body: ::core::option::Option<DatabaseInstance>,
6103}
6104#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6105pub struct SqlInstancesListRequest {
6106 #[prost(string, tag = "1")]
6116 pub filter: ::prost::alloc::string::String,
6117 #[prost(uint32, tag = "2")]
6122 pub max_results: u32,
6123 #[prost(string, tag = "3")]
6126 pub page_token: ::prost::alloc::string::String,
6127 #[prost(string, tag = "4")]
6129 pub project: ::prost::alloc::string::String,
6130}
6131#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6132pub struct SqlInstancesListServerCasRequest {
6133 #[prost(string, tag = "1")]
6135 pub instance: ::prost::alloc::string::String,
6136 #[prost(string, tag = "2")]
6138 pub project: ::prost::alloc::string::String,
6139}
6140#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6141pub struct SqlInstancesListServerCertificatesRequest {
6142 #[prost(string, tag = "1")]
6144 pub instance: ::prost::alloc::string::String,
6145 #[prost(string, tag = "2")]
6147 pub project: ::prost::alloc::string::String,
6148}
6149#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6151pub struct SqlInstancesListEntraIdCertificatesRequest {
6152 #[prost(string, tag = "1")]
6154 pub instance: ::prost::alloc::string::String,
6155 #[prost(string, tag = "2")]
6157 pub project: ::prost::alloc::string::String,
6158}
6159#[derive(Clone, PartialEq, ::prost::Message)]
6160pub struct SqlInstancesPatchRequest {
6161 #[prost(string, tag = "1")]
6163 pub instance: ::prost::alloc::string::String,
6164 #[prost(string, tag = "2")]
6166 pub project: ::prost::alloc::string::String,
6167 #[prost(message, optional, tag = "100")]
6168 pub body: ::core::option::Option<DatabaseInstance>,
6169}
6170#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6171pub struct SqlInstancesPromoteReplicaRequest {
6172 #[prost(string, tag = "1")]
6174 pub instance: ::prost::alloc::string::String,
6175 #[prost(string, tag = "2")]
6177 pub project: ::prost::alloc::string::String,
6178 #[prost(bool, tag = "3")]
6185 pub failover: bool,
6186}
6187#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6189pub struct SqlInstancesSwitchoverRequest {
6190 #[prost(string, tag = "1")]
6192 pub instance: ::prost::alloc::string::String,
6193 #[prost(string, tag = "2")]
6195 pub project: ::prost::alloc::string::String,
6196 #[prost(message, optional, tag = "3")]
6200 pub db_timeout: ::core::option::Option<::prost_types::Duration>,
6201}
6202#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6203pub struct SqlInstancesResetSslConfigRequest {
6204 #[prost(string, tag = "1")]
6206 pub instance: ::prost::alloc::string::String,
6207 #[prost(string, tag = "2")]
6209 pub project: ::prost::alloc::string::String,
6210 #[prost(
6212 enumeration = "sql_instances_reset_ssl_config_request::ResetSslMode",
6213 tag = "3"
6214 )]
6215 pub mode: i32,
6216}
6217pub mod sql_instances_reset_ssl_config_request {
6219 #[derive(
6221 Clone,
6222 Copy,
6223 Debug,
6224 PartialEq,
6225 Eq,
6226 Hash,
6227 PartialOrd,
6228 Ord,
6229 ::prost::Enumeration
6230 )]
6231 #[repr(i32)]
6232 pub enum ResetSslMode {
6233 Unspecified = 0,
6235 All = 1,
6237 SyncFromPrimary = 2,
6241 }
6242 impl ResetSslMode {
6243 pub fn as_str_name(&self) -> &'static str {
6248 match self {
6249 Self::Unspecified => "RESET_SSL_MODE_UNSPECIFIED",
6250 Self::All => "ALL",
6251 Self::SyncFromPrimary => "SYNC_FROM_PRIMARY",
6252 }
6253 }
6254 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6256 match value {
6257 "RESET_SSL_MODE_UNSPECIFIED" => Some(Self::Unspecified),
6258 "ALL" => Some(Self::All),
6259 "SYNC_FROM_PRIMARY" => Some(Self::SyncFromPrimary),
6260 _ => None,
6261 }
6262 }
6263 }
6264}
6265#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6266pub struct SqlInstancesRestartRequest {
6267 #[prost(string, tag = "1")]
6269 pub instance: ::prost::alloc::string::String,
6270 #[prost(string, tag = "2")]
6272 pub project: ::prost::alloc::string::String,
6273}
6274#[derive(Clone, PartialEq, ::prost::Message)]
6275pub struct SqlInstancesRestoreBackupRequest {
6276 #[prost(string, tag = "1")]
6278 pub instance: ::prost::alloc::string::String,
6279 #[prost(string, tag = "2")]
6281 pub project: ::prost::alloc::string::String,
6282 #[prost(message, optional, tag = "100")]
6283 pub body: ::core::option::Option<InstancesRestoreBackupRequest>,
6284}
6285#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6286pub struct SqlInstancesRotateServerCaRequest {
6287 #[prost(string, tag = "1")]
6289 pub instance: ::prost::alloc::string::String,
6290 #[prost(string, tag = "2")]
6292 pub project: ::prost::alloc::string::String,
6293 #[prost(message, optional, tag = "100")]
6294 pub body: ::core::option::Option<InstancesRotateServerCaRequest>,
6295}
6296#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6297pub struct SqlInstancesRotateServerCertificateRequest {
6298 #[prost(string, tag = "1")]
6300 pub instance: ::prost::alloc::string::String,
6301 #[prost(string, tag = "2")]
6303 pub project: ::prost::alloc::string::String,
6304 #[prost(message, optional, tag = "100")]
6306 pub body: ::core::option::Option<InstancesRotateServerCertificateRequest>,
6307}
6308#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6310pub struct SqlInstancesRotateEntraIdCertificateRequest {
6311 #[prost(string, tag = "1")]
6313 pub instance: ::prost::alloc::string::String,
6314 #[prost(string, tag = "2")]
6316 pub project: ::prost::alloc::string::String,
6317 #[prost(message, optional, tag = "100")]
6319 pub body: ::core::option::Option<InstancesRotateEntraIdCertificateRequest>,
6320}
6321#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6322pub struct SqlInstancesStartReplicaRequest {
6323 #[prost(string, tag = "1")]
6325 pub instance: ::prost::alloc::string::String,
6326 #[prost(string, tag = "2")]
6328 pub project: ::prost::alloc::string::String,
6329}
6330#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6331pub struct SqlInstancesStopReplicaRequest {
6332 #[prost(string, tag = "1")]
6334 pub instance: ::prost::alloc::string::String,
6335 #[prost(string, tag = "2")]
6337 pub project: ::prost::alloc::string::String,
6338}
6339#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6340pub struct SqlInstancesTruncateLogRequest {
6341 #[prost(string, tag = "1")]
6343 pub instance: ::prost::alloc::string::String,
6344 #[prost(string, tag = "2")]
6346 pub project: ::prost::alloc::string::String,
6347 #[prost(message, optional, tag = "100")]
6348 pub body: ::core::option::Option<InstancesTruncateLogRequest>,
6349}
6350#[derive(Clone, PartialEq, ::prost::Message)]
6351pub struct SqlInstancesUpdateRequest {
6352 #[prost(string, tag = "1")]
6354 pub instance: ::prost::alloc::string::String,
6355 #[prost(string, tag = "2")]
6357 pub project: ::prost::alloc::string::String,
6358 #[prost(message, optional, tag = "100")]
6359 pub body: ::core::option::Option<DatabaseInstance>,
6360}
6361#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6363pub struct SqlInstancesReencryptRequest {
6364 #[prost(string, tag = "1")]
6366 pub instance: ::prost::alloc::string::String,
6367 #[prost(string, tag = "2")]
6369 pub project: ::prost::alloc::string::String,
6370 #[prost(message, optional, tag = "3")]
6372 pub body: ::core::option::Option<InstancesReencryptRequest>,
6373}
6374#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6376pub struct InstancesReencryptRequest {
6377 #[prost(message, optional, tag = "1")]
6379 pub backup_reencryption_config: ::core::option::Option<BackupReencryptionConfig>,
6380}
6381#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6383pub struct BackupReencryptionConfig {
6384 #[prost(int32, optional, tag = "1")]
6386 pub backup_limit: ::core::option::Option<i32>,
6387 #[prost(enumeration = "backup_reencryption_config::BackupType", optional, tag = "2")]
6389 pub backup_type: ::core::option::Option<i32>,
6390}
6391pub mod backup_reencryption_config {
6393 #[derive(
6395 Clone,
6396 Copy,
6397 Debug,
6398 PartialEq,
6399 Eq,
6400 Hash,
6401 PartialOrd,
6402 Ord,
6403 ::prost::Enumeration
6404 )]
6405 #[repr(i32)]
6406 pub enum BackupType {
6407 Unspecified = 0,
6409 Automated = 1,
6411 OnDemand = 2,
6413 }
6414 impl BackupType {
6415 pub fn as_str_name(&self) -> &'static str {
6420 match self {
6421 Self::Unspecified => "BACKUP_TYPE_UNSPECIFIED",
6422 Self::Automated => "AUTOMATED",
6423 Self::OnDemand => "ON_DEMAND",
6424 }
6425 }
6426 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6428 match value {
6429 "BACKUP_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
6430 "AUTOMATED" => Some(Self::Automated),
6431 "ON_DEMAND" => Some(Self::OnDemand),
6432 _ => None,
6433 }
6434 }
6435 }
6436}
6437#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6438pub struct SqlInstancesRescheduleMaintenanceRequest {
6439 #[prost(string, tag = "1")]
6441 pub instance: ::prost::alloc::string::String,
6442 #[prost(string, tag = "2")]
6444 pub project: ::prost::alloc::string::String,
6445 #[prost(message, optional, tag = "100")]
6446 pub body: ::core::option::Option<SqlInstancesRescheduleMaintenanceRequestBody>,
6447}
6448#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6450pub struct SqlInstancesPerformDiskShrinkRequest {
6451 #[prost(string, tag = "1")]
6453 pub instance: ::prost::alloc::string::String,
6454 #[prost(string, tag = "2")]
6456 pub project: ::prost::alloc::string::String,
6457 #[prost(message, optional, tag = "100")]
6459 pub body: ::core::option::Option<PerformDiskShrinkContext>,
6460}
6461#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6463pub struct ExternalSyncSelectedObject {
6464 #[prost(string, tag = "1")]
6466 pub database: ::prost::alloc::string::String,
6467}
6468#[derive(Clone, PartialEq, ::prost::Message)]
6469pub struct SqlInstancesVerifyExternalSyncSettingsRequest {
6470 #[prost(string, tag = "1")]
6472 pub instance: ::prost::alloc::string::String,
6473 #[prost(string, tag = "2")]
6475 pub project: ::prost::alloc::string::String,
6476 #[prost(bool, tag = "3")]
6478 pub verify_connection_only: bool,
6479 #[prost(
6481 enumeration = "sql_instances_verify_external_sync_settings_request::ExternalSyncMode",
6482 tag = "4"
6483 )]
6484 pub sync_mode: i32,
6485 #[prost(bool, tag = "5")]
6487 pub verify_replication_only: bool,
6488 #[prost(
6492 enumeration = "sql_instances_verify_external_sync_settings_request::MigrationType",
6493 tag = "7"
6494 )]
6495 pub migration_type: i32,
6496 #[prost(enumeration = "ExternalSyncParallelLevel", tag = "8")]
6499 pub sync_parallel_level: i32,
6500 #[prost(message, repeated, tag = "9")]
6503 pub selected_objects: ::prost::alloc::vec::Vec<ExternalSyncSelectedObject>,
6504 #[prost(
6505 oneof = "sql_instances_verify_external_sync_settings_request::SyncConfig",
6506 tags = "6"
6507 )]
6508 pub sync_config: ::core::option::Option<
6509 sql_instances_verify_external_sync_settings_request::SyncConfig,
6510 >,
6511}
6512pub mod sql_instances_verify_external_sync_settings_request {
6514 #[derive(
6515 Clone,
6516 Copy,
6517 Debug,
6518 PartialEq,
6519 Eq,
6520 Hash,
6521 PartialOrd,
6522 Ord,
6523 ::prost::Enumeration
6524 )]
6525 #[repr(i32)]
6526 pub enum ExternalSyncMode {
6527 Unspecified = 0,
6529 Online = 1,
6532 Offline = 2,
6535 }
6536 impl ExternalSyncMode {
6537 pub fn as_str_name(&self) -> &'static str {
6542 match self {
6543 Self::Unspecified => "EXTERNAL_SYNC_MODE_UNSPECIFIED",
6544 Self::Online => "ONLINE",
6545 Self::Offline => "OFFLINE",
6546 }
6547 }
6548 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6550 match value {
6551 "EXTERNAL_SYNC_MODE_UNSPECIFIED" => Some(Self::Unspecified),
6552 "ONLINE" => Some(Self::Online),
6553 "OFFLINE" => Some(Self::Offline),
6554 _ => None,
6555 }
6556 }
6557 }
6558 #[derive(
6561 Clone,
6562 Copy,
6563 Debug,
6564 PartialEq,
6565 Eq,
6566 Hash,
6567 PartialOrd,
6568 Ord,
6569 ::prost::Enumeration
6570 )]
6571 #[repr(i32)]
6572 pub enum MigrationType {
6573 Unspecified = 0,
6575 Logical = 1,
6577 Physical = 2,
6579 }
6580 impl MigrationType {
6581 pub fn as_str_name(&self) -> &'static str {
6586 match self {
6587 Self::Unspecified => "MIGRATION_TYPE_UNSPECIFIED",
6588 Self::Logical => "LOGICAL",
6589 Self::Physical => "PHYSICAL",
6590 }
6591 }
6592 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6594 match value {
6595 "MIGRATION_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
6596 "LOGICAL" => Some(Self::Logical),
6597 "PHYSICAL" => Some(Self::Physical),
6598 _ => None,
6599 }
6600 }
6601 }
6602 #[derive(Clone, PartialEq, ::prost::Oneof)]
6603 pub enum SyncConfig {
6604 #[prost(message, tag = "6")]
6606 MysqlSyncConfig(super::MySqlSyncConfig),
6607 }
6608}
6609#[derive(Clone, PartialEq, ::prost::Message)]
6610pub struct SqlInstancesStartExternalSyncRequest {
6611 #[prost(string, tag = "1")]
6613 pub instance: ::prost::alloc::string::String,
6614 #[prost(string, tag = "2")]
6616 pub project: ::prost::alloc::string::String,
6617 #[prost(
6619 enumeration = "sql_instances_verify_external_sync_settings_request::ExternalSyncMode",
6620 tag = "3"
6621 )]
6622 pub sync_mode: i32,
6623 #[prost(bool, tag = "4")]
6625 pub skip_verification: bool,
6626 #[prost(enumeration = "ExternalSyncParallelLevel", tag = "7")]
6629 pub sync_parallel_level: i32,
6630 #[prost(
6634 enumeration = "sql_instances_verify_external_sync_settings_request::MigrationType",
6635 tag = "8"
6636 )]
6637 pub migration_type: i32,
6638 #[prost(bool, tag = "9")]
6643 pub replica_overwrite_enabled: bool,
6644 #[prost(oneof = "sql_instances_start_external_sync_request::SyncConfig", tags = "6")]
6645 pub sync_config: ::core::option::Option<
6646 sql_instances_start_external_sync_request::SyncConfig,
6647 >,
6648}
6649pub mod sql_instances_start_external_sync_request {
6651 #[derive(Clone, PartialEq, ::prost::Oneof)]
6652 pub enum SyncConfig {
6653 #[prost(message, tag = "6")]
6655 MysqlSyncConfig(super::MySqlSyncConfig),
6656 }
6657}
6658#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6660pub struct SqlInstancesResetReplicaSizeRequest {
6661 #[prost(string, tag = "1")]
6663 pub instance: ::prost::alloc::string::String,
6664 #[prost(string, tag = "2")]
6666 pub project: ::prost::alloc::string::String,
6667}
6668#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6669pub struct SqlOperationsGetRequest {
6670 #[prost(string, tag = "1")]
6672 pub operation: ::prost::alloc::string::String,
6673 #[prost(string, tag = "2")]
6675 pub project: ::prost::alloc::string::String,
6676}
6677#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6678pub struct SqlOperationsListRequest {
6679 #[prost(string, tag = "1")]
6681 pub instance: ::prost::alloc::string::String,
6682 #[prost(uint32, tag = "2")]
6684 pub max_results: u32,
6685 #[prost(string, tag = "3")]
6688 pub page_token: ::prost::alloc::string::String,
6689 #[prost(string, tag = "4")]
6691 pub project: ::prost::alloc::string::String,
6692}
6693#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6695pub struct SqlOperationsCancelRequest {
6696 #[prost(string, tag = "1")]
6698 pub operation: ::prost::alloc::string::String,
6699 #[prost(string, tag = "2")]
6701 pub project: ::prost::alloc::string::String,
6702}
6703#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6704pub struct SqlInstancesCreateEphemeralCertRequest {
6705 #[prost(string, tag = "1")]
6707 pub instance: ::prost::alloc::string::String,
6708 #[prost(string, tag = "2")]
6710 pub project: ::prost::alloc::string::String,
6711 #[prost(message, optional, tag = "100")]
6712 pub body: ::core::option::Option<SslCertsCreateEphemeralRequest>,
6713}
6714#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6715pub struct SqlSslCertsDeleteRequest {
6716 #[prost(string, tag = "1")]
6718 pub instance: ::prost::alloc::string::String,
6719 #[prost(string, tag = "2")]
6721 pub project: ::prost::alloc::string::String,
6722 #[prost(string, tag = "3")]
6724 pub sha1_fingerprint: ::prost::alloc::string::String,
6725}
6726#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6727pub struct SqlSslCertsGetRequest {
6728 #[prost(string, tag = "1")]
6730 pub instance: ::prost::alloc::string::String,
6731 #[prost(string, tag = "2")]
6733 pub project: ::prost::alloc::string::String,
6734 #[prost(string, tag = "3")]
6736 pub sha1_fingerprint: ::prost::alloc::string::String,
6737}
6738#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6739pub struct SqlSslCertsInsertRequest {
6740 #[prost(string, tag = "1")]
6742 pub instance: ::prost::alloc::string::String,
6743 #[prost(string, tag = "2")]
6745 pub project: ::prost::alloc::string::String,
6746 #[prost(message, optional, tag = "100")]
6747 pub body: ::core::option::Option<SslCertsInsertRequest>,
6748}
6749#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6750pub struct SqlSslCertsListRequest {
6751 #[prost(string, tag = "1")]
6753 pub instance: ::prost::alloc::string::String,
6754 #[prost(string, tag = "2")]
6756 pub project: ::prost::alloc::string::String,
6757}
6758#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6760pub struct SqlInstancesGetDiskShrinkConfigRequest {
6761 #[prost(string, tag = "1")]
6763 pub instance: ::prost::alloc::string::String,
6764 #[prost(string, tag = "2")]
6766 pub project: ::prost::alloc::string::String,
6767}
6768#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6770pub struct SqlInstancesGetLatestRecoveryTimeRequest {
6771 #[prost(string, tag = "1")]
6773 pub instance: ::prost::alloc::string::String,
6774 #[prost(string, tag = "2")]
6776 pub project: ::prost::alloc::string::String,
6777 #[prost(message, optional, tag = "3")]
6780 pub source_instance_deletion_time: ::core::option::Option<::prost_types::Timestamp>,
6781}
6782#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6784pub struct SqlInstancesGetLatestRecoveryTimeResponse {
6785 #[prost(string, tag = "1")]
6787 pub kind: ::prost::alloc::string::String,
6788 #[prost(message, optional, tag = "2")]
6790 pub latest_recovery_time: ::core::option::Option<::prost_types::Timestamp>,
6791 #[prost(message, optional, tag = "3")]
6793 pub earliest_recovery_time: ::core::option::Option<::prost_types::Timestamp>,
6794}
6795#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6797pub struct SqlInstancesExecuteSqlRequest {
6798 #[prost(string, tag = "1")]
6800 pub instance: ::prost::alloc::string::String,
6801 #[prost(string, tag = "2")]
6803 pub project: ::prost::alloc::string::String,
6804 #[prost(message, optional, tag = "100")]
6806 pub body: ::core::option::Option<ExecuteSqlPayload>,
6807}
6808#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6810pub struct SqlInstancesReleaseSsrsLeaseRequest {
6811 #[prost(string, tag = "1")]
6816 pub instance: ::prost::alloc::string::String,
6817 #[prost(string, tag = "2")]
6820 pub project: ::prost::alloc::string::String,
6821}
6822#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6824pub struct SqlInstancesReleaseSsrsLeaseResponse {
6825 #[prost(string, tag = "1")]
6827 pub operation_id: ::prost::alloc::string::String,
6828}
6829#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6831pub struct ExecuteSqlPayload {
6832 #[prost(string, tag = "1")]
6836 pub user: ::prost::alloc::string::String,
6837 #[prost(string, tag = "2")]
6840 pub sql_statement: ::prost::alloc::string::String,
6841 #[prost(string, tag = "3")]
6843 pub database: ::prost::alloc::string::String,
6844 #[prost(int64, tag = "10")]
6846 pub row_limit: i64,
6847 #[prost(enumeration = "execute_sql_payload::PartialResultMode", tag = "13")]
6851 pub partial_result_mode: i32,
6852 #[prost(string, tag = "16")]
6856 pub application: ::prost::alloc::string::String,
6857 #[prost(oneof = "execute_sql_payload::UserPassword", tags = "11")]
6859 pub user_password: ::core::option::Option<execute_sql_payload::UserPassword>,
6860}
6861pub mod execute_sql_payload {
6863 #[derive(
6866 Clone,
6867 Copy,
6868 Debug,
6869 PartialEq,
6870 Eq,
6871 Hash,
6872 PartialOrd,
6873 Ord,
6874 ::prost::Enumeration
6875 )]
6876 #[repr(i32)]
6877 pub enum PartialResultMode {
6878 Unspecified = 0,
6880 FailPartialResult = 1,
6883 AllowPartialResult = 2,
6887 }
6888 impl PartialResultMode {
6889 pub fn as_str_name(&self) -> &'static str {
6894 match self {
6895 Self::Unspecified => "PARTIAL_RESULT_MODE_UNSPECIFIED",
6896 Self::FailPartialResult => "FAIL_PARTIAL_RESULT",
6897 Self::AllowPartialResult => "ALLOW_PARTIAL_RESULT",
6898 }
6899 }
6900 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
6902 match value {
6903 "PARTIAL_RESULT_MODE_UNSPECIFIED" => Some(Self::Unspecified),
6904 "FAIL_PARTIAL_RESULT" => Some(Self::FailPartialResult),
6905 "ALLOW_PARTIAL_RESULT" => Some(Self::AllowPartialResult),
6906 _ => None,
6907 }
6908 }
6909 }
6910 #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
6912 pub enum UserPassword {
6913 #[prost(bool, tag = "11")]
6917 AutoIamAuthn(bool),
6918 }
6919}
6920#[derive(Clone, PartialEq, ::prost::Message)]
6922pub struct SqlInstancesExecuteSqlResponse {
6923 #[prost(message, repeated, tag = "9")]
6929 pub messages: ::prost::alloc::vec::Vec<sql_instances_execute_sql_response::Message>,
6930 #[prost(message, optional, tag = "6")]
6933 pub metadata: ::core::option::Option<Metadata>,
6934 #[prost(message, repeated, tag = "7")]
6936 pub results: ::prost::alloc::vec::Vec<QueryResult>,
6937 #[prost(message, optional, tag = "8")]
6939 pub status: ::core::option::Option<super::super::super::rpc::Status>,
6940}
6941pub mod sql_instances_execute_sql_response {
6943 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6945 pub struct Message {
6946 #[prost(string, optional, tag = "1")]
6951 pub message: ::core::option::Option<::prost::alloc::string::String>,
6952 #[prost(string, optional, tag = "2")]
6955 pub severity: ::core::option::Option<::prost::alloc::string::String>,
6956 }
6957}
6958#[derive(Clone, PartialEq, ::prost::Message)]
6960pub struct QueryResult {
6961 #[prost(message, repeated, tag = "1")]
6964 pub columns: ::prost::alloc::vec::Vec<Column>,
6965 #[prost(message, repeated, tag = "2")]
6967 pub rows: ::prost::alloc::vec::Vec<Row>,
6968 #[prost(string, tag = "3")]
6970 pub message: ::prost::alloc::string::String,
6971 #[prost(bool, tag = "4")]
6974 pub partial_result: bool,
6975 #[prost(message, optional, tag = "8")]
6977 pub status: ::core::option::Option<super::super::super::rpc::Status>,
6978}
6979#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6981pub struct Column {
6982 #[prost(string, tag = "1")]
6984 pub name: ::prost::alloc::string::String,
6985 #[prost(string, tag = "2")]
6987 pub r#type: ::prost::alloc::string::String,
6988}
6989#[derive(Clone, PartialEq, ::prost::Message)]
6991pub struct Row {
6992 #[prost(message, repeated, tag = "1")]
6994 pub values: ::prost::alloc::vec::Vec<Value>,
6995}
6996#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
6998pub struct Value {
6999 #[prost(string, tag = "1")]
7001 pub value: ::prost::alloc::string::String,
7002 #[prost(bool, tag = "2")]
7004 pub null_value: bool,
7005}
7006#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
7009pub struct Metadata {
7010 #[prost(message, optional, tag = "1")]
7012 pub sql_statement_execution_time: ::core::option::Option<::prost_types::Duration>,
7013}
7014#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
7016pub struct SqlInstancesAcquireSsrsLeaseRequest {
7017 #[prost(string, tag = "1")]
7022 pub instance: ::prost::alloc::string::String,
7023 #[prost(string, tag = "2")]
7026 pub project: ::prost::alloc::string::String,
7027 #[prost(message, optional, tag = "100")]
7029 pub body: ::core::option::Option<InstancesAcquireSsrsLeaseRequest>,
7030}
7031#[derive(Clone, PartialEq, ::prost::Message)]
7033pub struct SqlInstancesPreCheckMajorVersionUpgradeRequest {
7034 #[prost(string, tag = "1")]
7036 pub instance: ::prost::alloc::string::String,
7037 #[prost(string, tag = "2")]
7039 pub project: ::prost::alloc::string::String,
7040 #[prost(message, optional, tag = "3")]
7043 pub body: ::core::option::Option<InstancesPreCheckMajorVersionUpgradeRequest>,
7044}
7045#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
7047pub struct SqlInstancesAcquireSsrsLeaseResponse {
7048 #[prost(string, optional, tag = "1")]
7050 pub operation_id: ::core::option::Option<::prost::alloc::string::String>,
7051}
7052#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
7055pub struct SqlInstancesPointInTimeRestoreRequest {
7056 #[prost(string, tag = "1")]
7059 pub parent: ::prost::alloc::string::String,
7060 #[prost(message, optional, tag = "100")]
7063 pub context: ::core::option::Option<PointInTimeRestoreContext>,
7064}
7065#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
7067#[repr(i32)]
7068pub enum ExternalSyncParallelLevel {
7069 Unspecified = 0,
7071 Min = 1,
7073 Optimal = 2,
7075 Max = 3,
7077}
7078impl ExternalSyncParallelLevel {
7079 pub fn as_str_name(&self) -> &'static str {
7084 match self {
7085 Self::Unspecified => "EXTERNAL_SYNC_PARALLEL_LEVEL_UNSPECIFIED",
7086 Self::Min => "MIN",
7087 Self::Optimal => "OPTIMAL",
7088 Self::Max => "MAX",
7089 }
7090 }
7091 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
7093 match value {
7094 "EXTERNAL_SYNC_PARALLEL_LEVEL_UNSPECIFIED" => Some(Self::Unspecified),
7095 "MIN" => Some(Self::Min),
7096 "OPTIMAL" => Some(Self::Optimal),
7097 "MAX" => Some(Self::Max),
7098 _ => None,
7099 }
7100 }
7101}
7102pub mod sql_backup_runs_service_client {
7104 #![allow(
7105 unused_variables,
7106 dead_code,
7107 missing_docs,
7108 clippy::wildcard_imports,
7109 clippy::let_unit_value,
7110 )]
7111 use tonic::codegen::*;
7112 use tonic::codegen::http::Uri;
7113 #[derive(Debug, Clone)]
7114 pub struct SqlBackupRunsServiceClient<T> {
7115 inner: tonic::client::Grpc<T>,
7116 }
7117 impl<T> SqlBackupRunsServiceClient<T>
7118 where
7119 T: tonic::client::GrpcService<tonic::body::Body>,
7120 T::Error: Into<StdError>,
7121 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
7122 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
7123 {
7124 pub fn new(inner: T) -> Self {
7125 let inner = tonic::client::Grpc::new(inner);
7126 Self { inner }
7127 }
7128 pub fn with_origin(inner: T, origin: Uri) -> Self {
7129 let inner = tonic::client::Grpc::with_origin(inner, origin);
7130 Self { inner }
7131 }
7132 pub fn with_interceptor<F>(
7133 inner: T,
7134 interceptor: F,
7135 ) -> SqlBackupRunsServiceClient<InterceptedService<T, F>>
7136 where
7137 F: tonic::service::Interceptor,
7138 T::ResponseBody: Default,
7139 T: tonic::codegen::Service<
7140 http::Request<tonic::body::Body>,
7141 Response = http::Response<
7142 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
7143 >,
7144 >,
7145 <T as tonic::codegen::Service<
7146 http::Request<tonic::body::Body>,
7147 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
7148 {
7149 SqlBackupRunsServiceClient::new(InterceptedService::new(inner, interceptor))
7150 }
7151 #[must_use]
7156 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7157 self.inner = self.inner.send_compressed(encoding);
7158 self
7159 }
7160 #[must_use]
7162 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7163 self.inner = self.inner.accept_compressed(encoding);
7164 self
7165 }
7166 #[must_use]
7170 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7171 self.inner = self.inner.max_decoding_message_size(limit);
7172 self
7173 }
7174 #[must_use]
7178 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7179 self.inner = self.inner.max_encoding_message_size(limit);
7180 self
7181 }
7182 pub async fn delete(
7184 &mut self,
7185 request: impl tonic::IntoRequest<super::SqlBackupRunsDeleteRequest>,
7186 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7187 self.inner
7188 .ready()
7189 .await
7190 .map_err(|e| {
7191 tonic::Status::unknown(
7192 format!("Service was not ready: {}", e.into()),
7193 )
7194 })?;
7195 let codec = tonic_prost::ProstCodec::default();
7196 let path = http::uri::PathAndQuery::from_static(
7197 "/google.cloud.sql.v1beta4.SqlBackupRunsService/Delete",
7198 );
7199 let mut req = request.into_request();
7200 req.extensions_mut()
7201 .insert(
7202 GrpcMethod::new(
7203 "google.cloud.sql.v1beta4.SqlBackupRunsService",
7204 "Delete",
7205 ),
7206 );
7207 self.inner.unary(req, path, codec).await
7208 }
7209 pub async fn get(
7211 &mut self,
7212 request: impl tonic::IntoRequest<super::SqlBackupRunsGetRequest>,
7213 ) -> std::result::Result<tonic::Response<super::BackupRun>, tonic::Status> {
7214 self.inner
7215 .ready()
7216 .await
7217 .map_err(|e| {
7218 tonic::Status::unknown(
7219 format!("Service was not ready: {}", e.into()),
7220 )
7221 })?;
7222 let codec = tonic_prost::ProstCodec::default();
7223 let path = http::uri::PathAndQuery::from_static(
7224 "/google.cloud.sql.v1beta4.SqlBackupRunsService/Get",
7225 );
7226 let mut req = request.into_request();
7227 req.extensions_mut()
7228 .insert(
7229 GrpcMethod::new(
7230 "google.cloud.sql.v1beta4.SqlBackupRunsService",
7231 "Get",
7232 ),
7233 );
7234 self.inner.unary(req, path, codec).await
7235 }
7236 pub async fn insert(
7238 &mut self,
7239 request: impl tonic::IntoRequest<super::SqlBackupRunsInsertRequest>,
7240 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7241 self.inner
7242 .ready()
7243 .await
7244 .map_err(|e| {
7245 tonic::Status::unknown(
7246 format!("Service was not ready: {}", e.into()),
7247 )
7248 })?;
7249 let codec = tonic_prost::ProstCodec::default();
7250 let path = http::uri::PathAndQuery::from_static(
7251 "/google.cloud.sql.v1beta4.SqlBackupRunsService/Insert",
7252 );
7253 let mut req = request.into_request();
7254 req.extensions_mut()
7255 .insert(
7256 GrpcMethod::new(
7257 "google.cloud.sql.v1beta4.SqlBackupRunsService",
7258 "Insert",
7259 ),
7260 );
7261 self.inner.unary(req, path, codec).await
7262 }
7263 pub async fn list(
7267 &mut self,
7268 request: impl tonic::IntoRequest<super::SqlBackupRunsListRequest>,
7269 ) -> std::result::Result<
7270 tonic::Response<super::BackupRunsListResponse>,
7271 tonic::Status,
7272 > {
7273 self.inner
7274 .ready()
7275 .await
7276 .map_err(|e| {
7277 tonic::Status::unknown(
7278 format!("Service was not ready: {}", e.into()),
7279 )
7280 })?;
7281 let codec = tonic_prost::ProstCodec::default();
7282 let path = http::uri::PathAndQuery::from_static(
7283 "/google.cloud.sql.v1beta4.SqlBackupRunsService/List",
7284 );
7285 let mut req = request.into_request();
7286 req.extensions_mut()
7287 .insert(
7288 GrpcMethod::new(
7289 "google.cloud.sql.v1beta4.SqlBackupRunsService",
7290 "List",
7291 ),
7292 );
7293 self.inner.unary(req, path, codec).await
7294 }
7295 }
7296}
7297pub mod sql_databases_service_client {
7299 #![allow(
7300 unused_variables,
7301 dead_code,
7302 missing_docs,
7303 clippy::wildcard_imports,
7304 clippy::let_unit_value,
7305 )]
7306 use tonic::codegen::*;
7307 use tonic::codegen::http::Uri;
7308 #[derive(Debug, Clone)]
7309 pub struct SqlDatabasesServiceClient<T> {
7310 inner: tonic::client::Grpc<T>,
7311 }
7312 impl<T> SqlDatabasesServiceClient<T>
7313 where
7314 T: tonic::client::GrpcService<tonic::body::Body>,
7315 T::Error: Into<StdError>,
7316 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
7317 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
7318 {
7319 pub fn new(inner: T) -> Self {
7320 let inner = tonic::client::Grpc::new(inner);
7321 Self { inner }
7322 }
7323 pub fn with_origin(inner: T, origin: Uri) -> Self {
7324 let inner = tonic::client::Grpc::with_origin(inner, origin);
7325 Self { inner }
7326 }
7327 pub fn with_interceptor<F>(
7328 inner: T,
7329 interceptor: F,
7330 ) -> SqlDatabasesServiceClient<InterceptedService<T, F>>
7331 where
7332 F: tonic::service::Interceptor,
7333 T::ResponseBody: Default,
7334 T: tonic::codegen::Service<
7335 http::Request<tonic::body::Body>,
7336 Response = http::Response<
7337 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
7338 >,
7339 >,
7340 <T as tonic::codegen::Service<
7341 http::Request<tonic::body::Body>,
7342 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
7343 {
7344 SqlDatabasesServiceClient::new(InterceptedService::new(inner, interceptor))
7345 }
7346 #[must_use]
7351 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7352 self.inner = self.inner.send_compressed(encoding);
7353 self
7354 }
7355 #[must_use]
7357 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7358 self.inner = self.inner.accept_compressed(encoding);
7359 self
7360 }
7361 #[must_use]
7365 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7366 self.inner = self.inner.max_decoding_message_size(limit);
7367 self
7368 }
7369 #[must_use]
7373 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7374 self.inner = self.inner.max_encoding_message_size(limit);
7375 self
7376 }
7377 pub async fn delete(
7379 &mut self,
7380 request: impl tonic::IntoRequest<super::SqlDatabasesDeleteRequest>,
7381 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7382 self.inner
7383 .ready()
7384 .await
7385 .map_err(|e| {
7386 tonic::Status::unknown(
7387 format!("Service was not ready: {}", e.into()),
7388 )
7389 })?;
7390 let codec = tonic_prost::ProstCodec::default();
7391 let path = http::uri::PathAndQuery::from_static(
7392 "/google.cloud.sql.v1beta4.SqlDatabasesService/Delete",
7393 );
7394 let mut req = request.into_request();
7395 req.extensions_mut()
7396 .insert(
7397 GrpcMethod::new(
7398 "google.cloud.sql.v1beta4.SqlDatabasesService",
7399 "Delete",
7400 ),
7401 );
7402 self.inner.unary(req, path, codec).await
7403 }
7404 pub async fn get(
7407 &mut self,
7408 request: impl tonic::IntoRequest<super::SqlDatabasesGetRequest>,
7409 ) -> std::result::Result<tonic::Response<super::Database>, tonic::Status> {
7410 self.inner
7411 .ready()
7412 .await
7413 .map_err(|e| {
7414 tonic::Status::unknown(
7415 format!("Service was not ready: {}", e.into()),
7416 )
7417 })?;
7418 let codec = tonic_prost::ProstCodec::default();
7419 let path = http::uri::PathAndQuery::from_static(
7420 "/google.cloud.sql.v1beta4.SqlDatabasesService/Get",
7421 );
7422 let mut req = request.into_request();
7423 req.extensions_mut()
7424 .insert(
7425 GrpcMethod::new(
7426 "google.cloud.sql.v1beta4.SqlDatabasesService",
7427 "Get",
7428 ),
7429 );
7430 self.inner.unary(req, path, codec).await
7431 }
7432 pub async fn insert(
7437 &mut self,
7438 request: impl tonic::IntoRequest<super::SqlDatabasesInsertRequest>,
7439 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7440 self.inner
7441 .ready()
7442 .await
7443 .map_err(|e| {
7444 tonic::Status::unknown(
7445 format!("Service was not ready: {}", e.into()),
7446 )
7447 })?;
7448 let codec = tonic_prost::ProstCodec::default();
7449 let path = http::uri::PathAndQuery::from_static(
7450 "/google.cloud.sql.v1beta4.SqlDatabasesService/Insert",
7451 );
7452 let mut req = request.into_request();
7453 req.extensions_mut()
7454 .insert(
7455 GrpcMethod::new(
7456 "google.cloud.sql.v1beta4.SqlDatabasesService",
7457 "Insert",
7458 ),
7459 );
7460 self.inner.unary(req, path, codec).await
7461 }
7462 pub async fn list(
7464 &mut self,
7465 request: impl tonic::IntoRequest<super::SqlDatabasesListRequest>,
7466 ) -> std::result::Result<
7467 tonic::Response<super::DatabasesListResponse>,
7468 tonic::Status,
7469 > {
7470 self.inner
7471 .ready()
7472 .await
7473 .map_err(|e| {
7474 tonic::Status::unknown(
7475 format!("Service was not ready: {}", e.into()),
7476 )
7477 })?;
7478 let codec = tonic_prost::ProstCodec::default();
7479 let path = http::uri::PathAndQuery::from_static(
7480 "/google.cloud.sql.v1beta4.SqlDatabasesService/List",
7481 );
7482 let mut req = request.into_request();
7483 req.extensions_mut()
7484 .insert(
7485 GrpcMethod::new(
7486 "google.cloud.sql.v1beta4.SqlDatabasesService",
7487 "List",
7488 ),
7489 );
7490 self.inner.unary(req, path, codec).await
7491 }
7492 pub async fn patch(
7495 &mut self,
7496 request: impl tonic::IntoRequest<super::SqlDatabasesUpdateRequest>,
7497 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7498 self.inner
7499 .ready()
7500 .await
7501 .map_err(|e| {
7502 tonic::Status::unknown(
7503 format!("Service was not ready: {}", e.into()),
7504 )
7505 })?;
7506 let codec = tonic_prost::ProstCodec::default();
7507 let path = http::uri::PathAndQuery::from_static(
7508 "/google.cloud.sql.v1beta4.SqlDatabasesService/Patch",
7509 );
7510 let mut req = request.into_request();
7511 req.extensions_mut()
7512 .insert(
7513 GrpcMethod::new(
7514 "google.cloud.sql.v1beta4.SqlDatabasesService",
7515 "Patch",
7516 ),
7517 );
7518 self.inner.unary(req, path, codec).await
7519 }
7520 pub async fn update(
7523 &mut self,
7524 request: impl tonic::IntoRequest<super::SqlDatabasesUpdateRequest>,
7525 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7526 self.inner
7527 .ready()
7528 .await
7529 .map_err(|e| {
7530 tonic::Status::unknown(
7531 format!("Service was not ready: {}", e.into()),
7532 )
7533 })?;
7534 let codec = tonic_prost::ProstCodec::default();
7535 let path = http::uri::PathAndQuery::from_static(
7536 "/google.cloud.sql.v1beta4.SqlDatabasesService/Update",
7537 );
7538 let mut req = request.into_request();
7539 req.extensions_mut()
7540 .insert(
7541 GrpcMethod::new(
7542 "google.cloud.sql.v1beta4.SqlDatabasesService",
7543 "Update",
7544 ),
7545 );
7546 self.inner.unary(req, path, codec).await
7547 }
7548 }
7549}
7550pub mod sql_flags_service_client {
7552 #![allow(
7553 unused_variables,
7554 dead_code,
7555 missing_docs,
7556 clippy::wildcard_imports,
7557 clippy::let_unit_value,
7558 )]
7559 use tonic::codegen::*;
7560 use tonic::codegen::http::Uri;
7561 #[derive(Debug, Clone)]
7562 pub struct SqlFlagsServiceClient<T> {
7563 inner: tonic::client::Grpc<T>,
7564 }
7565 impl<T> SqlFlagsServiceClient<T>
7566 where
7567 T: tonic::client::GrpcService<tonic::body::Body>,
7568 T::Error: Into<StdError>,
7569 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
7570 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
7571 {
7572 pub fn new(inner: T) -> Self {
7573 let inner = tonic::client::Grpc::new(inner);
7574 Self { inner }
7575 }
7576 pub fn with_origin(inner: T, origin: Uri) -> Self {
7577 let inner = tonic::client::Grpc::with_origin(inner, origin);
7578 Self { inner }
7579 }
7580 pub fn with_interceptor<F>(
7581 inner: T,
7582 interceptor: F,
7583 ) -> SqlFlagsServiceClient<InterceptedService<T, F>>
7584 where
7585 F: tonic::service::Interceptor,
7586 T::ResponseBody: Default,
7587 T: tonic::codegen::Service<
7588 http::Request<tonic::body::Body>,
7589 Response = http::Response<
7590 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
7591 >,
7592 >,
7593 <T as tonic::codegen::Service<
7594 http::Request<tonic::body::Body>,
7595 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
7596 {
7597 SqlFlagsServiceClient::new(InterceptedService::new(inner, interceptor))
7598 }
7599 #[must_use]
7604 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7605 self.inner = self.inner.send_compressed(encoding);
7606 self
7607 }
7608 #[must_use]
7610 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7611 self.inner = self.inner.accept_compressed(encoding);
7612 self
7613 }
7614 #[must_use]
7618 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7619 self.inner = self.inner.max_decoding_message_size(limit);
7620 self
7621 }
7622 #[must_use]
7626 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7627 self.inner = self.inner.max_encoding_message_size(limit);
7628 self
7629 }
7630 pub async fn list(
7632 &mut self,
7633 request: impl tonic::IntoRequest<super::SqlFlagsListRequest>,
7634 ) -> std::result::Result<
7635 tonic::Response<super::FlagsListResponse>,
7636 tonic::Status,
7637 > {
7638 self.inner
7639 .ready()
7640 .await
7641 .map_err(|e| {
7642 tonic::Status::unknown(
7643 format!("Service was not ready: {}", e.into()),
7644 )
7645 })?;
7646 let codec = tonic_prost::ProstCodec::default();
7647 let path = http::uri::PathAndQuery::from_static(
7648 "/google.cloud.sql.v1beta4.SqlFlagsService/List",
7649 );
7650 let mut req = request.into_request();
7651 req.extensions_mut()
7652 .insert(
7653 GrpcMethod::new("google.cloud.sql.v1beta4.SqlFlagsService", "List"),
7654 );
7655 self.inner.unary(req, path, codec).await
7656 }
7657 }
7658}
7659pub mod sql_instances_service_client {
7661 #![allow(
7662 unused_variables,
7663 dead_code,
7664 missing_docs,
7665 clippy::wildcard_imports,
7666 clippy::let_unit_value,
7667 )]
7668 use tonic::codegen::*;
7669 use tonic::codegen::http::Uri;
7670 #[derive(Debug, Clone)]
7671 pub struct SqlInstancesServiceClient<T> {
7672 inner: tonic::client::Grpc<T>,
7673 }
7674 impl<T> SqlInstancesServiceClient<T>
7675 where
7676 T: tonic::client::GrpcService<tonic::body::Body>,
7677 T::Error: Into<StdError>,
7678 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
7679 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
7680 {
7681 pub fn new(inner: T) -> Self {
7682 let inner = tonic::client::Grpc::new(inner);
7683 Self { inner }
7684 }
7685 pub fn with_origin(inner: T, origin: Uri) -> Self {
7686 let inner = tonic::client::Grpc::with_origin(inner, origin);
7687 Self { inner }
7688 }
7689 pub fn with_interceptor<F>(
7690 inner: T,
7691 interceptor: F,
7692 ) -> SqlInstancesServiceClient<InterceptedService<T, F>>
7693 where
7694 F: tonic::service::Interceptor,
7695 T::ResponseBody: Default,
7696 T: tonic::codegen::Service<
7697 http::Request<tonic::body::Body>,
7698 Response = http::Response<
7699 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
7700 >,
7701 >,
7702 <T as tonic::codegen::Service<
7703 http::Request<tonic::body::Body>,
7704 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
7705 {
7706 SqlInstancesServiceClient::new(InterceptedService::new(inner, interceptor))
7707 }
7708 #[must_use]
7713 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
7714 self.inner = self.inner.send_compressed(encoding);
7715 self
7716 }
7717 #[must_use]
7719 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
7720 self.inner = self.inner.accept_compressed(encoding);
7721 self
7722 }
7723 #[must_use]
7727 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
7728 self.inner = self.inner.max_decoding_message_size(limit);
7729 self
7730 }
7731 #[must_use]
7735 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
7736 self.inner = self.inner.max_encoding_message_size(limit);
7737 self
7738 }
7739 pub async fn add_server_ca(
7747 &mut self,
7748 request: impl tonic::IntoRequest<super::SqlInstancesAddServerCaRequest>,
7749 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7750 self.inner
7751 .ready()
7752 .await
7753 .map_err(|e| {
7754 tonic::Status::unknown(
7755 format!("Service was not ready: {}", e.into()),
7756 )
7757 })?;
7758 let codec = tonic_prost::ProstCodec::default();
7759 let path = http::uri::PathAndQuery::from_static(
7760 "/google.cloud.sql.v1beta4.SqlInstancesService/AddServerCa",
7761 );
7762 let mut req = request.into_request();
7763 req.extensions_mut()
7764 .insert(
7765 GrpcMethod::new(
7766 "google.cloud.sql.v1beta4.SqlInstancesService",
7767 "AddServerCa",
7768 ),
7769 );
7770 self.inner.unary(req, path, codec).await
7771 }
7772 pub async fn add_server_certificate(
7780 &mut self,
7781 request: impl tonic::IntoRequest<
7782 super::SqlInstancesAddServerCertificateRequest,
7783 >,
7784 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7785 self.inner
7786 .ready()
7787 .await
7788 .map_err(|e| {
7789 tonic::Status::unknown(
7790 format!("Service was not ready: {}", e.into()),
7791 )
7792 })?;
7793 let codec = tonic_prost::ProstCodec::default();
7794 let path = http::uri::PathAndQuery::from_static(
7795 "/google.cloud.sql.v1beta4.SqlInstancesService/AddServerCertificate",
7796 );
7797 let mut req = request.into_request();
7798 req.extensions_mut()
7799 .insert(
7800 GrpcMethod::new(
7801 "google.cloud.sql.v1beta4.SqlInstancesService",
7802 "AddServerCertificate",
7803 ),
7804 );
7805 self.inner.unary(req, path, codec).await
7806 }
7807 pub async fn add_entra_id_certificate(
7811 &mut self,
7812 request: impl tonic::IntoRequest<
7813 super::SqlInstancesAddEntraIdCertificateRequest,
7814 >,
7815 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7816 self.inner
7817 .ready()
7818 .await
7819 .map_err(|e| {
7820 tonic::Status::unknown(
7821 format!("Service was not ready: {}", e.into()),
7822 )
7823 })?;
7824 let codec = tonic_prost::ProstCodec::default();
7825 let path = http::uri::PathAndQuery::from_static(
7826 "/google.cloud.sql.v1beta4.SqlInstancesService/AddEntraIdCertificate",
7827 );
7828 let mut req = request.into_request();
7829 req.extensions_mut()
7830 .insert(
7831 GrpcMethod::new(
7832 "google.cloud.sql.v1beta4.SqlInstancesService",
7833 "AddEntraIdCertificate",
7834 ),
7835 );
7836 self.inner.unary(req, path, codec).await
7837 }
7838 pub async fn clone(
7841 &mut self,
7842 request: impl tonic::IntoRequest<super::SqlInstancesCloneRequest>,
7843 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7844 self.inner
7845 .ready()
7846 .await
7847 .map_err(|e| {
7848 tonic::Status::unknown(
7849 format!("Service was not ready: {}", e.into()),
7850 )
7851 })?;
7852 let codec = tonic_prost::ProstCodec::default();
7853 let path = http::uri::PathAndQuery::from_static(
7854 "/google.cloud.sql.v1beta4.SqlInstancesService/Clone",
7855 );
7856 let mut req = request.into_request();
7857 req.extensions_mut()
7858 .insert(
7859 GrpcMethod::new(
7860 "google.cloud.sql.v1beta4.SqlInstancesService",
7861 "Clone",
7862 ),
7863 );
7864 self.inner.unary(req, path, codec).await
7865 }
7866 pub async fn delete(
7868 &mut self,
7869 request: impl tonic::IntoRequest<super::SqlInstancesDeleteRequest>,
7870 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7871 self.inner
7872 .ready()
7873 .await
7874 .map_err(|e| {
7875 tonic::Status::unknown(
7876 format!("Service was not ready: {}", e.into()),
7877 )
7878 })?;
7879 let codec = tonic_prost::ProstCodec::default();
7880 let path = http::uri::PathAndQuery::from_static(
7881 "/google.cloud.sql.v1beta4.SqlInstancesService/Delete",
7882 );
7883 let mut req = request.into_request();
7884 req.extensions_mut()
7885 .insert(
7886 GrpcMethod::new(
7887 "google.cloud.sql.v1beta4.SqlInstancesService",
7888 "Delete",
7889 ),
7890 );
7891 self.inner.unary(req, path, codec).await
7892 }
7893 pub async fn demote_master(
7896 &mut self,
7897 request: impl tonic::IntoRequest<super::SqlInstancesDemoteMasterRequest>,
7898 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7899 self.inner
7900 .ready()
7901 .await
7902 .map_err(|e| {
7903 tonic::Status::unknown(
7904 format!("Service was not ready: {}", e.into()),
7905 )
7906 })?;
7907 let codec = tonic_prost::ProstCodec::default();
7908 let path = http::uri::PathAndQuery::from_static(
7909 "/google.cloud.sql.v1beta4.SqlInstancesService/DemoteMaster",
7910 );
7911 let mut req = request.into_request();
7912 req.extensions_mut()
7913 .insert(
7914 GrpcMethod::new(
7915 "google.cloud.sql.v1beta4.SqlInstancesService",
7916 "DemoteMaster",
7917 ),
7918 );
7919 self.inner.unary(req, path, codec).await
7920 }
7921 pub async fn demote(
7924 &mut self,
7925 request: impl tonic::IntoRequest<super::SqlInstancesDemoteRequest>,
7926 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7927 self.inner
7928 .ready()
7929 .await
7930 .map_err(|e| {
7931 tonic::Status::unknown(
7932 format!("Service was not ready: {}", e.into()),
7933 )
7934 })?;
7935 let codec = tonic_prost::ProstCodec::default();
7936 let path = http::uri::PathAndQuery::from_static(
7937 "/google.cloud.sql.v1beta4.SqlInstancesService/Demote",
7938 );
7939 let mut req = request.into_request();
7940 req.extensions_mut()
7941 .insert(
7942 GrpcMethod::new(
7943 "google.cloud.sql.v1beta4.SqlInstancesService",
7944 "Demote",
7945 ),
7946 );
7947 self.inner.unary(req, path, codec).await
7948 }
7949 pub async fn export(
7952 &mut self,
7953 request: impl tonic::IntoRequest<super::SqlInstancesExportRequest>,
7954 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7955 self.inner
7956 .ready()
7957 .await
7958 .map_err(|e| {
7959 tonic::Status::unknown(
7960 format!("Service was not ready: {}", e.into()),
7961 )
7962 })?;
7963 let codec = tonic_prost::ProstCodec::default();
7964 let path = http::uri::PathAndQuery::from_static(
7965 "/google.cloud.sql.v1beta4.SqlInstancesService/Export",
7966 );
7967 let mut req = request.into_request();
7968 req.extensions_mut()
7969 .insert(
7970 GrpcMethod::new(
7971 "google.cloud.sql.v1beta4.SqlInstancesService",
7972 "Export",
7973 ),
7974 );
7975 self.inner.unary(req, path, codec).await
7976 }
7977 pub async fn failover(
7986 &mut self,
7987 request: impl tonic::IntoRequest<super::SqlInstancesFailoverRequest>,
7988 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
7989 self.inner
7990 .ready()
7991 .await
7992 .map_err(|e| {
7993 tonic::Status::unknown(
7994 format!("Service was not ready: {}", e.into()),
7995 )
7996 })?;
7997 let codec = tonic_prost::ProstCodec::default();
7998 let path = http::uri::PathAndQuery::from_static(
7999 "/google.cloud.sql.v1beta4.SqlInstancesService/Failover",
8000 );
8001 let mut req = request.into_request();
8002 req.extensions_mut()
8003 .insert(
8004 GrpcMethod::new(
8005 "google.cloud.sql.v1beta4.SqlInstancesService",
8006 "Failover",
8007 ),
8008 );
8009 self.inner.unary(req, path, codec).await
8010 }
8011 pub async fn reencrypt(
8013 &mut self,
8014 request: impl tonic::IntoRequest<super::SqlInstancesReencryptRequest>,
8015 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8016 self.inner
8017 .ready()
8018 .await
8019 .map_err(|e| {
8020 tonic::Status::unknown(
8021 format!("Service was not ready: {}", e.into()),
8022 )
8023 })?;
8024 let codec = tonic_prost::ProstCodec::default();
8025 let path = http::uri::PathAndQuery::from_static(
8026 "/google.cloud.sql.v1beta4.SqlInstancesService/Reencrypt",
8027 );
8028 let mut req = request.into_request();
8029 req.extensions_mut()
8030 .insert(
8031 GrpcMethod::new(
8032 "google.cloud.sql.v1beta4.SqlInstancesService",
8033 "Reencrypt",
8034 ),
8035 );
8036 self.inner.unary(req, path, codec).await
8037 }
8038 pub async fn get(
8040 &mut self,
8041 request: impl tonic::IntoRequest<super::SqlInstancesGetRequest>,
8042 ) -> std::result::Result<
8043 tonic::Response<super::DatabaseInstance>,
8044 tonic::Status,
8045 > {
8046 self.inner
8047 .ready()
8048 .await
8049 .map_err(|e| {
8050 tonic::Status::unknown(
8051 format!("Service was not ready: {}", e.into()),
8052 )
8053 })?;
8054 let codec = tonic_prost::ProstCodec::default();
8055 let path = http::uri::PathAndQuery::from_static(
8056 "/google.cloud.sql.v1beta4.SqlInstancesService/Get",
8057 );
8058 let mut req = request.into_request();
8059 req.extensions_mut()
8060 .insert(
8061 GrpcMethod::new(
8062 "google.cloud.sql.v1beta4.SqlInstancesService",
8063 "Get",
8064 ),
8065 );
8066 self.inner.unary(req, path, codec).await
8067 }
8068 pub async fn import(
8071 &mut self,
8072 request: impl tonic::IntoRequest<super::SqlInstancesImportRequest>,
8073 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8074 self.inner
8075 .ready()
8076 .await
8077 .map_err(|e| {
8078 tonic::Status::unknown(
8079 format!("Service was not ready: {}", e.into()),
8080 )
8081 })?;
8082 let codec = tonic_prost::ProstCodec::default();
8083 let path = http::uri::PathAndQuery::from_static(
8084 "/google.cloud.sql.v1beta4.SqlInstancesService/Import",
8085 );
8086 let mut req = request.into_request();
8087 req.extensions_mut()
8088 .insert(
8089 GrpcMethod::new(
8090 "google.cloud.sql.v1beta4.SqlInstancesService",
8091 "Import",
8092 ),
8093 );
8094 self.inner.unary(req, path, codec).await
8095 }
8096 pub async fn insert(
8098 &mut self,
8099 request: impl tonic::IntoRequest<super::SqlInstancesInsertRequest>,
8100 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8101 self.inner
8102 .ready()
8103 .await
8104 .map_err(|e| {
8105 tonic::Status::unknown(
8106 format!("Service was not ready: {}", e.into()),
8107 )
8108 })?;
8109 let codec = tonic_prost::ProstCodec::default();
8110 let path = http::uri::PathAndQuery::from_static(
8111 "/google.cloud.sql.v1beta4.SqlInstancesService/Insert",
8112 );
8113 let mut req = request.into_request();
8114 req.extensions_mut()
8115 .insert(
8116 GrpcMethod::new(
8117 "google.cloud.sql.v1beta4.SqlInstancesService",
8118 "Insert",
8119 ),
8120 );
8121 self.inner.unary(req, path, codec).await
8122 }
8123 pub async fn list(
8125 &mut self,
8126 request: impl tonic::IntoRequest<super::SqlInstancesListRequest>,
8127 ) -> std::result::Result<
8128 tonic::Response<super::InstancesListResponse>,
8129 tonic::Status,
8130 > {
8131 self.inner
8132 .ready()
8133 .await
8134 .map_err(|e| {
8135 tonic::Status::unknown(
8136 format!("Service was not ready: {}", e.into()),
8137 )
8138 })?;
8139 let codec = tonic_prost::ProstCodec::default();
8140 let path = http::uri::PathAndQuery::from_static(
8141 "/google.cloud.sql.v1beta4.SqlInstancesService/List",
8142 );
8143 let mut req = request.into_request();
8144 req.extensions_mut()
8145 .insert(
8146 GrpcMethod::new(
8147 "google.cloud.sql.v1beta4.SqlInstancesService",
8148 "List",
8149 ),
8150 );
8151 self.inner.unary(req, path, codec).await
8152 }
8153 pub async fn list_server_cas(
8159 &mut self,
8160 request: impl tonic::IntoRequest<super::SqlInstancesListServerCasRequest>,
8161 ) -> std::result::Result<
8162 tonic::Response<super::InstancesListServerCasResponse>,
8163 tonic::Status,
8164 > {
8165 self.inner
8166 .ready()
8167 .await
8168 .map_err(|e| {
8169 tonic::Status::unknown(
8170 format!("Service was not ready: {}", e.into()),
8171 )
8172 })?;
8173 let codec = tonic_prost::ProstCodec::default();
8174 let path = http::uri::PathAndQuery::from_static(
8175 "/google.cloud.sql.v1beta4.SqlInstancesService/ListServerCas",
8176 );
8177 let mut req = request.into_request();
8178 req.extensions_mut()
8179 .insert(
8180 GrpcMethod::new(
8181 "google.cloud.sql.v1beta4.SqlInstancesService",
8182 "ListServerCas",
8183 ),
8184 );
8185 self.inner.unary(req, path, codec).await
8186 }
8187 pub async fn list_server_certificates(
8194 &mut self,
8195 request: impl tonic::IntoRequest<
8196 super::SqlInstancesListServerCertificatesRequest,
8197 >,
8198 ) -> std::result::Result<
8199 tonic::Response<super::InstancesListServerCertificatesResponse>,
8200 tonic::Status,
8201 > {
8202 self.inner
8203 .ready()
8204 .await
8205 .map_err(|e| {
8206 tonic::Status::unknown(
8207 format!("Service was not ready: {}", e.into()),
8208 )
8209 })?;
8210 let codec = tonic_prost::ProstCodec::default();
8211 let path = http::uri::PathAndQuery::from_static(
8212 "/google.cloud.sql.v1beta4.SqlInstancesService/ListServerCertificates",
8213 );
8214 let mut req = request.into_request();
8215 req.extensions_mut()
8216 .insert(
8217 GrpcMethod::new(
8218 "google.cloud.sql.v1beta4.SqlInstancesService",
8219 "ListServerCertificates",
8220 ),
8221 );
8222 self.inner.unary(req, path, codec).await
8223 }
8224 pub async fn list_entra_id_certificates(
8229 &mut self,
8230 request: impl tonic::IntoRequest<
8231 super::SqlInstancesListEntraIdCertificatesRequest,
8232 >,
8233 ) -> std::result::Result<
8234 tonic::Response<super::InstancesListEntraIdCertificatesResponse>,
8235 tonic::Status,
8236 > {
8237 self.inner
8238 .ready()
8239 .await
8240 .map_err(|e| {
8241 tonic::Status::unknown(
8242 format!("Service was not ready: {}", e.into()),
8243 )
8244 })?;
8245 let codec = tonic_prost::ProstCodec::default();
8246 let path = http::uri::PathAndQuery::from_static(
8247 "/google.cloud.sql.v1beta4.SqlInstancesService/ListEntraIdCertificates",
8248 );
8249 let mut req = request.into_request();
8250 req.extensions_mut()
8251 .insert(
8252 GrpcMethod::new(
8253 "google.cloud.sql.v1beta4.SqlInstancesService",
8254 "ListEntraIdCertificates",
8255 ),
8256 );
8257 self.inner.unary(req, path, codec).await
8258 }
8259 pub async fn patch(
8262 &mut self,
8263 request: impl tonic::IntoRequest<super::SqlInstancesPatchRequest>,
8264 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8265 self.inner
8266 .ready()
8267 .await
8268 .map_err(|e| {
8269 tonic::Status::unknown(
8270 format!("Service was not ready: {}", e.into()),
8271 )
8272 })?;
8273 let codec = tonic_prost::ProstCodec::default();
8274 let path = http::uri::PathAndQuery::from_static(
8275 "/google.cloud.sql.v1beta4.SqlInstancesService/Patch",
8276 );
8277 let mut req = request.into_request();
8278 req.extensions_mut()
8279 .insert(
8280 GrpcMethod::new(
8281 "google.cloud.sql.v1beta4.SqlInstancesService",
8282 "Patch",
8283 ),
8284 );
8285 self.inner.unary(req, path, codec).await
8286 }
8287 pub async fn promote_replica(
8291 &mut self,
8292 request: impl tonic::IntoRequest<super::SqlInstancesPromoteReplicaRequest>,
8293 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8294 self.inner
8295 .ready()
8296 .await
8297 .map_err(|e| {
8298 tonic::Status::unknown(
8299 format!("Service was not ready: {}", e.into()),
8300 )
8301 })?;
8302 let codec = tonic_prost::ProstCodec::default();
8303 let path = http::uri::PathAndQuery::from_static(
8304 "/google.cloud.sql.v1beta4.SqlInstancesService/PromoteReplica",
8305 );
8306 let mut req = request.into_request();
8307 req.extensions_mut()
8308 .insert(
8309 GrpcMethod::new(
8310 "google.cloud.sql.v1beta4.SqlInstancesService",
8311 "PromoteReplica",
8312 ),
8313 );
8314 self.inner.unary(req, path, codec).await
8315 }
8316 pub async fn switchover(
8319 &mut self,
8320 request: impl tonic::IntoRequest<super::SqlInstancesSwitchoverRequest>,
8321 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8322 self.inner
8323 .ready()
8324 .await
8325 .map_err(|e| {
8326 tonic::Status::unknown(
8327 format!("Service was not ready: {}", e.into()),
8328 )
8329 })?;
8330 let codec = tonic_prost::ProstCodec::default();
8331 let path = http::uri::PathAndQuery::from_static(
8332 "/google.cloud.sql.v1beta4.SqlInstancesService/Switchover",
8333 );
8334 let mut req = request.into_request();
8335 req.extensions_mut()
8336 .insert(
8337 GrpcMethod::new(
8338 "google.cloud.sql.v1beta4.SqlInstancesService",
8339 "Switchover",
8340 ),
8341 );
8342 self.inner.unary(req, path, codec).await
8343 }
8344 pub async fn reset_ssl_config(
8347 &mut self,
8348 request: impl tonic::IntoRequest<super::SqlInstancesResetSslConfigRequest>,
8349 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8350 self.inner
8351 .ready()
8352 .await
8353 .map_err(|e| {
8354 tonic::Status::unknown(
8355 format!("Service was not ready: {}", e.into()),
8356 )
8357 })?;
8358 let codec = tonic_prost::ProstCodec::default();
8359 let path = http::uri::PathAndQuery::from_static(
8360 "/google.cloud.sql.v1beta4.SqlInstancesService/ResetSslConfig",
8361 );
8362 let mut req = request.into_request();
8363 req.extensions_mut()
8364 .insert(
8365 GrpcMethod::new(
8366 "google.cloud.sql.v1beta4.SqlInstancesService",
8367 "ResetSslConfig",
8368 ),
8369 );
8370 self.inner.unary(req, path, codec).await
8371 }
8372 pub async fn restart(
8374 &mut self,
8375 request: impl tonic::IntoRequest<super::SqlInstancesRestartRequest>,
8376 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8377 self.inner
8378 .ready()
8379 .await
8380 .map_err(|e| {
8381 tonic::Status::unknown(
8382 format!("Service was not ready: {}", e.into()),
8383 )
8384 })?;
8385 let codec = tonic_prost::ProstCodec::default();
8386 let path = http::uri::PathAndQuery::from_static(
8387 "/google.cloud.sql.v1beta4.SqlInstancesService/Restart",
8388 );
8389 let mut req = request.into_request();
8390 req.extensions_mut()
8391 .insert(
8392 GrpcMethod::new(
8393 "google.cloud.sql.v1beta4.SqlInstancesService",
8394 "Restart",
8395 ),
8396 );
8397 self.inner.unary(req, path, codec).await
8398 }
8399 pub async fn restore_backup(
8402 &mut self,
8403 request: impl tonic::IntoRequest<super::SqlInstancesRestoreBackupRequest>,
8404 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8405 self.inner
8406 .ready()
8407 .await
8408 .map_err(|e| {
8409 tonic::Status::unknown(
8410 format!("Service was not ready: {}", e.into()),
8411 )
8412 })?;
8413 let codec = tonic_prost::ProstCodec::default();
8414 let path = http::uri::PathAndQuery::from_static(
8415 "/google.cloud.sql.v1beta4.SqlInstancesService/RestoreBackup",
8416 );
8417 let mut req = request.into_request();
8418 req.extensions_mut()
8419 .insert(
8420 GrpcMethod::new(
8421 "google.cloud.sql.v1beta4.SqlInstancesService",
8422 "RestoreBackup",
8423 ),
8424 );
8425 self.inner.unary(req, path, codec).await
8426 }
8427 pub async fn rotate_server_ca(
8432 &mut self,
8433 request: impl tonic::IntoRequest<super::SqlInstancesRotateServerCaRequest>,
8434 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8435 self.inner
8436 .ready()
8437 .await
8438 .map_err(|e| {
8439 tonic::Status::unknown(
8440 format!("Service was not ready: {}", e.into()),
8441 )
8442 })?;
8443 let codec = tonic_prost::ProstCodec::default();
8444 let path = http::uri::PathAndQuery::from_static(
8445 "/google.cloud.sql.v1beta4.SqlInstancesService/RotateServerCa",
8446 );
8447 let mut req = request.into_request();
8448 req.extensions_mut()
8449 .insert(
8450 GrpcMethod::new(
8451 "google.cloud.sql.v1beta4.SqlInstancesService",
8452 "RotateServerCa",
8453 ),
8454 );
8455 self.inner.unary(req, path, codec).await
8456 }
8457 pub async fn rotate_server_certificate(
8461 &mut self,
8462 request: impl tonic::IntoRequest<
8463 super::SqlInstancesRotateServerCertificateRequest,
8464 >,
8465 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8466 self.inner
8467 .ready()
8468 .await
8469 .map_err(|e| {
8470 tonic::Status::unknown(
8471 format!("Service was not ready: {}", e.into()),
8472 )
8473 })?;
8474 let codec = tonic_prost::ProstCodec::default();
8475 let path = http::uri::PathAndQuery::from_static(
8476 "/google.cloud.sql.v1beta4.SqlInstancesService/RotateServerCertificate",
8477 );
8478 let mut req = request.into_request();
8479 req.extensions_mut()
8480 .insert(
8481 GrpcMethod::new(
8482 "google.cloud.sql.v1beta4.SqlInstancesService",
8483 "RotateServerCertificate",
8484 ),
8485 );
8486 self.inner.unary(req, path, codec).await
8487 }
8488 pub async fn rotate_entra_id_certificate(
8491 &mut self,
8492 request: impl tonic::IntoRequest<
8493 super::SqlInstancesRotateEntraIdCertificateRequest,
8494 >,
8495 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8496 self.inner
8497 .ready()
8498 .await
8499 .map_err(|e| {
8500 tonic::Status::unknown(
8501 format!("Service was not ready: {}", e.into()),
8502 )
8503 })?;
8504 let codec = tonic_prost::ProstCodec::default();
8505 let path = http::uri::PathAndQuery::from_static(
8506 "/google.cloud.sql.v1beta4.SqlInstancesService/RotateEntraIdCertificate",
8507 );
8508 let mut req = request.into_request();
8509 req.extensions_mut()
8510 .insert(
8511 GrpcMethod::new(
8512 "google.cloud.sql.v1beta4.SqlInstancesService",
8513 "RotateEntraIdCertificate",
8514 ),
8515 );
8516 self.inner.unary(req, path, codec).await
8517 }
8518 pub async fn start_replica(
8520 &mut self,
8521 request: impl tonic::IntoRequest<super::SqlInstancesStartReplicaRequest>,
8522 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8523 self.inner
8524 .ready()
8525 .await
8526 .map_err(|e| {
8527 tonic::Status::unknown(
8528 format!("Service was not ready: {}", e.into()),
8529 )
8530 })?;
8531 let codec = tonic_prost::ProstCodec::default();
8532 let path = http::uri::PathAndQuery::from_static(
8533 "/google.cloud.sql.v1beta4.SqlInstancesService/StartReplica",
8534 );
8535 let mut req = request.into_request();
8536 req.extensions_mut()
8537 .insert(
8538 GrpcMethod::new(
8539 "google.cloud.sql.v1beta4.SqlInstancesService",
8540 "StartReplica",
8541 ),
8542 );
8543 self.inner.unary(req, path, codec).await
8544 }
8545 pub async fn stop_replica(
8547 &mut self,
8548 request: impl tonic::IntoRequest<super::SqlInstancesStopReplicaRequest>,
8549 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8550 self.inner
8551 .ready()
8552 .await
8553 .map_err(|e| {
8554 tonic::Status::unknown(
8555 format!("Service was not ready: {}", e.into()),
8556 )
8557 })?;
8558 let codec = tonic_prost::ProstCodec::default();
8559 let path = http::uri::PathAndQuery::from_static(
8560 "/google.cloud.sql.v1beta4.SqlInstancesService/StopReplica",
8561 );
8562 let mut req = request.into_request();
8563 req.extensions_mut()
8564 .insert(
8565 GrpcMethod::new(
8566 "google.cloud.sql.v1beta4.SqlInstancesService",
8567 "StopReplica",
8568 ),
8569 );
8570 self.inner.unary(req, path, codec).await
8571 }
8572 pub async fn truncate_log(
8575 &mut self,
8576 request: impl tonic::IntoRequest<super::SqlInstancesTruncateLogRequest>,
8577 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8578 self.inner
8579 .ready()
8580 .await
8581 .map_err(|e| {
8582 tonic::Status::unknown(
8583 format!("Service was not ready: {}", e.into()),
8584 )
8585 })?;
8586 let codec = tonic_prost::ProstCodec::default();
8587 let path = http::uri::PathAndQuery::from_static(
8588 "/google.cloud.sql.v1beta4.SqlInstancesService/TruncateLog",
8589 );
8590 let mut req = request.into_request();
8591 req.extensions_mut()
8592 .insert(
8593 GrpcMethod::new(
8594 "google.cloud.sql.v1beta4.SqlInstancesService",
8595 "TruncateLog",
8596 ),
8597 );
8598 self.inner.unary(req, path, codec).await
8599 }
8600 pub async fn update(
8603 &mut self,
8604 request: impl tonic::IntoRequest<super::SqlInstancesUpdateRequest>,
8605 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8606 self.inner
8607 .ready()
8608 .await
8609 .map_err(|e| {
8610 tonic::Status::unknown(
8611 format!("Service was not ready: {}", e.into()),
8612 )
8613 })?;
8614 let codec = tonic_prost::ProstCodec::default();
8615 let path = http::uri::PathAndQuery::from_static(
8616 "/google.cloud.sql.v1beta4.SqlInstancesService/Update",
8617 );
8618 let mut req = request.into_request();
8619 req.extensions_mut()
8620 .insert(
8621 GrpcMethod::new(
8622 "google.cloud.sql.v1beta4.SqlInstancesService",
8623 "Update",
8624 ),
8625 );
8626 self.inner.unary(req, path, codec).await
8627 }
8628 pub async fn create_ephemeral(
8633 &mut self,
8634 request: impl tonic::IntoRequest<
8635 super::SqlInstancesCreateEphemeralCertRequest,
8636 >,
8637 ) -> std::result::Result<tonic::Response<super::SslCert>, tonic::Status> {
8638 self.inner
8639 .ready()
8640 .await
8641 .map_err(|e| {
8642 tonic::Status::unknown(
8643 format!("Service was not ready: {}", e.into()),
8644 )
8645 })?;
8646 let codec = tonic_prost::ProstCodec::default();
8647 let path = http::uri::PathAndQuery::from_static(
8648 "/google.cloud.sql.v1beta4.SqlInstancesService/CreateEphemeral",
8649 );
8650 let mut req = request.into_request();
8651 req.extensions_mut()
8652 .insert(
8653 GrpcMethod::new(
8654 "google.cloud.sql.v1beta4.SqlInstancesService",
8655 "CreateEphemeral",
8656 ),
8657 );
8658 self.inner.unary(req, path, codec).await
8659 }
8660 pub async fn reschedule_maintenance(
8662 &mut self,
8663 request: impl tonic::IntoRequest<
8664 super::SqlInstancesRescheduleMaintenanceRequest,
8665 >,
8666 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8667 self.inner
8668 .ready()
8669 .await
8670 .map_err(|e| {
8671 tonic::Status::unknown(
8672 format!("Service was not ready: {}", e.into()),
8673 )
8674 })?;
8675 let codec = tonic_prost::ProstCodec::default();
8676 let path = http::uri::PathAndQuery::from_static(
8677 "/google.cloud.sql.v1beta4.SqlInstancesService/RescheduleMaintenance",
8678 );
8679 let mut req = request.into_request();
8680 req.extensions_mut()
8681 .insert(
8682 GrpcMethod::new(
8683 "google.cloud.sql.v1beta4.SqlInstancesService",
8684 "RescheduleMaintenance",
8685 ),
8686 );
8687 self.inner.unary(req, path, codec).await
8688 }
8689 pub async fn verify_external_sync_settings(
8691 &mut self,
8692 request: impl tonic::IntoRequest<
8693 super::SqlInstancesVerifyExternalSyncSettingsRequest,
8694 >,
8695 ) -> std::result::Result<
8696 tonic::Response<super::SqlInstancesVerifyExternalSyncSettingsResponse>,
8697 tonic::Status,
8698 > {
8699 self.inner
8700 .ready()
8701 .await
8702 .map_err(|e| {
8703 tonic::Status::unknown(
8704 format!("Service was not ready: {}", e.into()),
8705 )
8706 })?;
8707 let codec = tonic_prost::ProstCodec::default();
8708 let path = http::uri::PathAndQuery::from_static(
8709 "/google.cloud.sql.v1beta4.SqlInstancesService/VerifyExternalSyncSettings",
8710 );
8711 let mut req = request.into_request();
8712 req.extensions_mut()
8713 .insert(
8714 GrpcMethod::new(
8715 "google.cloud.sql.v1beta4.SqlInstancesService",
8716 "VerifyExternalSyncSettings",
8717 ),
8718 );
8719 self.inner.unary(req, path, codec).await
8720 }
8721 pub async fn start_external_sync(
8723 &mut self,
8724 request: impl tonic::IntoRequest<super::SqlInstancesStartExternalSyncRequest>,
8725 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8726 self.inner
8727 .ready()
8728 .await
8729 .map_err(|e| {
8730 tonic::Status::unknown(
8731 format!("Service was not ready: {}", e.into()),
8732 )
8733 })?;
8734 let codec = tonic_prost::ProstCodec::default();
8735 let path = http::uri::PathAndQuery::from_static(
8736 "/google.cloud.sql.v1beta4.SqlInstancesService/StartExternalSync",
8737 );
8738 let mut req = request.into_request();
8739 req.extensions_mut()
8740 .insert(
8741 GrpcMethod::new(
8742 "google.cloud.sql.v1beta4.SqlInstancesService",
8743 "StartExternalSync",
8744 ),
8745 );
8746 self.inner.unary(req, path, codec).await
8747 }
8748 pub async fn perform_disk_shrink(
8750 &mut self,
8751 request: impl tonic::IntoRequest<super::SqlInstancesPerformDiskShrinkRequest>,
8752 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8753 self.inner
8754 .ready()
8755 .await
8756 .map_err(|e| {
8757 tonic::Status::unknown(
8758 format!("Service was not ready: {}", e.into()),
8759 )
8760 })?;
8761 let codec = tonic_prost::ProstCodec::default();
8762 let path = http::uri::PathAndQuery::from_static(
8763 "/google.cloud.sql.v1beta4.SqlInstancesService/PerformDiskShrink",
8764 );
8765 let mut req = request.into_request();
8766 req.extensions_mut()
8767 .insert(
8768 GrpcMethod::new(
8769 "google.cloud.sql.v1beta4.SqlInstancesService",
8770 "PerformDiskShrink",
8771 ),
8772 );
8773 self.inner.unary(req, path, codec).await
8774 }
8775 pub async fn get_disk_shrink_config(
8777 &mut self,
8778 request: impl tonic::IntoRequest<
8779 super::SqlInstancesGetDiskShrinkConfigRequest,
8780 >,
8781 ) -> std::result::Result<
8782 tonic::Response<super::SqlInstancesGetDiskShrinkConfigResponse>,
8783 tonic::Status,
8784 > {
8785 self.inner
8786 .ready()
8787 .await
8788 .map_err(|e| {
8789 tonic::Status::unknown(
8790 format!("Service was not ready: {}", e.into()),
8791 )
8792 })?;
8793 let codec = tonic_prost::ProstCodec::default();
8794 let path = http::uri::PathAndQuery::from_static(
8795 "/google.cloud.sql.v1beta4.SqlInstancesService/GetDiskShrinkConfig",
8796 );
8797 let mut req = request.into_request();
8798 req.extensions_mut()
8799 .insert(
8800 GrpcMethod::new(
8801 "google.cloud.sql.v1beta4.SqlInstancesService",
8802 "GetDiskShrinkConfig",
8803 ),
8804 );
8805 self.inner.unary(req, path, codec).await
8806 }
8807 pub async fn reset_replica_size(
8809 &mut self,
8810 request: impl tonic::IntoRequest<super::SqlInstancesResetReplicaSizeRequest>,
8811 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8812 self.inner
8813 .ready()
8814 .await
8815 .map_err(|e| {
8816 tonic::Status::unknown(
8817 format!("Service was not ready: {}", e.into()),
8818 )
8819 })?;
8820 let codec = tonic_prost::ProstCodec::default();
8821 let path = http::uri::PathAndQuery::from_static(
8822 "/google.cloud.sql.v1beta4.SqlInstancesService/ResetReplicaSize",
8823 );
8824 let mut req = request.into_request();
8825 req.extensions_mut()
8826 .insert(
8827 GrpcMethod::new(
8828 "google.cloud.sql.v1beta4.SqlInstancesService",
8829 "ResetReplicaSize",
8830 ),
8831 );
8832 self.inner.unary(req, path, codec).await
8833 }
8834 pub async fn get_latest_recovery_time(
8836 &mut self,
8837 request: impl tonic::IntoRequest<
8838 super::SqlInstancesGetLatestRecoveryTimeRequest,
8839 >,
8840 ) -> std::result::Result<
8841 tonic::Response<super::SqlInstancesGetLatestRecoveryTimeResponse>,
8842 tonic::Status,
8843 > {
8844 self.inner
8845 .ready()
8846 .await
8847 .map_err(|e| {
8848 tonic::Status::unknown(
8849 format!("Service was not ready: {}", e.into()),
8850 )
8851 })?;
8852 let codec = tonic_prost::ProstCodec::default();
8853 let path = http::uri::PathAndQuery::from_static(
8854 "/google.cloud.sql.v1beta4.SqlInstancesService/GetLatestRecoveryTime",
8855 );
8856 let mut req = request.into_request();
8857 req.extensions_mut()
8858 .insert(
8859 GrpcMethod::new(
8860 "google.cloud.sql.v1beta4.SqlInstancesService",
8861 "GetLatestRecoveryTime",
8862 ),
8863 );
8864 self.inner.unary(req, path, codec).await
8865 }
8866 pub async fn execute_sql(
8868 &mut self,
8869 request: impl tonic::IntoRequest<super::SqlInstancesExecuteSqlRequest>,
8870 ) -> std::result::Result<
8871 tonic::Response<super::SqlInstancesExecuteSqlResponse>,
8872 tonic::Status,
8873 > {
8874 self.inner
8875 .ready()
8876 .await
8877 .map_err(|e| {
8878 tonic::Status::unknown(
8879 format!("Service was not ready: {}", e.into()),
8880 )
8881 })?;
8882 let codec = tonic_prost::ProstCodec::default();
8883 let path = http::uri::PathAndQuery::from_static(
8884 "/google.cloud.sql.v1beta4.SqlInstancesService/ExecuteSql",
8885 );
8886 let mut req = request.into_request();
8887 req.extensions_mut()
8888 .insert(
8889 GrpcMethod::new(
8890 "google.cloud.sql.v1beta4.SqlInstancesService",
8891 "ExecuteSql",
8892 ),
8893 );
8894 self.inner.unary(req, path, codec).await
8895 }
8896 pub async fn acquire_ssrs_lease(
8898 &mut self,
8899 request: impl tonic::IntoRequest<super::SqlInstancesAcquireSsrsLeaseRequest>,
8900 ) -> std::result::Result<
8901 tonic::Response<super::SqlInstancesAcquireSsrsLeaseResponse>,
8902 tonic::Status,
8903 > {
8904 self.inner
8905 .ready()
8906 .await
8907 .map_err(|e| {
8908 tonic::Status::unknown(
8909 format!("Service was not ready: {}", e.into()),
8910 )
8911 })?;
8912 let codec = tonic_prost::ProstCodec::default();
8913 let path = http::uri::PathAndQuery::from_static(
8914 "/google.cloud.sql.v1beta4.SqlInstancesService/AcquireSsrsLease",
8915 );
8916 let mut req = request.into_request();
8917 req.extensions_mut()
8918 .insert(
8919 GrpcMethod::new(
8920 "google.cloud.sql.v1beta4.SqlInstancesService",
8921 "AcquireSsrsLease",
8922 ),
8923 );
8924 self.inner.unary(req, path, codec).await
8925 }
8926 pub async fn release_ssrs_lease(
8928 &mut self,
8929 request: impl tonic::IntoRequest<super::SqlInstancesReleaseSsrsLeaseRequest>,
8930 ) -> std::result::Result<
8931 tonic::Response<super::SqlInstancesReleaseSsrsLeaseResponse>,
8932 tonic::Status,
8933 > {
8934 self.inner
8935 .ready()
8936 .await
8937 .map_err(|e| {
8938 tonic::Status::unknown(
8939 format!("Service was not ready: {}", e.into()),
8940 )
8941 })?;
8942 let codec = tonic_prost::ProstCodec::default();
8943 let path = http::uri::PathAndQuery::from_static(
8944 "/google.cloud.sql.v1beta4.SqlInstancesService/ReleaseSsrsLease",
8945 );
8946 let mut req = request.into_request();
8947 req.extensions_mut()
8948 .insert(
8949 GrpcMethod::new(
8950 "google.cloud.sql.v1beta4.SqlInstancesService",
8951 "ReleaseSsrsLease",
8952 ),
8953 );
8954 self.inner.unary(req, path, codec).await
8955 }
8956 pub async fn pre_check_major_version_upgrade(
8958 &mut self,
8959 request: impl tonic::IntoRequest<
8960 super::SqlInstancesPreCheckMajorVersionUpgradeRequest,
8961 >,
8962 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8963 self.inner
8964 .ready()
8965 .await
8966 .map_err(|e| {
8967 tonic::Status::unknown(
8968 format!("Service was not ready: {}", e.into()),
8969 )
8970 })?;
8971 let codec = tonic_prost::ProstCodec::default();
8972 let path = http::uri::PathAndQuery::from_static(
8973 "/google.cloud.sql.v1beta4.SqlInstancesService/PreCheckMajorVersionUpgrade",
8974 );
8975 let mut req = request.into_request();
8976 req.extensions_mut()
8977 .insert(
8978 GrpcMethod::new(
8979 "google.cloud.sql.v1beta4.SqlInstancesService",
8980 "PreCheckMajorVersionUpgrade",
8981 ),
8982 );
8983 self.inner.unary(req, path, codec).await
8984 }
8985 pub async fn point_in_time_restore(
8988 &mut self,
8989 request: impl tonic::IntoRequest<
8990 super::SqlInstancesPointInTimeRestoreRequest,
8991 >,
8992 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
8993 self.inner
8994 .ready()
8995 .await
8996 .map_err(|e| {
8997 tonic::Status::unknown(
8998 format!("Service was not ready: {}", e.into()),
8999 )
9000 })?;
9001 let codec = tonic_prost::ProstCodec::default();
9002 let path = http::uri::PathAndQuery::from_static(
9003 "/google.cloud.sql.v1beta4.SqlInstancesService/PointInTimeRestore",
9004 );
9005 let mut req = request.into_request();
9006 req.extensions_mut()
9007 .insert(
9008 GrpcMethod::new(
9009 "google.cloud.sql.v1beta4.SqlInstancesService",
9010 "PointInTimeRestore",
9011 ),
9012 );
9013 self.inner.unary(req, path, codec).await
9014 }
9015 }
9016}
9017pub mod sql_operations_service_client {
9019 #![allow(
9020 unused_variables,
9021 dead_code,
9022 missing_docs,
9023 clippy::wildcard_imports,
9024 clippy::let_unit_value,
9025 )]
9026 use tonic::codegen::*;
9027 use tonic::codegen::http::Uri;
9028 #[derive(Debug, Clone)]
9029 pub struct SqlOperationsServiceClient<T> {
9030 inner: tonic::client::Grpc<T>,
9031 }
9032 impl<T> SqlOperationsServiceClient<T>
9033 where
9034 T: tonic::client::GrpcService<tonic::body::Body>,
9035 T::Error: Into<StdError>,
9036 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
9037 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
9038 {
9039 pub fn new(inner: T) -> Self {
9040 let inner = tonic::client::Grpc::new(inner);
9041 Self { inner }
9042 }
9043 pub fn with_origin(inner: T, origin: Uri) -> Self {
9044 let inner = tonic::client::Grpc::with_origin(inner, origin);
9045 Self { inner }
9046 }
9047 pub fn with_interceptor<F>(
9048 inner: T,
9049 interceptor: F,
9050 ) -> SqlOperationsServiceClient<InterceptedService<T, F>>
9051 where
9052 F: tonic::service::Interceptor,
9053 T::ResponseBody: Default,
9054 T: tonic::codegen::Service<
9055 http::Request<tonic::body::Body>,
9056 Response = http::Response<
9057 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
9058 >,
9059 >,
9060 <T as tonic::codegen::Service<
9061 http::Request<tonic::body::Body>,
9062 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
9063 {
9064 SqlOperationsServiceClient::new(InterceptedService::new(inner, interceptor))
9065 }
9066 #[must_use]
9071 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9072 self.inner = self.inner.send_compressed(encoding);
9073 self
9074 }
9075 #[must_use]
9077 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9078 self.inner = self.inner.accept_compressed(encoding);
9079 self
9080 }
9081 #[must_use]
9085 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9086 self.inner = self.inner.max_decoding_message_size(limit);
9087 self
9088 }
9089 #[must_use]
9093 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9094 self.inner = self.inner.max_encoding_message_size(limit);
9095 self
9096 }
9097 pub async fn get(
9099 &mut self,
9100 request: impl tonic::IntoRequest<super::SqlOperationsGetRequest>,
9101 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
9102 self.inner
9103 .ready()
9104 .await
9105 .map_err(|e| {
9106 tonic::Status::unknown(
9107 format!("Service was not ready: {}", e.into()),
9108 )
9109 })?;
9110 let codec = tonic_prost::ProstCodec::default();
9111 let path = http::uri::PathAndQuery::from_static(
9112 "/google.cloud.sql.v1beta4.SqlOperationsService/Get",
9113 );
9114 let mut req = request.into_request();
9115 req.extensions_mut()
9116 .insert(
9117 GrpcMethod::new(
9118 "google.cloud.sql.v1beta4.SqlOperationsService",
9119 "Get",
9120 ),
9121 );
9122 self.inner.unary(req, path, codec).await
9123 }
9124 pub async fn list(
9127 &mut self,
9128 request: impl tonic::IntoRequest<super::SqlOperationsListRequest>,
9129 ) -> std::result::Result<
9130 tonic::Response<super::OperationsListResponse>,
9131 tonic::Status,
9132 > {
9133 self.inner
9134 .ready()
9135 .await
9136 .map_err(|e| {
9137 tonic::Status::unknown(
9138 format!("Service was not ready: {}", e.into()),
9139 )
9140 })?;
9141 let codec = tonic_prost::ProstCodec::default();
9142 let path = http::uri::PathAndQuery::from_static(
9143 "/google.cloud.sql.v1beta4.SqlOperationsService/List",
9144 );
9145 let mut req = request.into_request();
9146 req.extensions_mut()
9147 .insert(
9148 GrpcMethod::new(
9149 "google.cloud.sql.v1beta4.SqlOperationsService",
9150 "List",
9151 ),
9152 );
9153 self.inner.unary(req, path, codec).await
9154 }
9155 pub async fn cancel(
9158 &mut self,
9159 request: impl tonic::IntoRequest<super::SqlOperationsCancelRequest>,
9160 ) -> std::result::Result<tonic::Response<()>, tonic::Status> {
9161 self.inner
9162 .ready()
9163 .await
9164 .map_err(|e| {
9165 tonic::Status::unknown(
9166 format!("Service was not ready: {}", e.into()),
9167 )
9168 })?;
9169 let codec = tonic_prost::ProstCodec::default();
9170 let path = http::uri::PathAndQuery::from_static(
9171 "/google.cloud.sql.v1beta4.SqlOperationsService/Cancel",
9172 );
9173 let mut req = request.into_request();
9174 req.extensions_mut()
9175 .insert(
9176 GrpcMethod::new(
9177 "google.cloud.sql.v1beta4.SqlOperationsService",
9178 "Cancel",
9179 ),
9180 );
9181 self.inner.unary(req, path, codec).await
9182 }
9183 }
9184}
9185pub mod sql_ssl_certs_service_client {
9187 #![allow(
9188 unused_variables,
9189 dead_code,
9190 missing_docs,
9191 clippy::wildcard_imports,
9192 clippy::let_unit_value,
9193 )]
9194 use tonic::codegen::*;
9195 use tonic::codegen::http::Uri;
9196 #[derive(Debug, Clone)]
9197 pub struct SqlSslCertsServiceClient<T> {
9198 inner: tonic::client::Grpc<T>,
9199 }
9200 impl<T> SqlSslCertsServiceClient<T>
9201 where
9202 T: tonic::client::GrpcService<tonic::body::Body>,
9203 T::Error: Into<StdError>,
9204 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
9205 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
9206 {
9207 pub fn new(inner: T) -> Self {
9208 let inner = tonic::client::Grpc::new(inner);
9209 Self { inner }
9210 }
9211 pub fn with_origin(inner: T, origin: Uri) -> Self {
9212 let inner = tonic::client::Grpc::with_origin(inner, origin);
9213 Self { inner }
9214 }
9215 pub fn with_interceptor<F>(
9216 inner: T,
9217 interceptor: F,
9218 ) -> SqlSslCertsServiceClient<InterceptedService<T, F>>
9219 where
9220 F: tonic::service::Interceptor,
9221 T::ResponseBody: Default,
9222 T: tonic::codegen::Service<
9223 http::Request<tonic::body::Body>,
9224 Response = http::Response<
9225 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
9226 >,
9227 >,
9228 <T as tonic::codegen::Service<
9229 http::Request<tonic::body::Body>,
9230 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
9231 {
9232 SqlSslCertsServiceClient::new(InterceptedService::new(inner, interceptor))
9233 }
9234 #[must_use]
9239 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9240 self.inner = self.inner.send_compressed(encoding);
9241 self
9242 }
9243 #[must_use]
9245 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9246 self.inner = self.inner.accept_compressed(encoding);
9247 self
9248 }
9249 #[must_use]
9253 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9254 self.inner = self.inner.max_decoding_message_size(limit);
9255 self
9256 }
9257 #[must_use]
9261 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9262 self.inner = self.inner.max_encoding_message_size(limit);
9263 self
9264 }
9265 pub async fn delete(
9268 &mut self,
9269 request: impl tonic::IntoRequest<super::SqlSslCertsDeleteRequest>,
9270 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
9271 self.inner
9272 .ready()
9273 .await
9274 .map_err(|e| {
9275 tonic::Status::unknown(
9276 format!("Service was not ready: {}", e.into()),
9277 )
9278 })?;
9279 let codec = tonic_prost::ProstCodec::default();
9280 let path = http::uri::PathAndQuery::from_static(
9281 "/google.cloud.sql.v1beta4.SqlSslCertsService/Delete",
9282 );
9283 let mut req = request.into_request();
9284 req.extensions_mut()
9285 .insert(
9286 GrpcMethod::new(
9287 "google.cloud.sql.v1beta4.SqlSslCertsService",
9288 "Delete",
9289 ),
9290 );
9291 self.inner.unary(req, path, codec).await
9292 }
9293 pub async fn get(
9297 &mut self,
9298 request: impl tonic::IntoRequest<super::SqlSslCertsGetRequest>,
9299 ) -> std::result::Result<tonic::Response<super::SslCert>, tonic::Status> {
9300 self.inner
9301 .ready()
9302 .await
9303 .map_err(|e| {
9304 tonic::Status::unknown(
9305 format!("Service was not ready: {}", e.into()),
9306 )
9307 })?;
9308 let codec = tonic_prost::ProstCodec::default();
9309 let path = http::uri::PathAndQuery::from_static(
9310 "/google.cloud.sql.v1beta4.SqlSslCertsService/Get",
9311 );
9312 let mut req = request.into_request();
9313 req.extensions_mut()
9314 .insert(
9315 GrpcMethod::new("google.cloud.sql.v1beta4.SqlSslCertsService", "Get"),
9316 );
9317 self.inner.unary(req, path, codec).await
9318 }
9319 pub async fn insert(
9323 &mut self,
9324 request: impl tonic::IntoRequest<super::SqlSslCertsInsertRequest>,
9325 ) -> std::result::Result<
9326 tonic::Response<super::SslCertsInsertResponse>,
9327 tonic::Status,
9328 > {
9329 self.inner
9330 .ready()
9331 .await
9332 .map_err(|e| {
9333 tonic::Status::unknown(
9334 format!("Service was not ready: {}", e.into()),
9335 )
9336 })?;
9337 let codec = tonic_prost::ProstCodec::default();
9338 let path = http::uri::PathAndQuery::from_static(
9339 "/google.cloud.sql.v1beta4.SqlSslCertsService/Insert",
9340 );
9341 let mut req = request.into_request();
9342 req.extensions_mut()
9343 .insert(
9344 GrpcMethod::new(
9345 "google.cloud.sql.v1beta4.SqlSslCertsService",
9346 "Insert",
9347 ),
9348 );
9349 self.inner.unary(req, path, codec).await
9350 }
9351 pub async fn list(
9353 &mut self,
9354 request: impl tonic::IntoRequest<super::SqlSslCertsListRequest>,
9355 ) -> std::result::Result<
9356 tonic::Response<super::SslCertsListResponse>,
9357 tonic::Status,
9358 > {
9359 self.inner
9360 .ready()
9361 .await
9362 .map_err(|e| {
9363 tonic::Status::unknown(
9364 format!("Service was not ready: {}", e.into()),
9365 )
9366 })?;
9367 let codec = tonic_prost::ProstCodec::default();
9368 let path = http::uri::PathAndQuery::from_static(
9369 "/google.cloud.sql.v1beta4.SqlSslCertsService/List",
9370 );
9371 let mut req = request.into_request();
9372 req.extensions_mut()
9373 .insert(
9374 GrpcMethod::new(
9375 "google.cloud.sql.v1beta4.SqlSslCertsService",
9376 "List",
9377 ),
9378 );
9379 self.inner.unary(req, path, codec).await
9380 }
9381 }
9382}
9383pub mod sql_backups_service_client {
9385 #![allow(
9386 unused_variables,
9387 dead_code,
9388 missing_docs,
9389 clippy::wildcard_imports,
9390 clippy::let_unit_value,
9391 )]
9392 use tonic::codegen::*;
9393 use tonic::codegen::http::Uri;
9394 #[derive(Debug, Clone)]
9395 pub struct SqlBackupsServiceClient<T> {
9396 inner: tonic::client::Grpc<T>,
9397 }
9398 impl<T> SqlBackupsServiceClient<T>
9399 where
9400 T: tonic::client::GrpcService<tonic::body::Body>,
9401 T::Error: Into<StdError>,
9402 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
9403 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
9404 {
9405 pub fn new(inner: T) -> Self {
9406 let inner = tonic::client::Grpc::new(inner);
9407 Self { inner }
9408 }
9409 pub fn with_origin(inner: T, origin: Uri) -> Self {
9410 let inner = tonic::client::Grpc::with_origin(inner, origin);
9411 Self { inner }
9412 }
9413 pub fn with_interceptor<F>(
9414 inner: T,
9415 interceptor: F,
9416 ) -> SqlBackupsServiceClient<InterceptedService<T, F>>
9417 where
9418 F: tonic::service::Interceptor,
9419 T::ResponseBody: Default,
9420 T: tonic::codegen::Service<
9421 http::Request<tonic::body::Body>,
9422 Response = http::Response<
9423 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
9424 >,
9425 >,
9426 <T as tonic::codegen::Service<
9427 http::Request<tonic::body::Body>,
9428 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
9429 {
9430 SqlBackupsServiceClient::new(InterceptedService::new(inner, interceptor))
9431 }
9432 #[must_use]
9437 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9438 self.inner = self.inner.send_compressed(encoding);
9439 self
9440 }
9441 #[must_use]
9443 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9444 self.inner = self.inner.accept_compressed(encoding);
9445 self
9446 }
9447 #[must_use]
9451 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9452 self.inner = self.inner.max_decoding_message_size(limit);
9453 self
9454 }
9455 #[must_use]
9459 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9460 self.inner = self.inner.max_encoding_message_size(limit);
9461 self
9462 }
9463 pub async fn create_backup(
9466 &mut self,
9467 request: impl tonic::IntoRequest<super::CreateBackupRequest>,
9468 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
9469 self.inner
9470 .ready()
9471 .await
9472 .map_err(|e| {
9473 tonic::Status::unknown(
9474 format!("Service was not ready: {}", e.into()),
9475 )
9476 })?;
9477 let codec = tonic_prost::ProstCodec::default();
9478 let path = http::uri::PathAndQuery::from_static(
9479 "/google.cloud.sql.v1beta4.SqlBackupsService/CreateBackup",
9480 );
9481 let mut req = request.into_request();
9482 req.extensions_mut()
9483 .insert(
9484 GrpcMethod::new(
9485 "google.cloud.sql.v1beta4.SqlBackupsService",
9486 "CreateBackup",
9487 ),
9488 );
9489 self.inner.unary(req, path, codec).await
9490 }
9491 pub async fn get_backup(
9493 &mut self,
9494 request: impl tonic::IntoRequest<super::GetBackupRequest>,
9495 ) -> std::result::Result<tonic::Response<super::Backup>, tonic::Status> {
9496 self.inner
9497 .ready()
9498 .await
9499 .map_err(|e| {
9500 tonic::Status::unknown(
9501 format!("Service was not ready: {}", e.into()),
9502 )
9503 })?;
9504 let codec = tonic_prost::ProstCodec::default();
9505 let path = http::uri::PathAndQuery::from_static(
9506 "/google.cloud.sql.v1beta4.SqlBackupsService/GetBackup",
9507 );
9508 let mut req = request.into_request();
9509 req.extensions_mut()
9510 .insert(
9511 GrpcMethod::new(
9512 "google.cloud.sql.v1beta4.SqlBackupsService",
9513 "GetBackup",
9514 ),
9515 );
9516 self.inner.unary(req, path, codec).await
9517 }
9518 pub async fn list_backups(
9520 &mut self,
9521 request: impl tonic::IntoRequest<super::ListBackupsRequest>,
9522 ) -> std::result::Result<
9523 tonic::Response<super::ListBackupsResponse>,
9524 tonic::Status,
9525 > {
9526 self.inner
9527 .ready()
9528 .await
9529 .map_err(|e| {
9530 tonic::Status::unknown(
9531 format!("Service was not ready: {}", e.into()),
9532 )
9533 })?;
9534 let codec = tonic_prost::ProstCodec::default();
9535 let path = http::uri::PathAndQuery::from_static(
9536 "/google.cloud.sql.v1beta4.SqlBackupsService/ListBackups",
9537 );
9538 let mut req = request.into_request();
9539 req.extensions_mut()
9540 .insert(
9541 GrpcMethod::new(
9542 "google.cloud.sql.v1beta4.SqlBackupsService",
9543 "ListBackups",
9544 ),
9545 );
9546 self.inner.unary(req, path, codec).await
9547 }
9548 pub async fn update_backup(
9551 &mut self,
9552 request: impl tonic::IntoRequest<super::UpdateBackupRequest>,
9553 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
9554 self.inner
9555 .ready()
9556 .await
9557 .map_err(|e| {
9558 tonic::Status::unknown(
9559 format!("Service was not ready: {}", e.into()),
9560 )
9561 })?;
9562 let codec = tonic_prost::ProstCodec::default();
9563 let path = http::uri::PathAndQuery::from_static(
9564 "/google.cloud.sql.v1beta4.SqlBackupsService/UpdateBackup",
9565 );
9566 let mut req = request.into_request();
9567 req.extensions_mut()
9568 .insert(
9569 GrpcMethod::new(
9570 "google.cloud.sql.v1beta4.SqlBackupsService",
9571 "UpdateBackup",
9572 ),
9573 );
9574 self.inner.unary(req, path, codec).await
9575 }
9576 pub async fn delete_backup(
9578 &mut self,
9579 request: impl tonic::IntoRequest<super::DeleteBackupRequest>,
9580 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
9581 self.inner
9582 .ready()
9583 .await
9584 .map_err(|e| {
9585 tonic::Status::unknown(
9586 format!("Service was not ready: {}", e.into()),
9587 )
9588 })?;
9589 let codec = tonic_prost::ProstCodec::default();
9590 let path = http::uri::PathAndQuery::from_static(
9591 "/google.cloud.sql.v1beta4.SqlBackupsService/DeleteBackup",
9592 );
9593 let mut req = request.into_request();
9594 req.extensions_mut()
9595 .insert(
9596 GrpcMethod::new(
9597 "google.cloud.sql.v1beta4.SqlBackupsService",
9598 "DeleteBackup",
9599 ),
9600 );
9601 self.inner.unary(req, path, codec).await
9602 }
9603 }
9604}
9605#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9607pub struct GetConnectSettingsRequest {
9608 #[prost(string, tag = "1")]
9610 pub instance: ::prost::alloc::string::String,
9611 #[prost(string, tag = "2")]
9613 pub project: ::prost::alloc::string::String,
9614 #[prost(message, optional, tag = "7")]
9617 pub read_time: ::core::option::Option<::prost_types::Timestamp>,
9618}
9619#[derive(Clone, PartialEq, ::prost::Message)]
9621pub struct ConnectSettings {
9622 #[prost(string, tag = "1")]
9624 pub kind: ::prost::alloc::string::String,
9625 #[prost(message, optional, tag = "2")]
9627 pub server_ca_cert: ::core::option::Option<SslCert>,
9628 #[prost(message, repeated, tag = "3")]
9630 pub ip_addresses: ::prost::alloc::vec::Vec<IpMapping>,
9631 #[prost(string, tag = "4")]
9634 pub region: ::prost::alloc::string::String,
9635 #[prost(enumeration = "SqlDatabaseVersion", tag = "31")]
9647 pub database_version: i32,
9648 #[prost(enumeration = "SqlBackendType", tag = "32")]
9653 pub backend_type: i32,
9654 #[prost(bool, tag = "33")]
9656 pub psc_enabled: bool,
9657 #[prost(string, tag = "34")]
9659 pub dns_name: ::prost::alloc::string::String,
9660 #[prost(enumeration = "connect_settings::CaMode", tag = "35")]
9662 pub server_ca_mode: i32,
9663 #[prost(string, repeated, tag = "37")]
9665 pub custom_subject_alternative_names: ::prost::alloc::vec::Vec<
9666 ::prost::alloc::string::String,
9667 >,
9668 #[prost(message, repeated, tag = "38")]
9670 pub dns_names: ::prost::alloc::vec::Vec<DnsNameMapping>,
9671 #[prost(int32, optional, tag = "63")]
9673 pub node_count: ::core::option::Option<i32>,
9674 #[prost(message, repeated, tag = "64")]
9677 pub nodes: ::prost::alloc::vec::Vec<connect_settings::ConnectPoolNodeConfig>,
9678 #[prost(
9684 enumeration = "connect_settings::MdxProtocolSupport",
9685 repeated,
9686 packed = "false",
9687 tag = "39"
9688 )]
9689 pub mdx_protocol_support: ::prost::alloc::vec::Vec<i32>,
9690}
9691pub mod connect_settings {
9693 #[derive(Clone, PartialEq, ::prost::Message)]
9695 pub struct ConnectPoolNodeConfig {
9696 #[prost(string, optional, tag = "1")]
9699 pub name: ::core::option::Option<::prost::alloc::string::String>,
9700 #[prost(message, repeated, tag = "2")]
9703 pub ip_addresses: ::prost::alloc::vec::Vec<super::IpMapping>,
9704 #[prost(string, optional, tag = "3")]
9706 pub dns_name: ::core::option::Option<::prost::alloc::string::String>,
9707 #[prost(message, repeated, tag = "4")]
9709 pub dns_names: ::prost::alloc::vec::Vec<super::DnsNameMapping>,
9710 }
9711 #[derive(
9713 Clone,
9714 Copy,
9715 Debug,
9716 PartialEq,
9717 Eq,
9718 Hash,
9719 PartialOrd,
9720 Ord,
9721 ::prost::Enumeration
9722 )]
9723 #[repr(i32)]
9724 pub enum CaMode {
9725 Unspecified = 0,
9728 GoogleManagedInternalCa = 1,
9730 GoogleManagedCasCa = 2,
9733 CustomerManagedCasCa = 3,
9736 }
9737 impl CaMode {
9738 pub fn as_str_name(&self) -> &'static str {
9743 match self {
9744 Self::Unspecified => "CA_MODE_UNSPECIFIED",
9745 Self::GoogleManagedInternalCa => "GOOGLE_MANAGED_INTERNAL_CA",
9746 Self::GoogleManagedCasCa => "GOOGLE_MANAGED_CAS_CA",
9747 Self::CustomerManagedCasCa => "CUSTOMER_MANAGED_CAS_CA",
9748 }
9749 }
9750 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
9752 match value {
9753 "CA_MODE_UNSPECIFIED" => Some(Self::Unspecified),
9754 "GOOGLE_MANAGED_INTERNAL_CA" => Some(Self::GoogleManagedInternalCa),
9755 "GOOGLE_MANAGED_CAS_CA" => Some(Self::GoogleManagedCasCa),
9756 "CUSTOMER_MANAGED_CAS_CA" => Some(Self::CustomerManagedCasCa),
9757 _ => None,
9758 }
9759 }
9760 }
9761 #[derive(
9764 Clone,
9765 Copy,
9766 Debug,
9767 PartialEq,
9768 Eq,
9769 Hash,
9770 PartialOrd,
9771 Ord,
9772 ::prost::Enumeration
9773 )]
9774 #[repr(i32)]
9775 pub enum MdxProtocolSupport {
9776 Unspecified = 0,
9778 ClientProtocolType = 1,
9780 }
9781 impl MdxProtocolSupport {
9782 pub fn as_str_name(&self) -> &'static str {
9787 match self {
9788 Self::Unspecified => "MDX_PROTOCOL_SUPPORT_UNSPECIFIED",
9789 Self::ClientProtocolType => "CLIENT_PROTOCOL_TYPE",
9790 }
9791 }
9792 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
9794 match value {
9795 "MDX_PROTOCOL_SUPPORT_UNSPECIFIED" => Some(Self::Unspecified),
9796 "CLIENT_PROTOCOL_TYPE" => Some(Self::ClientProtocolType),
9797 _ => None,
9798 }
9799 }
9800 }
9801}
9802#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9804pub struct GenerateEphemeralCertRequest {
9805 #[prost(string, tag = "1")]
9807 pub instance: ::prost::alloc::string::String,
9808 #[prost(string, tag = "2")]
9810 pub project: ::prost::alloc::string::String,
9811 #[prost(string, tag = "3")]
9813 pub public_key: ::prost::alloc::string::String,
9814 #[prost(string, tag = "4")]
9816 pub access_token: ::prost::alloc::string::String,
9817 #[prost(message, optional, tag = "7")]
9820 pub read_time: ::core::option::Option<::prost_types::Timestamp>,
9821 #[prost(message, optional, tag = "12")]
9823 pub valid_duration: ::core::option::Option<::prost_types::Duration>,
9824}
9825#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
9827pub struct GenerateEphemeralCertResponse {
9828 #[prost(message, optional, tag = "1")]
9830 pub ephemeral_cert: ::core::option::Option<SslCert>,
9831}
9832pub mod sql_connect_service_client {
9834 #![allow(
9835 unused_variables,
9836 dead_code,
9837 missing_docs,
9838 clippy::wildcard_imports,
9839 clippy::let_unit_value,
9840 )]
9841 use tonic::codegen::*;
9842 use tonic::codegen::http::Uri;
9843 #[derive(Debug, Clone)]
9845 pub struct SqlConnectServiceClient<T> {
9846 inner: tonic::client::Grpc<T>,
9847 }
9848 impl<T> SqlConnectServiceClient<T>
9849 where
9850 T: tonic::client::GrpcService<tonic::body::Body>,
9851 T::Error: Into<StdError>,
9852 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
9853 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
9854 {
9855 pub fn new(inner: T) -> Self {
9856 let inner = tonic::client::Grpc::new(inner);
9857 Self { inner }
9858 }
9859 pub fn with_origin(inner: T, origin: Uri) -> Self {
9860 let inner = tonic::client::Grpc::with_origin(inner, origin);
9861 Self { inner }
9862 }
9863 pub fn with_interceptor<F>(
9864 inner: T,
9865 interceptor: F,
9866 ) -> SqlConnectServiceClient<InterceptedService<T, F>>
9867 where
9868 F: tonic::service::Interceptor,
9869 T::ResponseBody: Default,
9870 T: tonic::codegen::Service<
9871 http::Request<tonic::body::Body>,
9872 Response = http::Response<
9873 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
9874 >,
9875 >,
9876 <T as tonic::codegen::Service<
9877 http::Request<tonic::body::Body>,
9878 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
9879 {
9880 SqlConnectServiceClient::new(InterceptedService::new(inner, interceptor))
9881 }
9882 #[must_use]
9887 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
9888 self.inner = self.inner.send_compressed(encoding);
9889 self
9890 }
9891 #[must_use]
9893 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
9894 self.inner = self.inner.accept_compressed(encoding);
9895 self
9896 }
9897 #[must_use]
9901 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
9902 self.inner = self.inner.max_decoding_message_size(limit);
9903 self
9904 }
9905 #[must_use]
9909 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
9910 self.inner = self.inner.max_encoding_message_size(limit);
9911 self
9912 }
9913 pub async fn get_connect_settings(
9915 &mut self,
9916 request: impl tonic::IntoRequest<super::GetConnectSettingsRequest>,
9917 ) -> std::result::Result<
9918 tonic::Response<super::ConnectSettings>,
9919 tonic::Status,
9920 > {
9921 self.inner
9922 .ready()
9923 .await
9924 .map_err(|e| {
9925 tonic::Status::unknown(
9926 format!("Service was not ready: {}", e.into()),
9927 )
9928 })?;
9929 let codec = tonic_prost::ProstCodec::default();
9930 let path = http::uri::PathAndQuery::from_static(
9931 "/google.cloud.sql.v1beta4.SqlConnectService/GetConnectSettings",
9932 );
9933 let mut req = request.into_request();
9934 req.extensions_mut()
9935 .insert(
9936 GrpcMethod::new(
9937 "google.cloud.sql.v1beta4.SqlConnectService",
9938 "GetConnectSettings",
9939 ),
9940 );
9941 self.inner.unary(req, path, codec).await
9942 }
9943 pub async fn generate_ephemeral_cert(
9948 &mut self,
9949 request: impl tonic::IntoRequest<super::GenerateEphemeralCertRequest>,
9950 ) -> std::result::Result<
9951 tonic::Response<super::GenerateEphemeralCertResponse>,
9952 tonic::Status,
9953 > {
9954 self.inner
9955 .ready()
9956 .await
9957 .map_err(|e| {
9958 tonic::Status::unknown(
9959 format!("Service was not ready: {}", e.into()),
9960 )
9961 })?;
9962 let codec = tonic_prost::ProstCodec::default();
9963 let path = http::uri::PathAndQuery::from_static(
9964 "/google.cloud.sql.v1beta4.SqlConnectService/GenerateEphemeralCert",
9965 );
9966 let mut req = request.into_request();
9967 req.extensions_mut()
9968 .insert(
9969 GrpcMethod::new(
9970 "google.cloud.sql.v1beta4.SqlConnectService",
9971 "GenerateEphemeralCert",
9972 ),
9973 );
9974 self.inner.unary(req, path, codec).await
9975 }
9976 }
9977}
9978pub mod sql_iam_policies_service_client {
9980 #![allow(
9981 unused_variables,
9982 dead_code,
9983 missing_docs,
9984 clippy::wildcard_imports,
9985 clippy::let_unit_value,
9986 )]
9987 use tonic::codegen::*;
9988 use tonic::codegen::http::Uri;
9989 #[derive(Debug, Clone)]
9991 pub struct SqlIamPoliciesServiceClient<T> {
9992 inner: tonic::client::Grpc<T>,
9993 }
9994 impl<T> SqlIamPoliciesServiceClient<T>
9995 where
9996 T: tonic::client::GrpcService<tonic::body::Body>,
9997 T::Error: Into<StdError>,
9998 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
9999 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
10000 {
10001 pub fn new(inner: T) -> Self {
10002 let inner = tonic::client::Grpc::new(inner);
10003 Self { inner }
10004 }
10005 pub fn with_origin(inner: T, origin: Uri) -> Self {
10006 let inner = tonic::client::Grpc::with_origin(inner, origin);
10007 Self { inner }
10008 }
10009 pub fn with_interceptor<F>(
10010 inner: T,
10011 interceptor: F,
10012 ) -> SqlIamPoliciesServiceClient<InterceptedService<T, F>>
10013 where
10014 F: tonic::service::Interceptor,
10015 T::ResponseBody: Default,
10016 T: tonic::codegen::Service<
10017 http::Request<tonic::body::Body>,
10018 Response = http::Response<
10019 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
10020 >,
10021 >,
10022 <T as tonic::codegen::Service<
10023 http::Request<tonic::body::Body>,
10024 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
10025 {
10026 SqlIamPoliciesServiceClient::new(InterceptedService::new(inner, interceptor))
10027 }
10028 #[must_use]
10033 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
10034 self.inner = self.inner.send_compressed(encoding);
10035 self
10036 }
10037 #[must_use]
10039 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
10040 self.inner = self.inner.accept_compressed(encoding);
10041 self
10042 }
10043 #[must_use]
10047 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
10048 self.inner = self.inner.max_decoding_message_size(limit);
10049 self
10050 }
10051 #[must_use]
10055 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
10056 self.inner = self.inner.max_encoding_message_size(limit);
10057 self
10058 }
10059 }
10060}
10061#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10062pub struct SqlTiersListRequest {
10063 #[prost(string, tag = "1")]
10065 pub project: ::prost::alloc::string::String,
10066}
10067#[derive(Clone, PartialEq, ::prost::Message)]
10069pub struct TiersListResponse {
10070 #[prost(string, tag = "1")]
10072 pub kind: ::prost::alloc::string::String,
10073 #[prost(message, repeated, tag = "2")]
10075 pub items: ::prost::alloc::vec::Vec<Tier>,
10076}
10077#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10079pub struct Tier {
10080 #[prost(string, tag = "1")]
10083 pub tier: ::prost::alloc::string::String,
10084 #[prost(int64, tag = "2")]
10086 pub ram: i64,
10087 #[prost(string, tag = "3")]
10089 pub kind: ::prost::alloc::string::String,
10090 #[prost(int64, tag = "4")]
10092 pub disk_quota: i64,
10093 #[prost(string, repeated, tag = "5")]
10095 pub region: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
10096}
10097pub mod sql_tiers_service_client {
10099 #![allow(
10100 unused_variables,
10101 dead_code,
10102 missing_docs,
10103 clippy::wildcard_imports,
10104 clippy::let_unit_value,
10105 )]
10106 use tonic::codegen::*;
10107 use tonic::codegen::http::Uri;
10108 #[derive(Debug, Clone)]
10110 pub struct SqlTiersServiceClient<T> {
10111 inner: tonic::client::Grpc<T>,
10112 }
10113 impl<T> SqlTiersServiceClient<T>
10114 where
10115 T: tonic::client::GrpcService<tonic::body::Body>,
10116 T::Error: Into<StdError>,
10117 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
10118 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
10119 {
10120 pub fn new(inner: T) -> Self {
10121 let inner = tonic::client::Grpc::new(inner);
10122 Self { inner }
10123 }
10124 pub fn with_origin(inner: T, origin: Uri) -> Self {
10125 let inner = tonic::client::Grpc::with_origin(inner, origin);
10126 Self { inner }
10127 }
10128 pub fn with_interceptor<F>(
10129 inner: T,
10130 interceptor: F,
10131 ) -> SqlTiersServiceClient<InterceptedService<T, F>>
10132 where
10133 F: tonic::service::Interceptor,
10134 T::ResponseBody: Default,
10135 T: tonic::codegen::Service<
10136 http::Request<tonic::body::Body>,
10137 Response = http::Response<
10138 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
10139 >,
10140 >,
10141 <T as tonic::codegen::Service<
10142 http::Request<tonic::body::Body>,
10143 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
10144 {
10145 SqlTiersServiceClient::new(InterceptedService::new(inner, interceptor))
10146 }
10147 #[must_use]
10152 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
10153 self.inner = self.inner.send_compressed(encoding);
10154 self
10155 }
10156 #[must_use]
10158 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
10159 self.inner = self.inner.accept_compressed(encoding);
10160 self
10161 }
10162 #[must_use]
10166 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
10167 self.inner = self.inner.max_decoding_message_size(limit);
10168 self
10169 }
10170 #[must_use]
10174 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
10175 self.inner = self.inner.max_encoding_message_size(limit);
10176 self
10177 }
10178 pub async fn list(
10181 &mut self,
10182 request: impl tonic::IntoRequest<super::SqlTiersListRequest>,
10183 ) -> std::result::Result<
10184 tonic::Response<super::TiersListResponse>,
10185 tonic::Status,
10186 > {
10187 self.inner
10188 .ready()
10189 .await
10190 .map_err(|e| {
10191 tonic::Status::unknown(
10192 format!("Service was not ready: {}", e.into()),
10193 )
10194 })?;
10195 let codec = tonic_prost::ProstCodec::default();
10196 let path = http::uri::PathAndQuery::from_static(
10197 "/google.cloud.sql.v1beta4.SqlTiersService/List",
10198 );
10199 let mut req = request.into_request();
10200 req.extensions_mut()
10201 .insert(
10202 GrpcMethod::new("google.cloud.sql.v1beta4.SqlTiersService", "List"),
10203 );
10204 self.inner.unary(req, path, codec).await
10205 }
10206 }
10207}
10208#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10209pub struct SqlUsersDeleteRequest {
10210 #[prost(string, tag = "1")]
10212 pub host: ::prost::alloc::string::String,
10213 #[prost(string, tag = "2")]
10215 pub instance: ::prost::alloc::string::String,
10216 #[prost(string, tag = "3")]
10218 pub name: ::prost::alloc::string::String,
10219 #[prost(string, tag = "4")]
10221 pub project: ::prost::alloc::string::String,
10222}
10223#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10225pub struct SqlUsersGetRequest {
10226 #[prost(string, tag = "1")]
10228 pub instance: ::prost::alloc::string::String,
10229 #[prost(string, tag = "2")]
10231 pub name: ::prost::alloc::string::String,
10232 #[prost(string, tag = "3")]
10234 pub project: ::prost::alloc::string::String,
10235 #[prost(string, tag = "4")]
10237 pub host: ::prost::alloc::string::String,
10238}
10239#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10240pub struct SqlUsersInsertRequest {
10241 #[prost(string, tag = "1")]
10243 pub instance: ::prost::alloc::string::String,
10244 #[prost(string, tag = "2")]
10246 pub project: ::prost::alloc::string::String,
10247 #[prost(message, optional, tag = "100")]
10248 pub body: ::core::option::Option<User>,
10249}
10250#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10251pub struct SqlUsersListRequest {
10252 #[prost(string, tag = "1")]
10254 pub instance: ::prost::alloc::string::String,
10255 #[prost(string, tag = "2")]
10257 pub project: ::prost::alloc::string::String,
10258}
10259#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10260pub struct SqlUsersUpdateRequest {
10261 #[prost(string, tag = "1")]
10263 pub host: ::prost::alloc::string::String,
10264 #[prost(string, tag = "2")]
10266 pub instance: ::prost::alloc::string::String,
10267 #[prost(string, tag = "3")]
10269 pub name: ::prost::alloc::string::String,
10270 #[prost(string, tag = "4")]
10272 pub project: ::prost::alloc::string::String,
10273 #[prost(string, repeated, tag = "5")]
10276 pub database_roles: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
10277 #[prost(bool, optional, tag = "6")]
10281 pub revoke_existing_roles: ::core::option::Option<bool>,
10282 #[prost(message, optional, tag = "100")]
10283 pub body: ::core::option::Option<User>,
10284}
10285#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
10287pub struct UserPasswordValidationPolicy {
10288 #[prost(int32, tag = "1")]
10290 pub allowed_failed_attempts: i32,
10291 #[prost(message, optional, tag = "2")]
10293 pub password_expiration_duration: ::core::option::Option<::prost_types::Duration>,
10294 #[prost(bool, tag = "3")]
10296 pub enable_failed_attempts_check: bool,
10297 #[prost(message, optional, tag = "4")]
10299 pub status: ::core::option::Option<PasswordStatus>,
10300 #[prost(bool, tag = "5")]
10303 pub enable_password_verification: bool,
10304}
10305#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
10307pub struct PasswordStatus {
10308 #[prost(bool, tag = "1")]
10310 pub locked: bool,
10311 #[prost(message, optional, tag = "2")]
10313 pub password_expiration_time: ::core::option::Option<::prost_types::Timestamp>,
10314}
10315#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10317pub struct User {
10318 #[prost(string, tag = "1")]
10320 pub kind: ::prost::alloc::string::String,
10321 #[prost(string, tag = "2")]
10323 pub password: ::prost::alloc::string::String,
10324 #[prost(string, tag = "3")]
10327 pub etag: ::prost::alloc::string::String,
10328 #[prost(string, tag = "4")]
10331 pub name: ::prost::alloc::string::String,
10332 #[prost(string, tag = "5")]
10338 pub host: ::prost::alloc::string::String,
10339 #[prost(string, tag = "6")]
10343 pub instance: ::prost::alloc::string::String,
10344 #[prost(string, tag = "7")]
10348 pub project: ::prost::alloc::string::String,
10349 #[prost(enumeration = "user::SqlUserType", tag = "8")]
10352 pub r#type: i32,
10353 #[prost(string, tag = "11")]
10356 pub iam_email: ::prost::alloc::string::String,
10357 #[prost(message, optional, tag = "12")]
10359 pub password_policy: ::core::option::Option<UserPasswordValidationPolicy>,
10360 #[prost(enumeration = "user::DualPasswordType", optional, tag = "13")]
10362 pub dual_password_type: ::core::option::Option<i32>,
10363 #[prost(enumeration = "user::IamStatus", optional, tag = "14")]
10365 pub iam_status: ::core::option::Option<i32>,
10366 #[prost(string, repeated, tag = "15")]
10368 pub database_roles: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
10369 #[prost(oneof = "user::UserDetails", tags = "9")]
10371 pub user_details: ::core::option::Option<user::UserDetails>,
10372}
10373pub mod user {
10375 #[derive(
10377 Clone,
10378 Copy,
10379 Debug,
10380 PartialEq,
10381 Eq,
10382 Hash,
10383 PartialOrd,
10384 Ord,
10385 ::prost::Enumeration
10386 )]
10387 #[repr(i32)]
10388 pub enum SqlUserType {
10389 BuiltIn = 0,
10391 CloudIamUser = 1,
10393 CloudIamServiceAccount = 2,
10395 CloudIamGroup = 3,
10397 CloudIamGroupUser = 4,
10399 CloudIamGroupServiceAccount = 5,
10402 EntraidUser = 7,
10404 }
10405 impl SqlUserType {
10406 pub fn as_str_name(&self) -> &'static str {
10411 match self {
10412 Self::BuiltIn => "BUILT_IN",
10413 Self::CloudIamUser => "CLOUD_IAM_USER",
10414 Self::CloudIamServiceAccount => "CLOUD_IAM_SERVICE_ACCOUNT",
10415 Self::CloudIamGroup => "CLOUD_IAM_GROUP",
10416 Self::CloudIamGroupUser => "CLOUD_IAM_GROUP_USER",
10417 Self::CloudIamGroupServiceAccount => "CLOUD_IAM_GROUP_SERVICE_ACCOUNT",
10418 Self::EntraidUser => "ENTRAID_USER",
10419 }
10420 }
10421 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
10423 match value {
10424 "BUILT_IN" => Some(Self::BuiltIn),
10425 "CLOUD_IAM_USER" => Some(Self::CloudIamUser),
10426 "CLOUD_IAM_SERVICE_ACCOUNT" => Some(Self::CloudIamServiceAccount),
10427 "CLOUD_IAM_GROUP" => Some(Self::CloudIamGroup),
10428 "CLOUD_IAM_GROUP_USER" => Some(Self::CloudIamGroupUser),
10429 "CLOUD_IAM_GROUP_SERVICE_ACCOUNT" => {
10430 Some(Self::CloudIamGroupServiceAccount)
10431 }
10432 "ENTRAID_USER" => Some(Self::EntraidUser),
10433 _ => None,
10434 }
10435 }
10436 }
10437 #[derive(
10439 Clone,
10440 Copy,
10441 Debug,
10442 PartialEq,
10443 Eq,
10444 Hash,
10445 PartialOrd,
10446 Ord,
10447 ::prost::Enumeration
10448 )]
10449 #[repr(i32)]
10450 pub enum DualPasswordType {
10451 Unspecified = 0,
10453 NoModifyDualPassword = 1,
10455 NoDualPassword = 2,
10457 DualPassword = 3,
10459 }
10460 impl DualPasswordType {
10461 pub fn as_str_name(&self) -> &'static str {
10466 match self {
10467 Self::Unspecified => "DUAL_PASSWORD_TYPE_UNSPECIFIED",
10468 Self::NoModifyDualPassword => "NO_MODIFY_DUAL_PASSWORD",
10469 Self::NoDualPassword => "NO_DUAL_PASSWORD",
10470 Self::DualPassword => "DUAL_PASSWORD",
10471 }
10472 }
10473 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
10475 match value {
10476 "DUAL_PASSWORD_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
10477 "NO_MODIFY_DUAL_PASSWORD" => Some(Self::NoModifyDualPassword),
10478 "NO_DUAL_PASSWORD" => Some(Self::NoDualPassword),
10479 "DUAL_PASSWORD" => Some(Self::DualPassword),
10480 _ => None,
10481 }
10482 }
10483 }
10484 #[derive(
10486 Clone,
10487 Copy,
10488 Debug,
10489 PartialEq,
10490 Eq,
10491 Hash,
10492 PartialOrd,
10493 Ord,
10494 ::prost::Enumeration
10495 )]
10496 #[repr(i32)]
10497 pub enum IamStatus {
10498 Unspecified = 0,
10504 Inactive = 1,
10507 Active = 2,
10509 }
10510 impl IamStatus {
10511 pub fn as_str_name(&self) -> &'static str {
10516 match self {
10517 Self::Unspecified => "IAM_STATUS_UNSPECIFIED",
10518 Self::Inactive => "INACTIVE",
10519 Self::Active => "ACTIVE",
10520 }
10521 }
10522 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
10524 match value {
10525 "IAM_STATUS_UNSPECIFIED" => Some(Self::Unspecified),
10526 "INACTIVE" => Some(Self::Inactive),
10527 "ACTIVE" => Some(Self::Active),
10528 _ => None,
10529 }
10530 }
10531 }
10532 #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
10534 pub enum UserDetails {
10535 #[prost(message, tag = "9")]
10536 SqlserverUserDetails(super::SqlServerUserDetails),
10537 }
10538}
10539#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
10541pub struct SqlServerUserDetails {
10542 #[prost(bool, tag = "1")]
10544 pub disabled: bool,
10545 #[prost(string, repeated, tag = "2")]
10547 pub server_roles: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
10548}
10549#[derive(Clone, PartialEq, ::prost::Message)]
10551pub struct UsersListResponse {
10552 #[prost(string, tag = "1")]
10554 pub kind: ::prost::alloc::string::String,
10555 #[prost(message, repeated, tag = "2")]
10557 pub items: ::prost::alloc::vec::Vec<User>,
10558 #[deprecated]
10560 #[prost(string, tag = "3")]
10561 pub next_page_token: ::prost::alloc::string::String,
10562}
10563pub mod sql_users_service_client {
10565 #![allow(
10566 unused_variables,
10567 dead_code,
10568 missing_docs,
10569 clippy::wildcard_imports,
10570 clippy::let_unit_value,
10571 )]
10572 use tonic::codegen::*;
10573 use tonic::codegen::http::Uri;
10574 #[derive(Debug, Clone)]
10575 pub struct SqlUsersServiceClient<T> {
10576 inner: tonic::client::Grpc<T>,
10577 }
10578 impl<T> SqlUsersServiceClient<T>
10579 where
10580 T: tonic::client::GrpcService<tonic::body::Body>,
10581 T::Error: Into<StdError>,
10582 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
10583 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
10584 {
10585 pub fn new(inner: T) -> Self {
10586 let inner = tonic::client::Grpc::new(inner);
10587 Self { inner }
10588 }
10589 pub fn with_origin(inner: T, origin: Uri) -> Self {
10590 let inner = tonic::client::Grpc::with_origin(inner, origin);
10591 Self { inner }
10592 }
10593 pub fn with_interceptor<F>(
10594 inner: T,
10595 interceptor: F,
10596 ) -> SqlUsersServiceClient<InterceptedService<T, F>>
10597 where
10598 F: tonic::service::Interceptor,
10599 T::ResponseBody: Default,
10600 T: tonic::codegen::Service<
10601 http::Request<tonic::body::Body>,
10602 Response = http::Response<
10603 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
10604 >,
10605 >,
10606 <T as tonic::codegen::Service<
10607 http::Request<tonic::body::Body>,
10608 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
10609 {
10610 SqlUsersServiceClient::new(InterceptedService::new(inner, interceptor))
10611 }
10612 #[must_use]
10617 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
10618 self.inner = self.inner.send_compressed(encoding);
10619 self
10620 }
10621 #[must_use]
10623 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
10624 self.inner = self.inner.accept_compressed(encoding);
10625 self
10626 }
10627 #[must_use]
10631 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
10632 self.inner = self.inner.max_decoding_message_size(limit);
10633 self
10634 }
10635 #[must_use]
10639 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
10640 self.inner = self.inner.max_encoding_message_size(limit);
10641 self
10642 }
10643 pub async fn delete(
10645 &mut self,
10646 request: impl tonic::IntoRequest<super::SqlUsersDeleteRequest>,
10647 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
10648 self.inner
10649 .ready()
10650 .await
10651 .map_err(|e| {
10652 tonic::Status::unknown(
10653 format!("Service was not ready: {}", e.into()),
10654 )
10655 })?;
10656 let codec = tonic_prost::ProstCodec::default();
10657 let path = http::uri::PathAndQuery::from_static(
10658 "/google.cloud.sql.v1beta4.SqlUsersService/Delete",
10659 );
10660 let mut req = request.into_request();
10661 req.extensions_mut()
10662 .insert(
10663 GrpcMethod::new("google.cloud.sql.v1beta4.SqlUsersService", "Delete"),
10664 );
10665 self.inner.unary(req, path, codec).await
10666 }
10667 pub async fn get(
10669 &mut self,
10670 request: impl tonic::IntoRequest<super::SqlUsersGetRequest>,
10671 ) -> std::result::Result<tonic::Response<super::User>, tonic::Status> {
10672 self.inner
10673 .ready()
10674 .await
10675 .map_err(|e| {
10676 tonic::Status::unknown(
10677 format!("Service was not ready: {}", e.into()),
10678 )
10679 })?;
10680 let codec = tonic_prost::ProstCodec::default();
10681 let path = http::uri::PathAndQuery::from_static(
10682 "/google.cloud.sql.v1beta4.SqlUsersService/Get",
10683 );
10684 let mut req = request.into_request();
10685 req.extensions_mut()
10686 .insert(
10687 GrpcMethod::new("google.cloud.sql.v1beta4.SqlUsersService", "Get"),
10688 );
10689 self.inner.unary(req, path, codec).await
10690 }
10691 pub async fn insert(
10693 &mut self,
10694 request: impl tonic::IntoRequest<super::SqlUsersInsertRequest>,
10695 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
10696 self.inner
10697 .ready()
10698 .await
10699 .map_err(|e| {
10700 tonic::Status::unknown(
10701 format!("Service was not ready: {}", e.into()),
10702 )
10703 })?;
10704 let codec = tonic_prost::ProstCodec::default();
10705 let path = http::uri::PathAndQuery::from_static(
10706 "/google.cloud.sql.v1beta4.SqlUsersService/Insert",
10707 );
10708 let mut req = request.into_request();
10709 req.extensions_mut()
10710 .insert(
10711 GrpcMethod::new("google.cloud.sql.v1beta4.SqlUsersService", "Insert"),
10712 );
10713 self.inner.unary(req, path, codec).await
10714 }
10715 pub async fn list(
10717 &mut self,
10718 request: impl tonic::IntoRequest<super::SqlUsersListRequest>,
10719 ) -> std::result::Result<
10720 tonic::Response<super::UsersListResponse>,
10721 tonic::Status,
10722 > {
10723 self.inner
10724 .ready()
10725 .await
10726 .map_err(|e| {
10727 tonic::Status::unknown(
10728 format!("Service was not ready: {}", e.into()),
10729 )
10730 })?;
10731 let codec = tonic_prost::ProstCodec::default();
10732 let path = http::uri::PathAndQuery::from_static(
10733 "/google.cloud.sql.v1beta4.SqlUsersService/List",
10734 );
10735 let mut req = request.into_request();
10736 req.extensions_mut()
10737 .insert(
10738 GrpcMethod::new("google.cloud.sql.v1beta4.SqlUsersService", "List"),
10739 );
10740 self.inner.unary(req, path, codec).await
10741 }
10742 pub async fn update(
10744 &mut self,
10745 request: impl tonic::IntoRequest<super::SqlUsersUpdateRequest>,
10746 ) -> std::result::Result<tonic::Response<super::Operation>, tonic::Status> {
10747 self.inner
10748 .ready()
10749 .await
10750 .map_err(|e| {
10751 tonic::Status::unknown(
10752 format!("Service was not ready: {}", e.into()),
10753 )
10754 })?;
10755 let codec = tonic_prost::ProstCodec::default();
10756 let path = http::uri::PathAndQuery::from_static(
10757 "/google.cloud.sql.v1beta4.SqlUsersService/Update",
10758 );
10759 let mut req = request.into_request();
10760 req.extensions_mut()
10761 .insert(
10762 GrpcMethod::new("google.cloud.sql.v1beta4.SqlUsersService", "Update"),
10763 );
10764 self.inner.unary(req, path, codec).await
10765 }
10766 }
10767}