Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions api_names_out.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -358860,6 +358860,8 @@
"/sqladmin:v1beta4/InstancesListServerCertificatesResponse/kind": kind
"/sqladmin:v1beta4/InstancesListServerCertificatesResponse/serverCerts": server_certs
"/sqladmin:v1beta4/InstancesListServerCertificatesResponse/serverCerts/server_cert": server_cert
"/sqladmin:v1beta4/InstancesPreCheckMajorVersionUpgradeRequest": instances_pre_check_major_version_upgrade_request
"/sqladmin:v1beta4/InstancesPreCheckMajorVersionUpgradeRequest/preCheckMajorVersionUpgradeContext": pre_check_major_version_upgrade_context
"/sqladmin:v1beta4/InstancesReencryptRequest": instances_reencrypt_request
"/sqladmin:v1beta4/InstancesReencryptRequest/backupReencryptionConfig": backup_reencryption_config
"/sqladmin:v1beta4/InstancesRestoreBackupRequest": restore_instances_backup_request
Expand Down Expand Up @@ -358962,6 +358964,7 @@
"/sqladmin:v1beta4/Operation/kind": kind
"/sqladmin:v1beta4/Operation/name": name
"/sqladmin:v1beta4/Operation/operationType": operation_type
"/sqladmin:v1beta4/Operation/preCheckMajorVersionUpgradeContext": pre_check_major_version_upgrade_context
"/sqladmin:v1beta4/Operation/selfLink": self_link
"/sqladmin:v1beta4/Operation/startTime": start_time
"/sqladmin:v1beta4/Operation/status": status
Expand Down Expand Up @@ -359026,6 +359029,16 @@
"/sqladmin:v1beta4/PoolNodeConfig/ipAddresses/ip_address": ip_address
"/sqladmin:v1beta4/PoolNodeConfig/name": name
"/sqladmin:v1beta4/PoolNodeConfig/state": state
"/sqladmin:v1beta4/PreCheckMajorVersionUpgradeContext": pre_check_major_version_upgrade_context
"/sqladmin:v1beta4/PreCheckMajorVersionUpgradeContext/kind": kind
"/sqladmin:v1beta4/PreCheckMajorVersionUpgradeContext/preCheckResponse": pre_check_response
"/sqladmin:v1beta4/PreCheckMajorVersionUpgradeContext/preCheckResponse/pre_check_response": pre_check_response
"/sqladmin:v1beta4/PreCheckMajorVersionUpgradeContext/targetDatabaseVersion": target_database_version
"/sqladmin:v1beta4/PreCheckResponse": pre_check_response
"/sqladmin:v1beta4/PreCheckResponse/actionsRequired": actions_required
"/sqladmin:v1beta4/PreCheckResponse/actionsRequired/actions_required": actions_required
"/sqladmin:v1beta4/PreCheckResponse/message": message
"/sqladmin:v1beta4/PreCheckResponse/messageType": message_type
"/sqladmin:v1beta4/PscAutoConnectionConfig": psc_auto_connection_config
"/sqladmin:v1beta4/PscAutoConnectionConfig/consumerNetwork": consumer_network
"/sqladmin:v1beta4/PscAutoConnectionConfig/consumerNetworkStatus": consumer_network_status
Expand All @@ -359051,6 +359064,8 @@
"/sqladmin:v1beta4/ReadPoolAutoScaleConfig/enabled": enabled
"/sqladmin:v1beta4/ReadPoolAutoScaleConfig/maxNodeCount": max_node_count
"/sqladmin:v1beta4/ReadPoolAutoScaleConfig/minNodeCount": min_node_count
"/sqladmin:v1beta4/ReadPoolAutoScaleConfig/scaleInCooldownSeconds": scale_in_cooldown_seconds
"/sqladmin:v1beta4/ReadPoolAutoScaleConfig/scaleOutCooldownSeconds": scale_out_cooldown_seconds
"/sqladmin:v1beta4/ReadPoolAutoScaleConfig/targetMetrics": target_metrics
"/sqladmin:v1beta4/ReadPoolAutoScaleConfig/targetMetrics/target_metric": target_metric
"/sqladmin:v1beta4/ReplicaConfiguration": replica_configuration
Expand Down Expand Up @@ -359406,6 +359421,9 @@
"/sqladmin:v1beta4/sql.instances.patch/project": project
"/sqladmin:v1beta4/sql.instances.pointInTimeRestore": point_instance_in_time_restore
"/sqladmin:v1beta4/sql.instances.pointInTimeRestore/parent": parent
"/sqladmin:v1beta4/sql.instances.preCheckMajorVersionUpgrade": pre_instance_check_major_version_upgrade
"/sqladmin:v1beta4/sql.instances.preCheckMajorVersionUpgrade/instance": instance
"/sqladmin:v1beta4/sql.instances.preCheckMajorVersionUpgrade/project": project
"/sqladmin:v1beta4/sql.instances.promoteReplica": promote_instance_replica
"/sqladmin:v1beta4/sql.instances.promoteReplica/failover": failover
"/sqladmin:v1beta4/sql.instances.promoteReplica/instance": instance
Expand Down
4 changes: 4 additions & 0 deletions generated/google-apis-sqladmin_v1beta4/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release history for google-apis-sqladmin_v1beta4

### v0.91.0 (2025-09-28)

* Regenerated from discovery document revision 20250915

### v0.90.0 (2025-09-21)

* Regenerated from discovery document revision 20250908
Expand Down
2 changes: 1 addition & 1 deletion generated/google-apis-sqladmin_v1beta4/OVERVIEW.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ Gem names for modern clients are often of the form `google-cloud-<service_name>`

**For most users, we recommend the modern client, if one is available.** Compared with simple clients, modern clients are generally much easier to use and more Ruby-like, support more advanced features such as streaming and long-running operations, and often provide much better performance. You may consider using a simple client instead, if a modern client is not yet available for the service you want to use, or if you are not able to use gRPC on your infrastructure.

The [product documentation](https://developers.google.com/cloud-sql/) may provide guidance regarding the preferred client library to use.
The [product documentation](https://cloud.google.com/sql/docs) may provide guidance regarding the preferred client library to use.

## Supported Ruby versions

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ module Apis
#
# API for Cloud SQL database instance management
#
# @see https://developers.google.com/cloud-sql/
# @see https://cloud.google.com/sql/docs
module SqladminV1beta4
# Version of the Cloud SQL Admin API this client connects to.
# This is NOT the gem version.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3243,6 +3243,25 @@ def update!(**args)
end
end

# Request for Pre-checks for MVU
class InstancesPreCheckMajorVersionUpgradeRequest
include Google::Apis::Core::Hashable

# Pre-check major version upgrade context.
# Corresponds to the JSON property `preCheckMajorVersionUpgradeContext`
# @return [Google::Apis::SqladminV1beta4::PreCheckMajorVersionUpgradeContext]
attr_accessor :pre_check_major_version_upgrade_context

def initialize(**args)
update!(**args)
end

# Update properties of this object
def update!(**args)
@pre_check_major_version_upgrade_context = args[:pre_check_major_version_upgrade_context] if args.key?(:pre_check_major_version_upgrade_context)
end
end

# Database Instance reencrypt request.
class InstancesReencryptRequest
include Google::Apis::Core::Hashable
Expand Down Expand Up @@ -3967,6 +3986,11 @@ class Operation
# @return [String]
attr_accessor :operation_type

# Pre-check major version upgrade context.
# Corresponds to the JSON property `preCheckMajorVersionUpgradeContext`
# @return [Google::Apis::SqladminV1beta4::PreCheckMajorVersionUpgradeContext]
attr_accessor :pre_check_major_version_upgrade_context

# The URI of this resource.
# Corresponds to the JSON property `selfLink`
# @return [String]
Expand Down Expand Up @@ -4025,6 +4049,7 @@ def update!(**args)
@kind = args[:kind] if args.key?(:kind)
@name = args[:name] if args.key?(:name)
@operation_type = args[:operation_type] if args.key?(:operation_type)
@pre_check_major_version_upgrade_context = args[:pre_check_major_version_upgrade_context] if args.key?(:pre_check_major_version_upgrade_context)
@self_link = args[:self_link] if args.key?(:self_link)
@start_time = args[:start_time] if args.key?(:start_time)
@status = args[:status] if args.key?(:status)
Expand Down Expand Up @@ -4407,6 +4432,68 @@ def update!(**args)
end
end

# Pre-check major version upgrade context.
class PreCheckMajorVersionUpgradeContext
include Google::Apis::Core::Hashable

# Optional. This is always `sql#preCheckMajorVersionUpgradeContext`.
# Corresponds to the JSON property `kind`
# @return [String]
attr_accessor :kind

# Output only. The responses from the precheck operation.
# Corresponds to the JSON property `preCheckResponse`
# @return [Array<Google::Apis::SqladminV1beta4::PreCheckResponse>]
attr_accessor :pre_check_response

# Required. The target database version to upgrade to.
# Corresponds to the JSON property `targetDatabaseVersion`
# @return [String]
attr_accessor :target_database_version

def initialize(**args)
update!(**args)
end

# Update properties of this object
def update!(**args)
@kind = args[:kind] if args.key?(:kind)
@pre_check_response = args[:pre_check_response] if args.key?(:pre_check_response)
@target_database_version = args[:target_database_version] if args.key?(:target_database_version)
end
end

# Structured PreCheckResponse containing message, type, and required actions.
class PreCheckResponse
include Google::Apis::Core::Hashable

# The actions that the user needs to take. Use repeated for multiple actions.
# Corresponds to the JSON property `actionsRequired`
# @return [Array<String>]
attr_accessor :actions_required

# The message to be displayed to the user.
# Corresponds to the JSON property `message`
# @return [String]
attr_accessor :message

# The type of message whether it is an info, warning, or error.
# Corresponds to the JSON property `messageType`
# @return [String]
attr_accessor :message_type

def initialize(**args)
update!(**args)
end

# Update properties of this object
def update!(**args)
@actions_required = args[:actions_required] if args.key?(:actions_required)
@message = args[:message] if args.key?(:message)
@message_type = args[:message_type] if args.key?(:message_type)
end
end

# Settings for an automatically-setup Private Service Connect consumer endpoint
# that is used to connect to a Cloud SQL instance.
class PscAutoConnectionConfig
Expand Down Expand Up @@ -4566,6 +4653,16 @@ class ReadPoolAutoScaleConfig
# @return [Fixnum]
attr_accessor :min_node_count

# The cooldown period for scale in operations.
# Corresponds to the JSON property `scaleInCooldownSeconds`
# @return [Fixnum]
attr_accessor :scale_in_cooldown_seconds

# The cooldown period for scale out operations.
# Corresponds to the JSON property `scaleOutCooldownSeconds`
# @return [Fixnum]
attr_accessor :scale_out_cooldown_seconds

# Optional. Target metrics for read pool auto scaling.
# Corresponds to the JSON property `targetMetrics`
# @return [Array<Google::Apis::SqladminV1beta4::TargetMetric>]
Expand All @@ -4581,6 +4678,8 @@ def update!(**args)
@enabled = args[:enabled] if args.key?(:enabled)
@max_node_count = args[:max_node_count] if args.key?(:max_node_count)
@min_node_count = args[:min_node_count] if args.key?(:min_node_count)
@scale_in_cooldown_seconds = args[:scale_in_cooldown_seconds] if args.key?(:scale_in_cooldown_seconds)
@scale_out_cooldown_seconds = args[:scale_out_cooldown_seconds] if args.key?(:scale_out_cooldown_seconds)
@target_metrics = args[:target_metrics] if args.key?(:target_metrics)
end
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ module Google
module Apis
module SqladminV1beta4
# Version of the google-apis-sqladmin_v1beta4 gem
GEM_VERSION = "0.90.0"
GEM_VERSION = "0.91.0"

# Version of the code generator used to generate this client
GENERATOR_VERSION = "0.18.0"

# Revision of the discovery document this client was generated from
REVISION = "20250908"
REVISION = "20250915"
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -436,6 +436,12 @@ class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end

class InstancesPreCheckMajorVersionUpgradeRequest
class Representation < Google::Apis::Core::JsonRepresentation; end

include Google::Apis::Core::JsonObjectSupport
end

class InstancesReencryptRequest
class Representation < Google::Apis::Core::JsonRepresentation; end

Expand Down Expand Up @@ -592,6 +598,18 @@ class Representation < Google::Apis::Core::JsonRepresentation; end
include Google::Apis::Core::JsonObjectSupport
end

class PreCheckMajorVersionUpgradeContext
class Representation < Google::Apis::Core::JsonRepresentation; end

include Google::Apis::Core::JsonObjectSupport
end

class PreCheckResponse
class Representation < Google::Apis::Core::JsonRepresentation; end

include Google::Apis::Core::JsonObjectSupport
end

class PscAutoConnectionConfig
class Representation < Google::Apis::Core::JsonRepresentation; end

Expand Down Expand Up @@ -1683,6 +1701,14 @@ class Representation < Google::Apis::Core::JsonRepresentation
end
end

class InstancesPreCheckMajorVersionUpgradeRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :pre_check_major_version_upgrade_context, as: 'preCheckMajorVersionUpgradeContext', class: Google::Apis::SqladminV1beta4::PreCheckMajorVersionUpgradeContext, decorator: Google::Apis::SqladminV1beta4::PreCheckMajorVersionUpgradeContext::Representation

end
end

class InstancesReencryptRequest
# @private
class Representation < Google::Apis::Core::JsonRepresentation
Expand Down Expand Up @@ -1874,6 +1900,8 @@ class Representation < Google::Apis::Core::JsonRepresentation
property :kind, as: 'kind'
property :name, as: 'name'
property :operation_type, as: 'operationType'
property :pre_check_major_version_upgrade_context, as: 'preCheckMajorVersionUpgradeContext', class: Google::Apis::SqladminV1beta4::PreCheckMajorVersionUpgradeContext, decorator: Google::Apis::SqladminV1beta4::PreCheckMajorVersionUpgradeContext::Representation

property :self_link, as: 'selfLink'
property :start_time, as: 'startTime'
property :status, as: 'status'
Expand Down Expand Up @@ -1982,6 +2010,25 @@ class Representation < Google::Apis::Core::JsonRepresentation
end
end

class PreCheckMajorVersionUpgradeContext
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :kind, as: 'kind'
collection :pre_check_response, as: 'preCheckResponse', class: Google::Apis::SqladminV1beta4::PreCheckResponse, decorator: Google::Apis::SqladminV1beta4::PreCheckResponse::Representation

property :target_database_version, as: 'targetDatabaseVersion'
end
end

class PreCheckResponse
# @private
class Representation < Google::Apis::Core::JsonRepresentation
collection :actions_required, as: 'actionsRequired'
property :message, as: 'message'
property :message_type, as: 'messageType'
end
end

class PscAutoConnectionConfig
# @private
class Representation < Google::Apis::Core::JsonRepresentation
Expand Down Expand Up @@ -2023,6 +2070,8 @@ class Representation < Google::Apis::Core::JsonRepresentation
property :enabled, as: 'enabled'
property :max_node_count, as: 'maxNodeCount'
property :min_node_count, as: 'minNodeCount'
property :scale_in_cooldown_seconds, as: 'scaleInCooldownSeconds'
property :scale_out_cooldown_seconds, as: 'scaleOutCooldownSeconds'
collection :target_metrics, as: 'targetMetrics', class: Google::Apis::SqladminV1beta4::TargetMetric, decorator: Google::Apis::SqladminV1beta4::TargetMetric::Representation

end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ module SqladminV1beta4
# Sqladmin = Google::Apis::SqladminV1beta4 # Alias the module
# service = Sqladmin::SQLAdminService.new
#
# @see https://developers.google.com/cloud-sql/
# @see https://cloud.google.com/sql/docs
class SQLAdminService < Google::Apis::Core::BaseService
DEFAULT_ENDPOINT_TEMPLATE = "https://sqladmin.$UNIVERSE_DOMAIN$/"

Expand Down Expand Up @@ -1442,6 +1442,42 @@ def point_instance_in_time_restore(parent, point_in_time_restore_context_object
execute_or_queue_command(command, &block)
end

# Execute MVU Pre-checks
# @param [String] project
# Required. Project ID of the project that contains the instance.
# @param [String] instance
# Required. Cloud SQL instance ID. This does not include the project ID.
# @param [Google::Apis::SqladminV1beta4::InstancesPreCheckMajorVersionUpgradeRequest] instances_pre_check_major_version_upgrade_request_object
# @param [String] fields
# Selector specifying which fields to include in a partial response.
# @param [String] quota_user
# Available to use for quota purposes for server-side applications. Can be any
# arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
# Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::SqladminV1beta4::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::SqladminV1beta4::Operation]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
def pre_instance_check_major_version_upgrade(project, instance, instances_pre_check_major_version_upgrade_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'sql/v1beta4/projects/{project}/instances/{instance}/preCheckMajorVersionUpgrade', options)
command.request_representation = Google::Apis::SqladminV1beta4::InstancesPreCheckMajorVersionUpgradeRequest::Representation
command.request_object = instances_pre_check_major_version_upgrade_request_object
command.response_representation = Google::Apis::SqladminV1beta4::Operation::Representation
command.response_class = Google::Apis::SqladminV1beta4::Operation
command.params['project'] = project unless project.nil?
command.params['instance'] = instance unless instance.nil?
command.query['fields'] = fields unless fields.nil?
command.query['quotaUser'] = quota_user unless quota_user.nil?
execute_or_queue_command(command, &block)
end

# Promotes the read replica instance to be an independent Cloud SQL primary
# instance. Using this operation might cause your instance to restart.
# @param [String] project
Expand Down Expand Up @@ -1879,6 +1915,7 @@ def update_instance(project, instance, database_instance_object = nil, fields: n
end

# Cancels an instance operation that has been performed on an instance.
# Ordinarily, this method name should be `CancelSqlOperation`.
# @param [String] project
# Project ID of the project that contains the instance.
# @param [String] operation
Expand Down
Loading