google-apis-sqladmin_v1 0.8.0 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -27,12 +27,12 @@ module Google
27
27
  include Google::Apis::Core::Hashable
28
28
 
29
29
  # The time when this access control entry expires in [RFC 3339](https://tools.
30
- # ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
30
+ # ietf.org/html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
31
31
  # Corresponds to the JSON property `expirationTime`
32
32
  # @return [String]
33
33
  attr_accessor :expiration_time
34
34
 
35
- # This is always **sql#aclEntry**.
35
+ # This is always `sql#aclEntry`.
36
36
  # Corresponds to the JSON property `kind`
37
37
  # @return [String]
38
38
  attr_accessor :kind
@@ -114,7 +114,7 @@ module Google
114
114
  attr_accessor :enabled
115
115
  alias_method :enabled?, :enabled
116
116
 
117
- # This is always **sql#backupConfiguration**.
117
+ # This is always `sql#backupConfiguration`.
118
118
  # Corresponds to the JSON property `kind`
119
119
  # @return [String]
120
120
  attr_accessor :kind
@@ -137,7 +137,7 @@ module Google
137
137
  alias_method :replication_log_archiving_enabled?, :replication_log_archiving_enabled
138
138
 
139
139
  # Start time for the daily backup configuration in UTC timezone in the 24 hour
140
- # format - **HH:MM**.
140
+ # format - `HH:MM`.
141
141
  # Corresponds to the JSON property `startTime`
142
142
  # @return [String]
143
143
  attr_accessor :start_time
@@ -175,7 +175,7 @@ module Google
175
175
  # @return [Fixnum]
176
176
  attr_accessor :backup_id
177
177
 
178
- # This is always **sql#backupContext**.
178
+ # This is always `sql#backupContext`.
179
179
  # Corresponds to the JSON property `kind`
180
180
  # @return [String]
181
181
  attr_accessor :kind
@@ -244,13 +244,13 @@ module Google
244
244
  attr_accessor :disk_encryption_status
245
245
 
246
246
  # The time the backup operation completed in UTC timezone in [RFC 3339](https://
247
- # tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
247
+ # tools.ietf.org/html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
248
248
  # Corresponds to the JSON property `endTime`
249
249
  # @return [String]
250
250
  attr_accessor :end_time
251
251
 
252
252
  # The time the run was enqueued in UTC timezone in [RFC 3339](https://tools.ietf.
253
- # org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
253
+ # org/html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
254
254
  # Corresponds to the JSON property `enqueuedTime`
255
255
  # @return [String]
256
256
  attr_accessor :enqueued_time
@@ -271,7 +271,7 @@ module Google
271
271
  # @return [String]
272
272
  attr_accessor :instance
273
273
 
274
- # This is always **sql#backupRun**.
274
+ # This is always `sql#backupRun`.
275
275
  # Corresponds to the JSON property `kind`
276
276
  # @return [String]
277
277
  attr_accessor :kind
@@ -287,8 +287,8 @@ module Google
287
287
  attr_accessor :self_link
288
288
 
289
289
  # The time the backup operation actually started in UTC timezone in [RFC 3339](
290
- # https://tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.
291
- # 094Z**.
290
+ # https://tools.ietf.org/html/rfc3339) format, for example `2012-11-15T16:19:00.
291
+ # 094Z`.
292
292
  # Corresponds to the JSON property `startTime`
293
293
  # @return [String]
294
294
  attr_accessor :start_time
@@ -305,8 +305,8 @@ module Google
305
305
  attr_accessor :type
306
306
 
307
307
  # The start time of the backup window during which this the backup was attempted
308
- # in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example **2012-
309
- # 11-15T16:19:00.094Z**.
308
+ # in [RFC 3339](https://tools.ietf.org/html/rfc3339) format, for example `2012-
309
+ # 11-15T16:19:00.094Z`.
310
310
  # Corresponds to the JSON property `windowStartTime`
311
311
  # @return [String]
312
312
  attr_accessor :window_start_time
@@ -345,7 +345,7 @@ module Google
345
345
  # @return [Array<Google::Apis::SqladminV1::BackupRun>]
346
346
  attr_accessor :items
347
347
 
348
- # This is always **sql#backupRunsList**.
348
+ # This is always `sql#backupRunsList`.
349
349
  # Corresponds to the JSON property `kind`
350
350
  # @return [String]
351
351
  attr_accessor :kind
@@ -382,7 +382,7 @@ module Google
382
382
  # @return [Fixnum]
383
383
  attr_accessor :bin_log_position
384
384
 
385
- # This is always **sql#binLogCoordinates**.
385
+ # This is always `sql#binLogCoordinates`.
386
386
  # Corresponds to the JSON property `kind`
387
387
  # @return [String]
388
388
  attr_accessor :kind
@@ -403,6 +403,16 @@ module Google
403
403
  class CloneContext
404
404
  include Google::Apis::Core::Hashable
405
405
 
406
+ # The name of the allocated ip range for the private ip CloudSQL instance. For
407
+ # example: "google-managed-services-default". If set, the cloned instance ip
408
+ # will be created in the allocated range. The range name must comply with [RFC
409
+ # 1035](https://tools.ietf.org/html/rfc1035). Specifically, the name must be 1-
410
+ # 63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])?.
411
+ # Reserved for future use.
412
+ # Corresponds to the JSON property `allocatedIpRange`
413
+ # @return [String]
414
+ attr_accessor :allocated_ip_range
415
+
406
416
  # Binary log coordinates.
407
417
  # Corresponds to the JSON property `binLogCoordinates`
408
418
  # @return [Google::Apis::SqladminV1::BinLogCoordinates]
@@ -413,7 +423,7 @@ module Google
413
423
  # @return [String]
414
424
  attr_accessor :destination_instance_name
415
425
 
416
- # This is always **sql#cloneContext**.
426
+ # This is always `sql#cloneContext`.
417
427
  # Corresponds to the JSON property `kind`
418
428
  # @return [String]
419
429
  attr_accessor :kind
@@ -435,6 +445,7 @@ module Google
435
445
 
436
446
  # Update properties of this object
437
447
  def update!(**args)
448
+ @allocated_ip_range = args[:allocated_ip_range] if args.key?(:allocated_ip_range)
438
449
  @bin_log_coordinates = args[:bin_log_coordinates] if args.key?(:bin_log_coordinates)
439
450
  @destination_instance_name = args[:destination_instance_name] if args.key?(:destination_instance_name)
440
451
  @kind = args[:kind] if args.key?(:kind)
@@ -447,19 +458,21 @@ module Google
447
458
  class ConnectSettings
448
459
  include Google::Apis::Core::Hashable
449
460
 
450
- # **SECOND_GEN**: Cloud SQL database instance. **EXTERNAL**: A database server
451
- # that is not managed by Google. This property is read-only; use the **tier**
452
- # property in the **settings** object to determine the database type.
461
+ # `SECOND_GEN`: Cloud SQL database instance. `EXTERNAL`: A database server that
462
+ # is not managed by Google. This property is read-only; use the `tier` property
463
+ # in the `settings` object to determine the database type.
453
464
  # Corresponds to the JSON property `backendType`
454
465
  # @return [String]
455
466
  attr_accessor :backend_type
456
467
 
457
- # The database engine type and version. The **databaseVersion** field cannot be
458
- # changed after instance creation. MySQL instances: **MYSQL_8_0**, **MYSQL_5_7**
459
- # (default), or **MYSQL_5_6**. PostgreSQL instances: **POSTGRES_9_6**, **
460
- # POSTGRES_10**, **POSTGRES_11** or **POSTGRES_12** (default). SQL Server
461
- # instances: **SQLSERVER_2017_STANDARD** (default), **SQLSERVER_2017_ENTERPRISE**
462
- # , **SQLSERVER_2017_EXPRESS**, or **SQLSERVER_2017_WEB**.
468
+ # The database engine type and version. The `databaseVersion` field cannot be
469
+ # changed after instance creation. MySQL instances: `MYSQL_8_0`, `MYSQL_5_7` (
470
+ # default), or `MYSQL_5_6`. PostgreSQL instances: `POSTGRES_9_6`, `POSTGRES_10`,
471
+ # `POSTGRES_11`, `POSTGRES_12` (default), `POSTGRES_13`, or `POSTGRES_14`. SQL
472
+ # Server instances: `SQLSERVER_2017_STANDARD` (default), `
473
+ # SQLSERVER_2017_ENTERPRISE`, `SQLSERVER_2017_EXPRESS`, `SQLSERVER_2017_WEB`, `
474
+ # SQLSERVER_2019_STANDARD`, `SQLSERVER_2019_ENTERPRISE`, `SQLSERVER_2019_EXPRESS`
475
+ # , or `SQLSERVER_2019_WEB`.
463
476
  # Corresponds to the JSON property `databaseVersion`
464
477
  # @return [String]
465
478
  attr_accessor :database_version
@@ -474,8 +487,8 @@ module Google
474
487
  # @return [String]
475
488
  attr_accessor :kind
476
489
 
477
- # The cloud region for the instance. e.g. **us-central1**, **europe-west1**. The
478
- # region cannot be changed after instance creation.
490
+ # The cloud region for the instance. For example, `us-central1`, `europe-west1`.
491
+ # The region cannot be changed after instance creation.
479
492
  # Corresponds to the JSON property `region`
480
493
  # @return [String]
481
494
  attr_accessor :region
@@ -524,7 +537,7 @@ module Google
524
537
  # @return [String]
525
538
  attr_accessor :instance
526
539
 
527
- # This is always **sql#database**.
540
+ # This is always `sql#database`.
528
541
  # Corresponds to the JSON property `kind`
529
542
  # @return [String]
530
543
  attr_accessor :kind
@@ -581,7 +594,7 @@ module Google
581
594
  # @return [String]
582
595
  attr_accessor :name
583
596
 
584
- # The value of the flag. Booleans are set to **on** for true and **off** for
597
+ # The value of the flag. Boolean flags are set to `on` for true and `off` for
585
598
  # false. This field must be omitted if the flag doesn't take a value.
586
599
  # Corresponds to the JSON property `value`
587
600
  # @return [String]
@@ -602,10 +615,9 @@ module Google
602
615
  class DatabaseInstance
603
616
  include Google::Apis::Core::Hashable
604
617
 
605
- # The backend type. **SECOND_GEN**: Cloud SQL database instance. **EXTERNAL**: A
618
+ # The backend type. `SECOND_GEN`: Cloud SQL database instance. `EXTERNAL`: A
606
619
  # database server that is not managed by Google. This property is read-only; use
607
- # the **tier** property in the **settings** object to determine the database
608
- # type.
620
+ # the `tier` property in the `settings` object to determine the database type.
609
621
  # Corresponds to the JSON property `backendType`
610
622
  # @return [String]
611
623
  attr_accessor :backend_type
@@ -616,7 +628,7 @@ module Google
616
628
  attr_accessor :connection_name
617
629
 
618
630
  # Output only. The time when the instance was created in [RFC 3339](https://
619
- # tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
631
+ # tools.ietf.org/html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
620
632
  # Corresponds to the JSON property `createTime`
621
633
  # @return [String]
622
634
  attr_accessor :create_time
@@ -630,14 +642,14 @@ module Google
630
642
  # @return [Fixnum]
631
643
  attr_accessor :current_disk_size
632
644
 
633
- # The database engine type and version. The **databaseVersion** field cannot be
634
- # changed after instance creation. * **MySQL instances**: MYSQL_8_0, MYSQL_5_7 (
635
- # default), or MYSQL_5_6. * **PostgreSQL instances**: POSTGRES_9_6, POSTGRES_10,
636
- # POSTGRES_11, POSTGRES_12, POSTGRES_13 (default), POSTGRES_14. * **SQL Server
637
- # instances**: SQLSERVER_2019_STANDARD, SQLSERVER_2019_ENTERPRISE,
638
- # SQLSERVER_2019_EXPRESS, or SQLSERVER_2019_WEB, SQLSERVER_2017_STANDARD (
639
- # default), SQLSERVER_2017_ENTERPRISE, SQLSERVER_2017_EXPRESS, or
640
- # SQLSERVER_2017_WEB.
645
+ # Output only. Stores the current database version running on the instance
646
+ # including minor version such as `MYSQL_8_0_18`.
647
+ # Corresponds to the JSON property `databaseInstalledVersion`
648
+ # @return [String]
649
+ attr_accessor :database_installed_version
650
+
651
+ # The database engine type and version. The `databaseVersion` field cannot be
652
+ # changed after instance creation.
641
653
  # Corresponds to the JSON property `databaseVersion`
642
654
  # @return [String]
643
655
  attr_accessor :database_version
@@ -653,7 +665,7 @@ module Google
653
665
  attr_accessor :disk_encryption_status
654
666
 
655
667
  # This field is deprecated and will be removed from a future version of the API.
656
- # Use the **settings.settingsVersion** field instead.
668
+ # Use the `settings.settingsVersion` field instead.
657
669
  # Corresponds to the JSON property `etag`
658
670
  # @return [String]
659
671
  attr_accessor :etag
@@ -665,15 +677,13 @@ module Google
665
677
 
666
678
  # The Compute Engine zone that the instance is currently serving from. This
667
679
  # value could be different from the zone that was specified when the instance
668
- # was created if the instance has failed over to its secondary zone.
680
+ # was created if the instance has failed over to its secondary zone. WARNING:
681
+ # Changing this might restart the instance.
669
682
  # Corresponds to the JSON property `gceZone`
670
683
  # @return [String]
671
684
  attr_accessor :gce_zone
672
685
 
673
- # The instance type. This can be one of the following: * **CLOUD_SQL_INSTANCE**:
674
- # A Cloud SQL instance that is not replicating from a primary instance. * **
675
- # ON_PREMISES_INSTANCE**: An instance running on the customer's premises. * **
676
- # READ_REPLICA_INSTANCE**: A Cloud SQL instance configured as a read-replica.
686
+ # The instance type.
677
687
  # Corresponds to the JSON property `instanceType`
678
688
  # @return [String]
679
689
  attr_accessor :instance_type
@@ -689,7 +699,7 @@ module Google
689
699
  # @return [String]
690
700
  attr_accessor :ipv6_address
691
701
 
692
- # This is always **sql#instance**.
702
+ # This is always `sql#instance`.
693
703
  # Corresponds to the JSON property `kind`
694
704
  # @return [String]
695
705
  attr_accessor :kind
@@ -725,10 +735,10 @@ module Google
725
735
  # @return [String]
726
736
  attr_accessor :project
727
737
 
728
- # The geographical region. Can be: * **us-central** (**FIRST_GEN** instances
729
- # only) * **us-central1** (**SECOND_GEN** instances only) * **asia-east1** or **
730
- # europe-west1**. Defaults to **us-central** or **us-central1** depending on the
731
- # instance type. The region cannot be changed after instance creation.
738
+ # The geographical region. Can be: * `us-central` (`FIRST_GEN` instances only) *
739
+ # `us-central1` (`SECOND_GEN` instances only) * `asia-east1` or `europe-west1`.
740
+ # Defaults to `us-central` or `us-central1` depending on the instance type. The
741
+ # region cannot be changed after instance creation.
732
742
  # Corresponds to the JSON property `region`
733
743
  # @return [String]
734
744
  attr_accessor :region
@@ -777,7 +787,7 @@ module Google
777
787
  # @return [Google::Apis::SqladminV1::SslCert]
778
788
  attr_accessor :server_ca_cert
779
789
 
780
- # The service account email address assigned to the instance. This property is
790
+ # The service account email address assigned to the instance.\This property is
781
791
  # read-only.
782
792
  # Corresponds to the JSON property `serviceAccountEmailAddress`
783
793
  # @return [String]
@@ -788,13 +798,7 @@ module Google
788
798
  # @return [Google::Apis::SqladminV1::Settings]
789
799
  attr_accessor :settings
790
800
 
791
- # The current serving state of the Cloud SQL instance. This can be one of the
792
- # following: * **SQL_INSTANCE_STATE_UNSPECIFIED**: The state of the instance is
793
- # unknown. * **RUNNABLE**: The instance is running, or has been stopped by owner.
794
- # * **SUSPENDED**: The instance is not available, for example due to problems
795
- # with billing. * **PENDING_DELETE**: The instance is being deleted. * **
796
- # PENDING_CREATE**: The instance is being created. * **MAINTENANCE**: The
797
- # instance is down for maintenance. * **FAILED**: The instance creation failed.
801
+ # The current serving state of the Cloud SQL instance.
798
802
  # Corresponds to the JSON property `state`
799
803
  # @return [String]
800
804
  attr_accessor :state
@@ -814,6 +818,7 @@ module Google
814
818
  @connection_name = args[:connection_name] if args.key?(:connection_name)
815
819
  @create_time = args[:create_time] if args.key?(:create_time)
816
820
  @current_disk_size = args[:current_disk_size] if args.key?(:current_disk_size)
821
+ @database_installed_version = args[:database_installed_version] if args.key?(:database_installed_version)
817
822
  @database_version = args[:database_version] if args.key?(:database_version)
818
823
  @disk_encryption_configuration = args[:disk_encryption_configuration] if args.key?(:disk_encryption_configuration)
819
824
  @disk_encryption_status = args[:disk_encryption_status] if args.key?(:disk_encryption_status)
@@ -885,7 +890,7 @@ module Google
885
890
  # @return [Array<Google::Apis::SqladminV1::Database>]
886
891
  attr_accessor :items
887
892
 
888
- # This is always **sql#databasesList**.
893
+ # This is always `sql#databasesList`.
889
894
  # Corresponds to the JSON property `kind`
890
895
  # @return [String]
891
896
  attr_accessor :kind
@@ -905,7 +910,7 @@ module Google
905
910
  class DemoteMasterConfiguration
906
911
  include Google::Apis::Core::Hashable
907
912
 
908
- # This is always **sql#demoteMasterConfiguration**.
913
+ # This is always `sql#demoteMasterConfiguration`.
909
914
  # Corresponds to the JSON property `kind`
910
915
  # @return [String]
911
916
  attr_accessor :kind
@@ -930,7 +935,7 @@ module Google
930
935
  class DemoteMasterContext
931
936
  include Google::Apis::Core::Hashable
932
937
 
933
- # This is always **sql#demoteMasterContext**.
938
+ # This is always `sql#demoteMasterContext`.
934
939
  # Corresponds to the JSON property `kind`
935
940
  # @return [String]
936
941
  attr_accessor :kind
@@ -952,12 +957,12 @@ module Google
952
957
  attr_accessor :skip_replication_setup
953
958
  alias_method :skip_replication_setup?, :skip_replication_setup
954
959
 
955
- # Verify GTID consistency for demote operation. Default value: **True**. Setting
956
- # this flag to false enables you to bypass GTID consistency check between on-
957
- # premises primary instance and Cloud SQL instance during the demotion operation
958
- # but also exposes you to the risk of future replication failures. Change the
959
- # value only if you know the reason for the GTID divergence and are confident
960
- # that doing so will not cause any replication issues.
960
+ # Verify the GTID consistency for demote operation. Default value: `True`.
961
+ # Setting this flag to `false` enables you to bypass the GTID consistency check
962
+ # between on-premises primary instance and Cloud SQL instance during the
963
+ # demotion operation but also exposes you to the risk of future replication
964
+ # failures. Change the value only if you know the reason for the GTID divergence
965
+ # and are confident that doing so will not cause any replication issues.
961
966
  # Corresponds to the JSON property `verifyGtidConsistency`
962
967
  # @return [Boolean]
963
968
  attr_accessor :verify_gtid_consistency
@@ -998,7 +1003,7 @@ module Google
998
1003
  # @return [String]
999
1004
  attr_accessor :client_key
1000
1005
 
1001
- # This is always **sql#demoteMasterMysqlReplicaConfiguration**.
1006
+ # This is always `sql#demoteMasterMysqlReplicaConfiguration`.
1002
1007
  # Corresponds to the JSON property `kind`
1003
1008
  # @return [String]
1004
1009
  attr_accessor :kind
@@ -1071,7 +1076,7 @@ module Google
1071
1076
  class DiskEncryptionConfiguration
1072
1077
  include Google::Apis::Core::Hashable
1073
1078
 
1074
- # This is always **sql#diskEncryptionConfiguration**.
1079
+ # This is always `sql#diskEncryptionConfiguration`.
1075
1080
  # Corresponds to the JSON property `kind`
1076
1081
  # @return [String]
1077
1082
  attr_accessor :kind
@@ -1096,7 +1101,7 @@ module Google
1096
1101
  class DiskEncryptionStatus
1097
1102
  include Google::Apis::Core::Hashable
1098
1103
 
1099
- # This is always **sql#diskEncryptionStatus**.
1104
+ # This is always `sql#diskEncryptionStatus`.
1100
1105
  # Corresponds to the JSON property `kind`
1101
1106
  # @return [String]
1102
1107
  attr_accessor :kind
@@ -1121,32 +1126,30 @@ module Google
1121
1126
  class ExportContext
1122
1127
  include Google::Apis::Core::Hashable
1123
1128
 
1124
- # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
1129
+ # Options for exporting data as CSV. `MySQL` and `PostgreSQL` instances only.
1125
1130
  # Corresponds to the JSON property `csvExportOptions`
1126
1131
  # @return [Google::Apis::SqladminV1::ExportContext::CsvExportOptions]
1127
1132
  attr_accessor :csv_export_options
1128
1133
 
1129
- # Databases to be exported. * **MySQL instances:** If **fileType** is **SQL**
1130
- # and no database is specified, all databases are exported, except for the **
1131
- # mysql** system database. If **fileType** is **CSV**, you can specify one
1132
- # database, either by using this property or by using the **csvExportOptions.
1133
- # selectQuery** property, which takes precedence over this property. * **
1134
- # PostgreSQL instances:** You must specify one database to be exported. If **
1135
- # fileType** is **CSV**, this database must match the one specified in the **
1136
- # csvExportOptions.selectQuery** property. * **SQL Server instances:** You must
1137
- # specify one database to be exported, and the **fileType** must be **BAK**.
1134
+ # Databases to be exported. `MySQL instances:` If `fileType` is `SQL` and no
1135
+ # database is specified, all databases are exported, except for the `mysql`
1136
+ # system database. If `fileType` is `CSV`, you can specify one database, either
1137
+ # by using this property or by using the `csvExportOptions.selectQuery` property,
1138
+ # which takes precedence over this property. `PostgreSQL instances:` You must
1139
+ # specify one database to be exported. If `fileType` is `CSV`, this database
1140
+ # must match the one specified in the `csvExportOptions.selectQuery` property. `
1141
+ # SQL Server instances:` You must specify one database to be exported, and the `
1142
+ # fileType` must be `BAK`.
1138
1143
  # Corresponds to the JSON property `databases`
1139
1144
  # @return [Array<String>]
1140
1145
  attr_accessor :databases
1141
1146
 
1142
- # The file type for the specified uri. * **SQL**: The file contains SQL
1143
- # statements. * **CSV**: The file contains CSV data. * **BAK**: The file
1144
- # contains backup data for a SQL Server instance.
1147
+ # The file type for the specified uri.
1145
1148
  # Corresponds to the JSON property `fileType`
1146
1149
  # @return [String]
1147
1150
  attr_accessor :file_type
1148
1151
 
1149
- # This is always **sql#exportContext**.
1152
+ # This is always `sql#exportContext`.
1150
1153
  # Corresponds to the JSON property `kind`
1151
1154
  # @return [String]
1152
1155
  attr_accessor :kind
@@ -1163,9 +1166,9 @@ module Google
1163
1166
  attr_accessor :sql_export_options
1164
1167
 
1165
1168
  # The path to the file in Google Cloud Storage where the export will be stored.
1166
- # The URI is in the form **gs://bucketName/fileName**. If the file already
1167
- # exists, the request succeeds, but the operation fails. If **fileType** is **
1168
- # SQL** and the filename ends with .gz, the contents are compressed.
1169
+ # The URI is in the form `gs://bucketName/fileName`. If the file already exists,
1170
+ # the request succeeds, but the operation fails. If `fileType` is `SQL` and the
1171
+ # filename ends with .gz, the contents are compressed.
1169
1172
  # Corresponds to the JSON property `uri`
1170
1173
  # @return [String]
1171
1174
  attr_accessor :uri
@@ -1185,7 +1188,7 @@ module Google
1185
1188
  @uri = args[:uri] if args.key?(:uri)
1186
1189
  end
1187
1190
 
1188
- # Options for exporting data as CSV. **MySQL** and **PostgreSQL** instances only.
1191
+ # Options for exporting data as CSV. `MySQL` and `PostgreSQL` instances only.
1189
1192
  class CsvExportOptions
1190
1193
  include Google::Apis::Core::Hashable
1191
1194
 
@@ -1268,11 +1271,11 @@ module Google
1268
1271
  class MysqlExportOptions
1269
1272
  include Google::Apis::Core::Hashable
1270
1273
 
1271
- # Option to include SQL statement required to set up replication. * If set to **
1272
- # 1**, the dump file includes a CHANGE MASTER TO statement with the binary log
1273
- # coordinates, and --set-gtid-purged is set to ON. * If set to **2**, the CHANGE
1274
- # MASTER TO statement is written as a SQL comment and has no effect. * If set to
1275
- # any value other than **1**, --set-gtid-purged is set to OFF.
1274
+ # Option to include SQL statement required to set up replication. If set to `1`,
1275
+ # the dump file includes a CHANGE MASTER TO statement with the binary log
1276
+ # coordinates, and --set-gtid-purged is set to ON. If set to `2`, the CHANGE
1277
+ # MASTER TO statement is written as a SQL comment and has no effect. If set to
1278
+ # any value other than `1`, --set-gtid-purged is set to OFF.
1276
1279
  # Corresponds to the JSON property `masterData`
1277
1280
  # @return [Fixnum]
1278
1281
  attr_accessor :master_data
@@ -1293,7 +1296,7 @@ module Google
1293
1296
  class FailoverContext
1294
1297
  include Google::Apis::Core::Hashable
1295
1298
 
1296
- # This is always **sql#failoverContext**.
1299
+ # This is always `sql#failoverContext`.
1297
1300
  # Corresponds to the JSON property `kind`
1298
1301
  # @return [String]
1299
1302
  attr_accessor :kind
@@ -1325,13 +1328,18 @@ module Google
1325
1328
  # @return [Array<Fixnum>]
1326
1329
  attr_accessor :allowed_int_values
1327
1330
 
1328
- # For **STRING** flags, a list of strings that the value can be set to.
1331
+ # For `STRING` flags, a list of strings that the value can be set to.
1329
1332
  # Corresponds to the JSON property `allowedStringValues`
1330
1333
  # @return [Array<String>]
1331
1334
  attr_accessor :allowed_string_values
1332
1335
 
1333
- # The database version this flag applies to. Can be **MYSQL_8_0**, **MYSQL_5_6**,
1334
- # or **MYSQL_5_7**.
1336
+ # The database version this flag applies to. Can be MySQL instances: `MYSQL_8_0`,
1337
+ # `MYSQL_8_0_18`, `MYSQL_8_0_26`, `MYSQL_5_7`, or `MYSQL_5_6`. PostgreSQL
1338
+ # instances: `POSTGRES_9_6`, `POSTGRES_10`, `POSTGRES_11` or `POSTGRES_12`. SQL
1339
+ # Server instances: `SQLSERVER_2017_STANDARD`, `SQLSERVER_2017_ENTERPRISE`, `
1340
+ # SQLSERVER_2017_EXPRESS`, `SQLSERVER_2017_WEB`, `SQLSERVER_2019_STANDARD`, `
1341
+ # SQLSERVER_2019_ENTERPRISE`, `SQLSERVER_2019_EXPRESS`, or `SQLSERVER_2019_WEB`.
1342
+ # See [the complete list](/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion).
1335
1343
  # Corresponds to the JSON property `appliesTo`
1336
1344
  # @return [Array<String>]
1337
1345
  attr_accessor :applies_to
@@ -1342,23 +1350,23 @@ module Google
1342
1350
  attr_accessor :in_beta
1343
1351
  alias_method :in_beta?, :in_beta
1344
1352
 
1345
- # This is always **sql#flag**.
1353
+ # This is always `sql#flag`.
1346
1354
  # Corresponds to the JSON property `kind`
1347
1355
  # @return [String]
1348
1356
  attr_accessor :kind
1349
1357
 
1350
- # For **INTEGER** flags, the maximum allowed value.
1358
+ # For `INTEGER` flags, the maximum allowed value.
1351
1359
  # Corresponds to the JSON property `maxValue`
1352
1360
  # @return [Fixnum]
1353
1361
  attr_accessor :max_value
1354
1362
 
1355
- # For **INTEGER** flags, the minimum allowed value.
1363
+ # For `INTEGER` flags, the minimum allowed value.
1356
1364
  # Corresponds to the JSON property `minValue`
1357
1365
  # @return [Fixnum]
1358
1366
  attr_accessor :min_value
1359
1367
 
1360
1368
  # This is the name of the flag. Flag names always use underscores, not hyphens,
1361
- # for example: **max_allowed_packet**
1369
+ # for example: `max_allowed_packet`
1362
1370
  # Corresponds to the JSON property `name`
1363
1371
  # @return [String]
1364
1372
  attr_accessor :name
@@ -1370,9 +1378,9 @@ module Google
1370
1378
  attr_accessor :requires_restart
1371
1379
  alias_method :requires_restart?, :requires_restart
1372
1380
 
1373
- # The type of the flag. Flags are typed to being **BOOLEAN**, **STRING**, **
1374
- # INTEGER** or **NONE**. **NONE** is used for flags which do not take a value,
1375
- # such as **skip_grant_tables**.
1381
+ # The type of the flag. Flags are typed to being `BOOLEAN`, `STRING`, `INTEGER`
1382
+ # or `NONE`. `NONE` is used for flags that do not take a value, such as `
1383
+ # skip_grant_tables`.
1376
1384
  # Corresponds to the JSON property `type`
1377
1385
  # @return [String]
1378
1386
  attr_accessor :type
@@ -1405,7 +1413,7 @@ module Google
1405
1413
  # @return [Array<Google::Apis::SqladminV1::Flag>]
1406
1414
  attr_accessor :items
1407
1415
 
1408
- # This is always **sql#flagsList**.
1416
+ # This is always `sql#flagsList`.
1409
1417
  # Corresponds to the JSON property `kind`
1410
1418
  # @return [String]
1411
1419
  attr_accessor :kind
@@ -1491,16 +1499,16 @@ module Google
1491
1499
  # @return [Google::Apis::SqladminV1::ImportContext::CsvImportOptions]
1492
1500
  attr_accessor :csv_import_options
1493
1501
 
1494
- # The target database for the import. If **fileType** is **SQL**, this field is
1502
+ # The target database for the import. If `fileType` is `SQL`, this field is
1495
1503
  # required only if the import file does not specify a database, and is
1496
- # overridden by any database specification in the import file. If **fileType**
1497
- # is **CSV**, one database must be specified.
1504
+ # overridden by any database specification in the import file. If `fileType` is `
1505
+ # CSV`, one database must be specified.
1498
1506
  # Corresponds to the JSON property `database`
1499
1507
  # @return [String]
1500
1508
  attr_accessor :database
1501
1509
 
1502
- # The file type for the specified uri. **SQL**: The file contains SQL statements.
1503
- # **CSV**: The file contains CSV data.
1510
+ # The file type for the specified uri.\`SQL`: The file contains SQL statements. \
1511
+ # `CSV`: The file contains CSV data.
1504
1512
  # Corresponds to the JSON property `fileType`
1505
1513
  # @return [String]
1506
1514
  attr_accessor :file_type
@@ -1510,15 +1518,15 @@ module Google
1510
1518
  # @return [String]
1511
1519
  attr_accessor :import_user
1512
1520
 
1513
- # This is always **sql#importContext**.
1521
+ # This is always `sql#importContext`.
1514
1522
  # Corresponds to the JSON property `kind`
1515
1523
  # @return [String]
1516
1524
  attr_accessor :kind
1517
1525
 
1518
- # Path to the import file in Cloud Storage, in the form **gs://bucketName/
1519
- # fileName**. Compressed gzip files (.gz) are supported when **fileType** is **
1520
- # SQL**. The instance must have write permissions to the bucket and read access
1521
- # to the file.
1526
+ # Path to the import file in Cloud Storage, in the form `gs://bucketName/
1527
+ # fileName`. Compressed gzip files (.gz) are supported when `fileType` is `SQL`.
1528
+ # The instance must have write permissions to the bucket and read access to the
1529
+ # file.
1522
1530
  # Corresponds to the JSON property `uri`
1523
1531
  # @return [String]
1524
1532
  attr_accessor :uri
@@ -1560,8 +1568,8 @@ module Google
1560
1568
  class EncryptionOptions
1561
1569
  include Google::Apis::Core::Hashable
1562
1570
 
1563
- # Path to the Certificate (.cer) in Cloud Storage, in the form **gs://bucketName/
1564
- # fileName**. The instance must have write permissions to the bucket and read
1571
+ # Path to the Certificate (.cer) in Cloud Storage, in the form `gs://bucketName/
1572
+ # fileName`. The instance must have write permissions to the bucket and read
1565
1573
  # access to the file.
1566
1574
  # Corresponds to the JSON property `certPath`
1567
1575
  # @return [String]
@@ -1572,8 +1580,8 @@ module Google
1572
1580
  # @return [String]
1573
1581
  attr_accessor :pvk_password
1574
1582
 
1575
- # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form **gs:/
1576
- # /bucketName/fileName**. The instance must have write permissions to the bucket
1583
+ # Path to the Certificate Private Key (.pvk) in Cloud Storage, in the form `gs://
1584
+ # bucketName/fileName`. The instance must have write permissions to the bucket
1577
1585
  # and read access to the file.
1578
1586
  # Corresponds to the JSON property `pvkPath`
1579
1587
  # @return [String]
@@ -1834,7 +1842,7 @@ module Google
1834
1842
  # @return [Array<Google::Apis::SqladminV1::DatabaseInstance>]
1835
1843
  attr_accessor :items
1836
1844
 
1837
- # This is always **sql#instancesList**.
1845
+ # This is always `sql#instancesList`.
1838
1846
  # Corresponds to the JSON property `kind`
1839
1847
  # @return [String]
1840
1848
  attr_accessor :kind
@@ -1877,7 +1885,7 @@ module Google
1877
1885
  # @return [Array<Google::Apis::SqladminV1::SslCert>]
1878
1886
  attr_accessor :certs
1879
1887
 
1880
- # This is always **sql#instancesListServerCas**.
1888
+ # This is always `sql#instancesListServerCas`.
1881
1889
  # Corresponds to the JSON property `kind`
1882
1890
  # @return [String]
1883
1891
  attr_accessor :kind
@@ -1961,14 +1969,13 @@ module Google
1961
1969
  # created in the allocated range. The range name must comply with [RFC 1035](
1962
1970
  # https://tools.ietf.org/html/rfc1035). Specifically, the name must be 1-63
1963
1971
  # characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?.`
1964
- # Reserved for future use.
1965
1972
  # Corresponds to the JSON property `allocatedIpRange`
1966
1973
  # @return [String]
1967
1974
  attr_accessor :allocated_ip_range
1968
1975
 
1969
1976
  # The list of external networks that are allowed to connect to the instance
1970
1977
  # using the IP. In 'CIDR' notation, also known as 'slash' notation (for example:
1971
- # **192.168.100.0/24**).
1978
+ # `157.197.200.0/24`).
1972
1979
  # Corresponds to the JSON property `authorizedNetworks`
1973
1980
  # @return [Array<Google::Apis::SqladminV1::AclEntry>]
1974
1981
  attr_accessor :authorized_networks
@@ -1980,8 +1987,8 @@ module Google
1980
1987
  alias_method :ipv4_enabled?, :ipv4_enabled
1981
1988
 
1982
1989
  # The resource link for the VPC network from which the Cloud SQL instance is
1983
- # accessible for private IP. For example, **/projects/myProject/global/networks/
1984
- # default**. This setting can be updated, but it cannot be removed after it is
1990
+ # accessible for private IP. For example, `/projects/myProject/global/networks/
1991
+ # default`. This setting can be updated, but it cannot be removed after it is
1985
1992
  # set.
1986
1993
  # Corresponds to the JSON property `privateNetwork`
1987
1994
  # @return [String]
@@ -2017,16 +2024,16 @@ module Google
2017
2024
  attr_accessor :ip_address
2018
2025
 
2019
2026
  # The due time for this IP to be retired in [RFC 3339](https://tools.ietf.org/
2020
- # html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**. This field is
2027
+ # html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`. This field is
2021
2028
  # only available when the IP is scheduled to be retired.
2022
2029
  # Corresponds to the JSON property `timeToRetire`
2023
2030
  # @return [String]
2024
2031
  attr_accessor :time_to_retire
2025
2032
 
2026
- # The type of this IP address. A **PRIMARY** address is a public address that
2027
- # can accept incoming connections. A **PRIVATE** address is a private address
2028
- # that can accept incoming connections. An **OUTGOING** address is the source
2029
- # address of connections originating from the instance, if supported.
2033
+ # The type of this IP address. A `PRIMARY` address is a public address that can
2034
+ # accept incoming connections. A `PRIVATE` address is a private address that can
2035
+ # accept incoming connections. An `OUTGOING` address is the source address of
2036
+ # connections originating from the instance, if supported.
2030
2037
  # Corresponds to the JSON property `type`
2031
2038
  # @return [String]
2032
2039
  attr_accessor :type
@@ -2050,12 +2057,12 @@ module Google
2050
2057
  include Google::Apis::Core::Hashable
2051
2058
 
2052
2059
  # The App Engine application to follow, it must be in the same region as the
2053
- # Cloud SQL instance.
2060
+ # Cloud SQL instance. WARNING: Changing this might restart the instance.
2054
2061
  # Corresponds to the JSON property `followGaeApplication`
2055
2062
  # @return [String]
2056
2063
  attr_accessor :follow_gae_application
2057
2064
 
2058
- # This is always **sql#locationPreference**.
2065
+ # This is always `sql#locationPreference`.
2059
2066
  # Corresponds to the JSON property `kind`
2060
2067
  # @return [String]
2061
2068
  attr_accessor :kind
@@ -2067,7 +2074,7 @@ module Google
2067
2074
  attr_accessor :secondary_zone
2068
2075
 
2069
2076
  # The preferred Compute Engine zone (for example: us-central1-a, us-central1-b,
2070
- # etc.).
2077
+ # etc.). WARNING: Changing this might restart the instance.
2071
2078
  # Corresponds to the JSON property `zone`
2072
2079
  # @return [String]
2073
2080
  attr_accessor :zone
@@ -2100,12 +2107,12 @@ module Google
2100
2107
  # @return [Fixnum]
2101
2108
  attr_accessor :hour
2102
2109
 
2103
- # This is always **sql#maintenanceWindow**.
2110
+ # This is always `sql#maintenanceWindow`.
2104
2111
  # Corresponds to the JSON property `kind`
2105
2112
  # @return [String]
2106
2113
  attr_accessor :kind
2107
2114
 
2108
- # Maintenance timing setting: **canary** (Earlier) or **stable** (Later). [Learn
2115
+ # Maintenance timing setting: `canary` (Earlier) or `stable` (Later). [Learn
2109
2116
  # more](https://cloud.google.com/sql/docs/mysql/instance-settings#maintenance-
2110
2117
  # timing-2ndgen).
2111
2118
  # Corresponds to the JSON property `updateTrack`
@@ -2159,7 +2166,7 @@ module Google
2159
2166
  # @return [String]
2160
2167
  attr_accessor :dump_file_path
2161
2168
 
2162
- # This is always **sql#mysqlReplicaConfiguration**.
2169
+ # This is always `sql#mysqlReplicaConfiguration`.
2163
2170
  # Corresponds to the JSON property `kind`
2164
2171
  # @return [String]
2165
2172
  attr_accessor :kind
@@ -2260,7 +2267,7 @@ module Google
2260
2267
  # @return [String]
2261
2268
  attr_accessor :host_port
2262
2269
 
2263
- # This is always **sql#onPremisesConfiguration**.
2270
+ # This is always `sql#onPremisesConfiguration`.
2264
2271
  # Corresponds to the JSON property `kind`
2265
2272
  # @return [String]
2266
2273
  attr_accessor :kind
@@ -2310,7 +2317,7 @@ module Google
2310
2317
  attr_accessor :backup_context
2311
2318
 
2312
2319
  # The time this operation finished in UTC timezone in [RFC 3339](https://tools.
2313
- # ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2320
+ # ietf.org/html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
2314
2321
  # Corresponds to the JSON property `endTime`
2315
2322
  # @return [String]
2316
2323
  attr_accessor :end_time
@@ -2331,12 +2338,12 @@ module Google
2331
2338
  attr_accessor :import_context
2332
2339
 
2333
2340
  # The time this operation was enqueued in UTC timezone in [RFC 3339](https://
2334
- # tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2341
+ # tools.ietf.org/html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
2335
2342
  # Corresponds to the JSON property `insertTime`
2336
2343
  # @return [String]
2337
2344
  attr_accessor :insert_time
2338
2345
 
2339
- # This is always **sql#operation**.
2346
+ # This is always `sql#operation`.
2340
2347
  # Corresponds to the JSON property `kind`
2341
2348
  # @return [String]
2342
2349
  attr_accessor :kind
@@ -2348,10 +2355,9 @@ module Google
2348
2355
  # @return [String]
2349
2356
  attr_accessor :name
2350
2357
 
2351
- # The type of the operation. Valid values are: * **CREATE** * **DELETE** * **
2352
- # UPDATE** * **RESTART** * **IMPORT** * **EXPORT** * **BACKUP_VOLUME** * **
2353
- # RESTORE_VOLUME** * **CREATE_USER** * **DELETE_USER** * **CREATE_DATABASE** * **
2354
- # DELETE_DATABASE**
2358
+ # The type of the operation. Valid values are: * `CREATE` * `DELETE` * `UPDATE` *
2359
+ # `RESTART` * `IMPORT` * `EXPORT` * `BACKUP_VOLUME` * `RESTORE_VOLUME` * `
2360
+ # CREATE_USER` * `DELETE_USER` * `CREATE_DATABASE` * `DELETE_DATABASE`
2355
2361
  # Corresponds to the JSON property `operationType`
2356
2362
  # @return [String]
2357
2363
  attr_accessor :operation_type
@@ -2362,13 +2368,12 @@ module Google
2362
2368
  attr_accessor :self_link
2363
2369
 
2364
2370
  # The time this operation actually started in UTC timezone in [RFC 3339](https://
2365
- # tools.ietf.org/html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2371
+ # tools.ietf.org/html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
2366
2372
  # Corresponds to the JSON property `startTime`
2367
2373
  # @return [String]
2368
2374
  attr_accessor :start_time
2369
2375
 
2370
- # The status of an operation. Valid values are: * **PENDING** * **RUNNING** * **
2371
- # DONE** * **SQL_OPERATION_STATUS_UNSPECIFIED**
2376
+ # The status of an operation.
2372
2377
  # Corresponds to the JSON property `status`
2373
2378
  # @return [String]
2374
2379
  attr_accessor :status
@@ -2427,7 +2432,7 @@ module Google
2427
2432
  # @return [String]
2428
2433
  attr_accessor :code
2429
2434
 
2430
- # This is always **sql#operationError**.
2435
+ # This is always `sql#operationError`.
2431
2436
  # Corresponds to the JSON property `kind`
2432
2437
  # @return [String]
2433
2438
  attr_accessor :kind
@@ -2458,7 +2463,7 @@ module Google
2458
2463
  # @return [Array<Google::Apis::SqladminV1::OperationError>]
2459
2464
  attr_accessor :errors
2460
2465
 
2461
- # This is always **sql#operationErrors**.
2466
+ # This is always `sql#operationErrors`.
2462
2467
  # Corresponds to the JSON property `kind`
2463
2468
  # @return [String]
2464
2469
  attr_accessor :kind
@@ -2483,7 +2488,7 @@ module Google
2483
2488
  # @return [Array<Google::Apis::SqladminV1::Operation>]
2484
2489
  attr_accessor :items
2485
2490
 
2486
- # This is always **sql#operationsList**.
2491
+ # This is always `sql#operationsList`.
2487
2492
  # Corresponds to the JSON property `kind`
2488
2493
  # @return [String]
2489
2494
  attr_accessor :kind
@@ -2506,12 +2511,83 @@ module Google
2506
2511
  end
2507
2512
  end
2508
2513
 
2514
+ # Read-only password status.
2515
+ class PasswordStatus
2516
+ include Google::Apis::Core::Hashable
2517
+
2518
+ # If true, user does not have login privileges.
2519
+ # Corresponds to the JSON property `locked`
2520
+ # @return [Boolean]
2521
+ attr_accessor :locked
2522
+ alias_method :locked?, :locked
2523
+
2524
+ # The expiration time of the current password.
2525
+ # Corresponds to the JSON property `passwordExpirationTime`
2526
+ # @return [String]
2527
+ attr_accessor :password_expiration_time
2528
+
2529
+ def initialize(**args)
2530
+ update!(**args)
2531
+ end
2532
+
2533
+ # Update properties of this object
2534
+ def update!(**args)
2535
+ @locked = args[:locked] if args.key?(:locked)
2536
+ @password_expiration_time = args[:password_expiration_time] if args.key?(:password_expiration_time)
2537
+ end
2538
+ end
2539
+
2540
+ # Database instance local user password validation policy
2541
+ class PasswordValidationPolicy
2542
+ include Google::Apis::Core::Hashable
2543
+
2544
+ # The complexity of the password.
2545
+ # Corresponds to the JSON property `complexity`
2546
+ # @return [String]
2547
+ attr_accessor :complexity
2548
+
2549
+ # Disallow username as a part of the password.
2550
+ # Corresponds to the JSON property `disallowUsernameSubstring`
2551
+ # @return [Boolean]
2552
+ attr_accessor :disallow_username_substring
2553
+ alias_method :disallow_username_substring?, :disallow_username_substring
2554
+
2555
+ # Minimum number of characters allowed.
2556
+ # Corresponds to the JSON property `minLength`
2557
+ # @return [Fixnum]
2558
+ attr_accessor :min_length
2559
+
2560
+ # Minimum interval after which the password can be changed. This flag is only
2561
+ # supported for PostgresSQL.
2562
+ # Corresponds to the JSON property `passwordChangeInterval`
2563
+ # @return [String]
2564
+ attr_accessor :password_change_interval
2565
+
2566
+ # Number of previous passwords that cannot be reused.
2567
+ # Corresponds to the JSON property `reuseInterval`
2568
+ # @return [Fixnum]
2569
+ attr_accessor :reuse_interval
2570
+
2571
+ def initialize(**args)
2572
+ update!(**args)
2573
+ end
2574
+
2575
+ # Update properties of this object
2576
+ def update!(**args)
2577
+ @complexity = args[:complexity] if args.key?(:complexity)
2578
+ @disallow_username_substring = args[:disallow_username_substring] if args.key?(:disallow_username_substring)
2579
+ @min_length = args[:min_length] if args.key?(:min_length)
2580
+ @password_change_interval = args[:password_change_interval] if args.key?(:password_change_interval)
2581
+ @reuse_interval = args[:reuse_interval] if args.key?(:reuse_interval)
2582
+ end
2583
+ end
2584
+
2509
2585
  # Read-replica configuration for connecting to the primary instance.
2510
2586
  class ReplicaConfiguration
2511
2587
  include Google::Apis::Core::Hashable
2512
2588
 
2513
- # Specifies if the replica is the failover target. If the field is set to **true*
2514
- # * the replica will be designated as a failover replica. In case the primary
2589
+ # Specifies if the replica is the failover target. If the field is set to `true`,
2590
+ # the replica will be designated as a failover replica. In case the primary
2515
2591
  # instance fails, the replica instance will be promoted as the new primary
2516
2592
  # instance. Only one replica can be specified as failover target, and the
2517
2593
  # replica has to be in different zone with the primary instance.
@@ -2520,7 +2596,7 @@ module Google
2520
2596
  attr_accessor :failover_target
2521
2597
  alias_method :failover_target?, :failover_target
2522
2598
 
2523
- # This is always **sql#replicaConfiguration**.
2599
+ # This is always `sql#replicaConfiguration`.
2524
2600
  # Corresponds to the JSON property `kind`
2525
2601
  # @return [String]
2526
2602
  attr_accessor :kind
@@ -2553,7 +2629,7 @@ module Google
2553
2629
 
2554
2630
  # Optional. Timestamp when the maintenance shall be rescheduled to if
2555
2631
  # reschedule_type=SPECIFIC_TIME, in [RFC 3339](https://tools.ietf.org/html/
2556
- # rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
2632
+ # rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
2557
2633
  # Corresponds to the JSON property `scheduleTime`
2558
2634
  # @return [String]
2559
2635
  attr_accessor :schedule_time
@@ -2584,7 +2660,7 @@ module Google
2584
2660
  # @return [String]
2585
2661
  attr_accessor :instance_id
2586
2662
 
2587
- # This is always **sql#restoreBackupContext**.
2663
+ # This is always `sql#restoreBackupContext`.
2588
2664
  # Corresponds to the JSON property `kind`
2589
2665
  # @return [String]
2590
2666
  attr_accessor :kind
@@ -2611,7 +2687,7 @@ module Google
2611
2687
  class RotateServerCaContext
2612
2688
  include Google::Apis::Core::Hashable
2613
2689
 
2614
- # This is always **sql#rotateServerCaContext**.
2690
+ # This is always `sql#rotateServerCaContext`.
2615
2691
  # Corresponds to the JSON property `kind`
2616
2692
  # @return [String]
2617
2693
  attr_accessor :kind
@@ -2638,10 +2714,10 @@ module Google
2638
2714
  include Google::Apis::Core::Hashable
2639
2715
 
2640
2716
  # The activation policy specifies when the instance is activated; it is
2641
- # applicable only when the instance state is RUNNABLE. Valid values: * **ALWAYS**
2642
- # : The instance is on, and remains so even in the absence of connection
2643
- # requests. * **NEVER**: The instance is off; it is not activated, even if a
2644
- # connection request arrives.
2717
+ # applicable only when the instance state is RUNNABLE. Valid values: * `ALWAYS`:
2718
+ # The instance is on, and remains so even in the absence of connection requests.
2719
+ # * `NEVER`: The instance is off; it is not activated, even if a connection
2720
+ # request arrives.
2645
2721
  # Corresponds to the JSON property `activationPolicy`
2646
2722
  # @return [String]
2647
2723
  attr_accessor :activation_policy
@@ -2657,12 +2733,11 @@ module Google
2657
2733
  # @return [Array<String>]
2658
2734
  attr_accessor :authorized_gae_applications
2659
2735
 
2660
- # Availability type. Potential values: * **ZONAL**: The instance serves data
2661
- # from only one zone. Outages in that zone affect data accessibility. * **
2662
- # REGIONAL**: The instance can serve data from more than one zone in a region (
2663
- # it is highly available)./ For more information, see [Overview of the High
2664
- # Availability Configuration](https://cloud.google.com/sql/docs/mysql/high-
2665
- # availability).
2736
+ # Availability type. Potential values: * `ZONAL`: The instance serves data from
2737
+ # only one zone. Outages in that zone affect data accessibility. * `REGIONAL`:
2738
+ # The instance can serve data from more than one zone in a region (it is highly
2739
+ # available)./ For more information, see [Overview of the High Availability
2740
+ # Configuration](https://cloud.google.com/sql/docs/mysql/high-availability).
2666
2741
  # Corresponds to the JSON property `availabilityType`
2667
2742
  # @return [String]
2668
2743
  attr_accessor :availability_type
@@ -2690,7 +2765,7 @@ module Google
2690
2765
  # @return [Fixnum]
2691
2766
  attr_accessor :data_disk_size_gb
2692
2767
 
2693
- # The type of data disk: **PD_SSD** (default) or **PD_HDD**. Not used for First
2768
+ # The type of data disk: `PD_SSD` (default) or `PD_HDD`. Not used for First
2694
2769
  # Generation instances.
2695
2770
  # Corresponds to the JSON property `dataDiskType`
2696
2771
  # @return [String]
@@ -2702,7 +2777,7 @@ module Google
2702
2777
  attr_accessor :database_flags
2703
2778
 
2704
2779
  # Configuration specific to read replica instances. Indicates whether
2705
- # replication is enabled or not.
2780
+ # replication is enabled or not. WARNING: Changing this restarts the instance.
2706
2781
  # Corresponds to the JSON property `databaseReplicationEnabled`
2707
2782
  # @return [Boolean]
2708
2783
  attr_accessor :database_replication_enabled
@@ -2724,7 +2799,7 @@ module Google
2724
2799
  # @return [Google::Apis::SqladminV1::IpConfiguration]
2725
2800
  attr_accessor :ip_configuration
2726
2801
 
2727
- # This is always **sql#settings**.
2802
+ # This is always `sql#settings`.
2728
2803
  # Corresponds to the JSON property `kind`
2729
2804
  # @return [String]
2730
2805
  attr_accessor :kind
@@ -2742,14 +2817,19 @@ module Google
2742
2817
  # @return [Google::Apis::SqladminV1::MaintenanceWindow]
2743
2818
  attr_accessor :maintenance_window
2744
2819
 
2745
- # The pricing plan for this instance. This can be either **PER_USE** or **
2746
- # PACKAGE**. Only **PER_USE** is supported for Second Generation instances.
2820
+ # Database instance local user password validation policy
2821
+ # Corresponds to the JSON property `passwordValidationPolicy`
2822
+ # @return [Google::Apis::SqladminV1::PasswordValidationPolicy]
2823
+ attr_accessor :password_validation_policy
2824
+
2825
+ # The pricing plan for this instance. This can be either `PER_USE` or `PACKAGE`.
2826
+ # Only `PER_USE` is supported for Second Generation instances.
2747
2827
  # Corresponds to the JSON property `pricingPlan`
2748
2828
  # @return [String]
2749
2829
  attr_accessor :pricing_plan
2750
2830
 
2751
- # The type of replication this instance uses. This can be either **ASYNCHRONOUS**
2752
- # or **SYNCHRONOUS**. (Deprecated) This property was only applicable to First
2831
+ # The type of replication this instance uses. This can be either `ASYNCHRONOUS`
2832
+ # or `SYNCHRONOUS`. (Deprecated) This property was only applicable to First
2753
2833
  # Generation instances.
2754
2834
  # Corresponds to the JSON property `replicationType`
2755
2835
  # @return [String]
@@ -2781,7 +2861,8 @@ module Google
2781
2861
  # @return [Fixnum]
2782
2862
  attr_accessor :storage_auto_resize_limit
2783
2863
 
2784
- # The tier (or machine type) for this instance, for example **db-custom-1-3840**.
2864
+ # The tier (or machine type) for this instance, for example `db-custom-1-3840`.
2865
+ # WARNING: Changing this restarts the instance.
2785
2866
  # Corresponds to the JSON property `tier`
2786
2867
  # @return [String]
2787
2868
  attr_accessor :tier
@@ -2815,6 +2896,7 @@ module Google
2815
2896
  @kind = args[:kind] if args.key?(:kind)
2816
2897
  @location_preference = args[:location_preference] if args.key?(:location_preference)
2817
2898
  @maintenance_window = args[:maintenance_window] if args.key?(:maintenance_window)
2899
+ @password_validation_policy = args[:password_validation_policy] if args.key?(:password_validation_policy)
2818
2900
  @pricing_plan = args[:pricing_plan] if args.key?(:pricing_plan)
2819
2901
  @replication_type = args[:replication_type] if args.key?(:replication_type)
2820
2902
  @settings_version = args[:settings_version] if args.key?(:settings_version)
@@ -2860,7 +2942,7 @@ module Google
2860
2942
  # @return [String]
2861
2943
  attr_accessor :detail
2862
2944
 
2863
- # Can be **sql#externalSyncSettingError** or **sql#externalSyncSettingWarning**.
2945
+ # Can be `sql#externalSyncSettingError` or `sql#externalSyncSettingWarning`.
2864
2946
  # Corresponds to the JSON property `kind`
2865
2947
  # @return [String]
2866
2948
  attr_accessor :kind
@@ -2981,7 +3063,7 @@ module Google
2981
3063
  # @return [Array<Google::Apis::SqladminV1::SqlExternalSyncSettingError>]
2982
3064
  attr_accessor :errors
2983
3065
 
2984
- # This is always **sql#migrationSettingErrorList**.
3066
+ # This is always `sql#migrationSettingErrorList`.
2985
3067
  # Corresponds to the JSON property `kind`
2986
3068
  # @return [String]
2987
3069
  attr_accessor :kind
@@ -3167,13 +3249,13 @@ module Google
3167
3249
  attr_accessor :common_name
3168
3250
 
3169
3251
  # The time when the certificate was created in [RFC 3339](https://tools.ietf.org/
3170
- # html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**
3252
+ # html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`
3171
3253
  # Corresponds to the JSON property `createTime`
3172
3254
  # @return [String]
3173
3255
  attr_accessor :create_time
3174
3256
 
3175
3257
  # The time when the certificate expires in [RFC 3339](https://tools.ietf.org/
3176
- # html/rfc3339) format, for example **2012-11-15T16:19:00.094Z**.
3258
+ # html/rfc3339) format, for example `2012-11-15T16:19:00.094Z`.
3177
3259
  # Corresponds to the JSON property `expirationTime`
3178
3260
  # @return [String]
3179
3261
  attr_accessor :expiration_time
@@ -3183,7 +3265,7 @@ module Google
3183
3265
  # @return [String]
3184
3266
  attr_accessor :instance
3185
3267
 
3186
- # This is always **sql#sslCert**.
3268
+ # This is always `sql#sslCert`.
3187
3269
  # Corresponds to the JSON property `kind`
3188
3270
  # @return [String]
3189
3271
  attr_accessor :kind
@@ -3296,7 +3378,7 @@ module Google
3296
3378
  # @return [Google::Apis::SqladminV1::SslCertDetail]
3297
3379
  attr_accessor :client_cert
3298
3380
 
3299
- # This is always **sql#sslCertsInsert**.
3381
+ # This is always `sql#sslCertsInsert`.
3300
3382
  # Corresponds to the JSON property `kind`
3301
3383
  # @return [String]
3302
3384
  attr_accessor :kind
@@ -3335,7 +3417,7 @@ module Google
3335
3417
  # @return [Array<Google::Apis::SqladminV1::SslCert>]
3336
3418
  attr_accessor :items
3337
3419
 
3338
- # This is always **sql#sslCertsList**.
3420
+ # This is always `sql#sslCertsList`.
3339
3421
  # Corresponds to the JSON property `kind`
3340
3422
  # @return [String]
3341
3423
  attr_accessor :kind
@@ -3392,7 +3474,7 @@ module Google
3392
3474
  # @return [Fixnum]
3393
3475
  attr_accessor :ram
3394
3476
 
3395
- # This is always **sql#tier**.
3477
+ # This is always `sql#tier`.
3396
3478
  # Corresponds to the JSON property `kind`
3397
3479
  # @return [String]
3398
3480
  attr_accessor :kind
@@ -3402,8 +3484,8 @@ module Google
3402
3484
  # @return [Array<String>]
3403
3485
  attr_accessor :region
3404
3486
 
3405
- # An identifier for the machine type, for example, db-custom-1-3840. For related
3406
- # information, see [Pricing](/sql/pricing).
3487
+ # An identifier for the machine type, for example, `db-custom-1-3840`. For
3488
+ # related information, see [Pricing](/sql/pricing).
3407
3489
  # Corresponds to the JSON property `tier`
3408
3490
  # @return [String]
3409
3491
  attr_accessor :tier
@@ -3431,7 +3513,7 @@ module Google
3431
3513
  # @return [Array<Google::Apis::SqladminV1::Tier>]
3432
3514
  attr_accessor :items
3433
3515
 
3434
- # This is always **sql#tiersList**.
3516
+ # This is always `sql#tiersList`.
3435
3517
  # Corresponds to the JSON property `kind`
3436
3518
  # @return [String]
3437
3519
  attr_accessor :kind
@@ -3451,13 +3533,13 @@ module Google
3451
3533
  class TruncateLogContext
3452
3534
  include Google::Apis::Core::Hashable
3453
3535
 
3454
- # This is always **sql#truncateLogContext**.
3536
+ # This is always `sql#truncateLogContext`.
3455
3537
  # Corresponds to the JSON property `kind`
3456
3538
  # @return [String]
3457
3539
  attr_accessor :kind
3458
3540
 
3459
- # The type of log to truncate. Valid values are **MYSQL_GENERAL_TABLE** and **
3460
- # MYSQL_SLOW_TABLE**.
3541
+ # The type of log to truncate. Valid values are `MYSQL_GENERAL_TABLE` and `
3542
+ # MYSQL_SLOW_TABLE`.
3461
3543
  # Corresponds to the JSON property `logType`
3462
3544
  # @return [String]
3463
3545
  attr_accessor :log_type
@@ -3482,26 +3564,28 @@ module Google
3482
3564
  # @return [String]
3483
3565
  attr_accessor :etag
3484
3566
 
3485
- # The host name from which the user can connect. For **insert** operations, host
3486
- # defaults to an empty string. For **update** operations, host is specified as
3487
- # part of the request URL. The host name cannot be updated after insertion.
3567
+ # Optional. The host from which the user can connect. For `insert` operations,
3568
+ # host defaults to an empty string. For `update` operations, host is specified
3569
+ # as part of the request URL. The host name cannot be updated after insertion.
3570
+ # For a MySQL instance, it's required; for a PostgreSQL or SQL Server instance,
3571
+ # it's optional.
3488
3572
  # Corresponds to the JSON property `host`
3489
3573
  # @return [String]
3490
3574
  attr_accessor :host
3491
3575
 
3492
3576
  # The name of the Cloud SQL instance. This does not include the project ID. Can
3493
- # be omitted for **update** since it is already specified on the URL.
3577
+ # be omitted for `update` because it is already specified on the URL.
3494
3578
  # Corresponds to the JSON property `instance`
3495
3579
  # @return [String]
3496
3580
  attr_accessor :instance
3497
3581
 
3498
- # This is always **sql#user**.
3582
+ # This is always `sql#user`.
3499
3583
  # Corresponds to the JSON property `kind`
3500
3584
  # @return [String]
3501
3585
  attr_accessor :kind
3502
3586
 
3503
- # The name of the user in the Cloud SQL instance. Can be omitted for **update**
3504
- # since it is already specified in the URL.
3587
+ # The name of the user in the Cloud SQL instance. Can be omitted for `update`
3588
+ # because it is already specified in the URL.
3505
3589
  # Corresponds to the JSON property `name`
3506
3590
  # @return [String]
3507
3591
  attr_accessor :name
@@ -3511,8 +3595,13 @@ module Google
3511
3595
  # @return [String]
3512
3596
  attr_accessor :password
3513
3597
 
3598
+ # User level password validation policy.
3599
+ # Corresponds to the JSON property `passwordPolicy`
3600
+ # @return [Google::Apis::SqladminV1::UserPasswordValidationPolicy]
3601
+ attr_accessor :password_policy
3602
+
3514
3603
  # The project ID of the project containing the Cloud SQL database. The Google
3515
- # apps domain is prefixed if applicable. Can be omitted for **update** since it
3604
+ # apps domain is prefixed if applicable. Can be omitted for `update` because it
3516
3605
  # is already specified on the URL.
3517
3606
  # Corresponds to the JSON property `project`
3518
3607
  # @return [String]
@@ -3541,12 +3630,51 @@ module Google
3541
3630
  @kind = args[:kind] if args.key?(:kind)
3542
3631
  @name = args[:name] if args.key?(:name)
3543
3632
  @password = args[:password] if args.key?(:password)
3633
+ @password_policy = args[:password_policy] if args.key?(:password_policy)
3544
3634
  @project = args[:project] if args.key?(:project)
3545
3635
  @sqlserver_user_details = args[:sqlserver_user_details] if args.key?(:sqlserver_user_details)
3546
3636
  @type = args[:type] if args.key?(:type)
3547
3637
  end
3548
3638
  end
3549
3639
 
3640
+ # User level password validation policy.
3641
+ class UserPasswordValidationPolicy
3642
+ include Google::Apis::Core::Hashable
3643
+
3644
+ # Number of failed login attempts allowed before user get locked.
3645
+ # Corresponds to the JSON property `allowedFailedAttempts`
3646
+ # @return [Fixnum]
3647
+ attr_accessor :allowed_failed_attempts
3648
+
3649
+ # If true, failed login attempts check will be enabled.
3650
+ # Corresponds to the JSON property `enableFailedAttemptsCheck`
3651
+ # @return [Boolean]
3652
+ attr_accessor :enable_failed_attempts_check
3653
+ alias_method :enable_failed_attempts_check?, :enable_failed_attempts_check
3654
+
3655
+ # Expiration duration after password is updated.
3656
+ # Corresponds to the JSON property `passwordExpirationDuration`
3657
+ # @return [String]
3658
+ attr_accessor :password_expiration_duration
3659
+
3660
+ # Read-only password status.
3661
+ # Corresponds to the JSON property `status`
3662
+ # @return [Google::Apis::SqladminV1::PasswordStatus]
3663
+ attr_accessor :status
3664
+
3665
+ def initialize(**args)
3666
+ update!(**args)
3667
+ end
3668
+
3669
+ # Update properties of this object
3670
+ def update!(**args)
3671
+ @allowed_failed_attempts = args[:allowed_failed_attempts] if args.key?(:allowed_failed_attempts)
3672
+ @enable_failed_attempts_check = args[:enable_failed_attempts_check] if args.key?(:enable_failed_attempts_check)
3673
+ @password_expiration_duration = args[:password_expiration_duration] if args.key?(:password_expiration_duration)
3674
+ @status = args[:status] if args.key?(:status)
3675
+ end
3676
+ end
3677
+
3550
3678
  # User list response.
3551
3679
  class UsersListResponse
3552
3680
  include Google::Apis::Core::Hashable
@@ -3556,7 +3684,7 @@ module Google
3556
3684
  # @return [Array<Google::Apis::SqladminV1::User>]
3557
3685
  attr_accessor :items
3558
3686
 
3559
- # This is always **sql#usersList**.
3687
+ # This is always `sql#usersList`.
3560
3688
  # Corresponds to the JSON property `kind`
3561
3689
  # @return [String]
3562
3690
  attr_accessor :kind