pub struct SqlInstancesServiceClient<T> { /* private fields */ }

Implementations§

source§

impl<T> SqlInstancesServiceClient<T>
where T: GrpcService<BoxBody>, T::Error: Into<StdError>, T::ResponseBody: Body<Data = Bytes> + Send + 'static, <T::ResponseBody as Body>::Error: Into<StdError> + Send,

source

pub fn new(inner: T) -> Self

source

pub fn with_origin(inner: T, origin: Uri) -> Self

source

pub fn with_interceptor<F>( inner: T, interceptor: F, ) -> SqlInstancesServiceClient<InterceptedService<T, F>>
where F: Interceptor, T::ResponseBody: Default, T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>, <T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,

source

pub fn send_compressed(self, encoding: CompressionEncoding) -> Self

Compress requests with the given encoding.

This requires the server to support it otherwise it might respond with an error.

source

pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self

Enable decompressing responses.

source

pub fn max_decoding_message_size(self, limit: usize) -> Self

Limits the maximum size of a decoded message.

Default: 4MB

source

pub fn max_encoding_message_size(self, limit: usize) -> Self

Limits the maximum size of an encoded message.

Default: usize::MAX

source

pub async fn add_server_ca( &mut self, request: impl IntoRequest<SqlInstancesAddServerCaRequest>, ) -> Result<Response<Operation>, Status>

Add a new trusted Certificate Authority (CA) version for the specified instance. Required to prepare for a certificate rotation. If a CA version was previously added but never used in a certificate rotation, this operation replaces that version. There cannot be more than one CA version waiting to be rotated in.

source

pub async fn clone( &mut self, request: impl IntoRequest<SqlInstancesCloneRequest>, ) -> Result<Response<Operation>, Status>

Creates a Cloud SQL instance as a clone of the source instance. Using this operation might cause your instance to restart.

source

pub async fn delete( &mut self, request: impl IntoRequest<SqlInstancesDeleteRequest>, ) -> Result<Response<Operation>, Status>

Deletes a Cloud SQL instance.

source

pub async fn demote_master( &mut self, request: impl IntoRequest<SqlInstancesDemoteMasterRequest>, ) -> Result<Response<Operation>, Status>

Demotes the stand-alone instance to be a Cloud SQL read replica for an external database server.

source

pub async fn demote( &mut self, request: impl IntoRequest<SqlInstancesDemoteRequest>, ) -> Result<Response<Operation>, Status>

Demotes an existing standalone instance to be a Cloud SQL read replica for an external database server.

source

pub async fn export( &mut self, request: impl IntoRequest<SqlInstancesExportRequest>, ) -> Result<Response<Operation>, Status>

Exports data from a Cloud SQL instance to a Cloud Storage bucket as a SQL dump or CSV file.

source

pub async fn failover( &mut self, request: impl IntoRequest<SqlInstancesFailoverRequest>, ) -> Result<Response<Operation>, Status>

Initiates a manual failover of a high availability (HA) primary instance to a standby instance, which becomes the primary instance. Users are then rerouted to the new primary. For more information, see the Overview of high availability page in the Cloud SQL documentation. If using Legacy HA (MySQL only), this causes the instance to failover to its failover replica instance.

source

pub async fn reencrypt( &mut self, request: impl IntoRequest<SqlInstancesReencryptRequest>, ) -> Result<Response<Operation>, Status>

Reencrypt CMEK instance with latest key version.

source

pub async fn get( &mut self, request: impl IntoRequest<SqlInstancesGetRequest>, ) -> Result<Response<DatabaseInstance>, Status>

Retrieves a resource containing information about a Cloud SQL instance.

source

pub async fn import( &mut self, request: impl IntoRequest<SqlInstancesImportRequest>, ) -> Result<Response<Operation>, Status>

Imports data into a Cloud SQL instance from a SQL dump or CSV file in Cloud Storage.

source

pub async fn insert( &mut self, request: impl IntoRequest<SqlInstancesInsertRequest>, ) -> Result<Response<Operation>, Status>

Creates a new Cloud SQL instance.

source

pub async fn list( &mut self, request: impl IntoRequest<SqlInstancesListRequest>, ) -> Result<Response<InstancesListResponse>, Status>

Lists instances under a given project.

source

pub async fn list_server_cas( &mut self, request: impl IntoRequest<SqlInstancesListServerCasRequest>, ) -> Result<Response<InstancesListServerCasResponse>, Status>

Lists all of the trusted Certificate Authorities (CAs) for the specified instance. There can be up to three CAs listed: the CA that was used to sign the certificate that is currently in use, a CA that has been added but not yet used to sign a certificate, and a CA used to sign a certificate that has previously rotated out.

source

pub async fn patch( &mut self, request: impl IntoRequest<SqlInstancesPatchRequest>, ) -> Result<Response<Operation>, Status>

Partially updates settings of a Cloud SQL instance by merging the request with the current configuration. This method supports patch semantics.

source

pub async fn promote_replica( &mut self, request: impl IntoRequest<SqlInstancesPromoteReplicaRequest>, ) -> Result<Response<Operation>, Status>

Promotes the read replica instance to be an independent Cloud SQL primary instance. Using this operation might cause your instance to restart.

source

pub async fn switchover( &mut self, request: impl IntoRequest<SqlInstancesSwitchoverRequest>, ) -> Result<Response<Operation>, Status>

Switches over from the primary instance to the designated DR replica instance.

source

pub async fn reset_ssl_config( &mut self, request: impl IntoRequest<SqlInstancesResetSslConfigRequest>, ) -> Result<Response<Operation>, Status>

Deletes all client certificates and generates a new server SSL certificate for the instance.

source

pub async fn restart( &mut self, request: impl IntoRequest<SqlInstancesRestartRequest>, ) -> Result<Response<Operation>, Status>

Restarts a Cloud SQL instance.

source

pub async fn restore_backup( &mut self, request: impl IntoRequest<SqlInstancesRestoreBackupRequest>, ) -> Result<Response<Operation>, Status>

Restores a backup of a Cloud SQL instance. Using this operation might cause your instance to restart.

source

pub async fn rotate_server_ca( &mut self, request: impl IntoRequest<SqlInstancesRotateServerCaRequest>, ) -> Result<Response<Operation>, Status>

Rotates the server certificate to one signed by the Certificate Authority (CA) version previously added with the addServerCA method.

source

pub async fn start_replica( &mut self, request: impl IntoRequest<SqlInstancesStartReplicaRequest>, ) -> Result<Response<Operation>, Status>

Starts the replication in the read replica instance.

source

pub async fn stop_replica( &mut self, request: impl IntoRequest<SqlInstancesStopReplicaRequest>, ) -> Result<Response<Operation>, Status>

Stops the replication in the read replica instance.

source

pub async fn truncate_log( &mut self, request: impl IntoRequest<SqlInstancesTruncateLogRequest>, ) -> Result<Response<Operation>, Status>

Truncate MySQL general and slow query log tables MySQL only.

source

pub async fn update( &mut self, request: impl IntoRequest<SqlInstancesUpdateRequest>, ) -> Result<Response<Operation>, Status>

Updates settings of a Cloud SQL instance. Using this operation might cause your instance to restart.

source

pub async fn create_ephemeral( &mut self, request: impl IntoRequest<SqlInstancesCreateEphemeralCertRequest>, ) -> Result<Response<SslCert>, Status>

Generates a short-lived X509 certificate containing the provided public key and signed by a private key specific to the target instance. Users may use the certificate to authenticate as themselves when connecting to the database.

source

pub async fn reschedule_maintenance( &mut self, request: impl IntoRequest<SqlInstancesRescheduleMaintenanceRequest>, ) -> Result<Response<Operation>, Status>

Reschedules the maintenance on the given instance.

source

pub async fn verify_external_sync_settings( &mut self, request: impl IntoRequest<SqlInstancesVerifyExternalSyncSettingsRequest>, ) -> Result<Response<SqlInstancesVerifyExternalSyncSettingsResponse>, Status>

Verify External primary instance external sync settings.

source

pub async fn start_external_sync( &mut self, request: impl IntoRequest<SqlInstancesStartExternalSyncRequest>, ) -> Result<Response<Operation>, Status>

Start External primary instance migration.

source

pub async fn perform_disk_shrink( &mut self, request: impl IntoRequest<SqlInstancesPerformDiskShrinkRequest>, ) -> Result<Response<Operation>, Status>

Perform Disk Shrink on primary instance.

source

pub async fn get_disk_shrink_config( &mut self, request: impl IntoRequest<SqlInstancesGetDiskShrinkConfigRequest>, ) -> Result<Response<SqlInstancesGetDiskShrinkConfigResponse>, Status>

Get Disk Shrink Config for a given instance.

source

pub async fn reset_replica_size( &mut self, request: impl IntoRequest<SqlInstancesResetReplicaSizeRequest>, ) -> Result<Response<Operation>, Status>

Reset Replica Size to primary instance disk size.

source

pub async fn get_latest_recovery_time( &mut self, request: impl IntoRequest<SqlInstancesGetLatestRecoveryTimeRequest>, ) -> Result<Response<SqlInstancesGetLatestRecoveryTimeResponse>, Status>

Get Latest Recovery Time for a given instance.

source

pub async fn acquire_ssrs_lease( &mut self, request: impl IntoRequest<SqlInstancesAcquireSsrsLeaseRequest>, ) -> Result<Response<SqlInstancesAcquireSsrsLeaseResponse>, Status>

Acquire a lease for the setup of SQL Server Reporting Services (SSRS).

source

pub async fn release_ssrs_lease( &mut self, request: impl IntoRequest<SqlInstancesReleaseSsrsLeaseRequest>, ) -> Result<Response<SqlInstancesReleaseSsrsLeaseResponse>, Status>

Release a lease for the setup of SQL Server Reporting Services (SSRS).

Trait Implementations§

source§

impl<T: Clone> Clone for SqlInstancesServiceClient<T>

source§

fn clone(&self) -> SqlInstancesServiceClient<T>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<T: Debug> Debug for SqlInstancesServiceClient<T>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> FromRef<T> for T
where T: Clone,

§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoRequest<T> for T

source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more