public class DatabaseAdminClient : ClientBase<DatabaseAdmin.DatabaseAdminClient>
Client for DatabaseAdmin
Inheritance
Object > ClientBase > ClientBase<DatabaseAdmin.DatabaseAdminClient> > DatabaseAdmin.DatabaseAdminClientNamespace
Google.Cloud.Spanner.Admin.Database.V1Assembly
Google.Cloud.Spanner.Admin.Database.V1.dll
Constructors
DatabaseAdminClient()
protected DatabaseAdminClient()
Protected parameterless constructor to allow creation of test doubles.
DatabaseAdminClient(CallInvoker)
public DatabaseAdminClient(CallInvoker callInvoker)
Creates a new client for DatabaseAdmin that uses a custom CallInvoker
.
Parameter | |
---|---|
Name | Description |
callInvoker | CallInvoker The callInvoker to use to make remote calls. |
DatabaseAdminClient(Channel)
[Obsolete("This constructor overload is present for compatibility only, and will be removed in the next major version")]
public DatabaseAdminClient(Channel channel)
Creates a new client using a channel.
Parameter | |
---|---|
Name | Description |
channel | Grpc.Core.Channel The channel to use to make remote calls. |
DatabaseAdminClient(ChannelBase)
public DatabaseAdminClient(ChannelBase channel)
Creates a new client for DatabaseAdmin
Parameter | |
---|---|
Name | Description |
channel | ChannelBase The channel to use to make remote calls. |
DatabaseAdminClient(ClientBase.ClientBaseConfiguration)
protected DatabaseAdminClient(ClientBase.ClientBaseConfiguration configuration)
Protected constructor to allow creation of configured clients.
Parameter | |
---|---|
Name | Description |
configuration | ClientBase.ClientBaseConfiguration The client configuration. |
Methods
CopyBackup(CopyBackupRequest, CallOptions)
public virtual Operation CopyBackup(CopyBackupRequest request, CallOptions options)
Starts copying a Cloud Spanner Backup.
The returned backup [long-running operation][google.longrunning.Operation]
will have a name of the format
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation_id>
and can be used to track copying of the backup. The operation is associated
with the destination backup.
The [metadata][google.longrunning.Operation.metadata] field type is
[CopyBackupMetadata][google.spanner.admin.database.v1.CopyBackupMetadata].
The [response][google.longrunning.Operation.response] field type is
[Backup][google.spanner.admin.database.v1.Backup], if successful. Cancelling the returned operation will stop the
copying and delete the backup.
Concurrent CopyBackup requests can run on the same source backup.
Parameters | |
---|---|
Name | Description |
request | CopyBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
CopyBackup(CopyBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation CopyBackup(CopyBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Starts copying a Cloud Spanner Backup.
The returned backup [long-running operation][google.longrunning.Operation]
will have a name of the format
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation_id>
and can be used to track copying of the backup. The operation is associated
with the destination backup.
The [metadata][google.longrunning.Operation.metadata] field type is
[CopyBackupMetadata][google.spanner.admin.database.v1.CopyBackupMetadata].
The [response][google.longrunning.Operation.response] field type is
[Backup][google.spanner.admin.database.v1.Backup], if successful. Cancelling the returned operation will stop the
copying and delete the backup.
Concurrent CopyBackup requests can run on the same source backup.
Parameters | |
---|---|
Name | Description |
request | CopyBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
CopyBackupAsync(CopyBackupRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> CopyBackupAsync(CopyBackupRequest request, CallOptions options)
Starts copying a Cloud Spanner Backup.
The returned backup [long-running operation][google.longrunning.Operation]
will have a name of the format
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation_id>
and can be used to track copying of the backup. The operation is associated
with the destination backup.
The [metadata][google.longrunning.Operation.metadata] field type is
[CopyBackupMetadata][google.spanner.admin.database.v1.CopyBackupMetadata].
The [response][google.longrunning.Operation.response] field type is
[Backup][google.spanner.admin.database.v1.Backup], if successful. Cancelling the returned operation will stop the
copying and delete the backup.
Concurrent CopyBackup requests can run on the same source backup.
Parameters | |
---|---|
Name | Description |
request | CopyBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
CopyBackupAsync(CopyBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> CopyBackupAsync(CopyBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Starts copying a Cloud Spanner Backup.
The returned backup [long-running operation][google.longrunning.Operation]
will have a name of the format
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation_id>
and can be used to track copying of the backup. The operation is associated
with the destination backup.
The [metadata][google.longrunning.Operation.metadata] field type is
[CopyBackupMetadata][google.spanner.admin.database.v1.CopyBackupMetadata].
The [response][google.longrunning.Operation.response] field type is
[Backup][google.spanner.admin.database.v1.Backup], if successful. Cancelling the returned operation will stop the
copying and delete the backup.
Concurrent CopyBackup requests can run on the same source backup.
Parameters | |
---|---|
Name | Description |
request | CopyBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
CreateBackup(CreateBackupRequest, CallOptions)
public virtual Operation CreateBackup(CreateBackupRequest request, CallOptions options)
Starts creating a new Cloud Spanner Backup.
The returned backup [long-running operation][google.longrunning.Operation]
will have a name of the format
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation_id>
and can be used to track creation of the backup. The
[metadata][google.longrunning.Operation.metadata] field type is
[CreateBackupMetadata][google.spanner.admin.database.v1.CreateBackupMetadata]. The
[response][google.longrunning.Operation.response] field type is
[Backup][google.spanner.admin.database.v1.Backup], if successful. Cancelling the returned operation will stop the
creation and delete the backup.
There can be only one pending backup creation per database. Backup creation
of different databases can run concurrently.
Parameters | |
---|---|
Name | Description |
request | CreateBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
CreateBackup(CreateBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation CreateBackup(CreateBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Starts creating a new Cloud Spanner Backup.
The returned backup [long-running operation][google.longrunning.Operation]
will have a name of the format
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation_id>
and can be used to track creation of the backup. The
[metadata][google.longrunning.Operation.metadata] field type is
[CreateBackupMetadata][google.spanner.admin.database.v1.CreateBackupMetadata]. The
[response][google.longrunning.Operation.response] field type is
[Backup][google.spanner.admin.database.v1.Backup], if successful. Cancelling the returned operation will stop the
creation and delete the backup.
There can be only one pending backup creation per database. Backup creation
of different databases can run concurrently.
Parameters | |
---|---|
Name | Description |
request | CreateBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
CreateBackupAsync(CreateBackupRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> CreateBackupAsync(CreateBackupRequest request, CallOptions options)
Starts creating a new Cloud Spanner Backup.
The returned backup [long-running operation][google.longrunning.Operation]
will have a name of the format
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation_id>
and can be used to track creation of the backup. The
[metadata][google.longrunning.Operation.metadata] field type is
[CreateBackupMetadata][google.spanner.admin.database.v1.CreateBackupMetadata]. The
[response][google.longrunning.Operation.response] field type is
[Backup][google.spanner.admin.database.v1.Backup], if successful. Cancelling the returned operation will stop the
creation and delete the backup.
There can be only one pending backup creation per database. Backup creation
of different databases can run concurrently.
Parameters | |
---|---|
Name | Description |
request | CreateBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
CreateBackupAsync(CreateBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> CreateBackupAsync(CreateBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Starts creating a new Cloud Spanner Backup.
The returned backup [long-running operation][google.longrunning.Operation]
will have a name of the format
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation_id>
and can be used to track creation of the backup. The
[metadata][google.longrunning.Operation.metadata] field type is
[CreateBackupMetadata][google.spanner.admin.database.v1.CreateBackupMetadata]. The
[response][google.longrunning.Operation.response] field type is
[Backup][google.spanner.admin.database.v1.Backup], if successful. Cancelling the returned operation will stop the
creation and delete the backup.
There can be only one pending backup creation per database. Backup creation
of different databases can run concurrently.
Parameters | |
---|---|
Name | Description |
request | CreateBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
CreateDatabase(CreateDatabaseRequest, CallOptions)
public virtual Operation CreateDatabase(CreateDatabaseRequest request, CallOptions options)
Creates a new Cloud Spanner database and starts to prepare it for serving.
The returned [long-running operation][google.longrunning.Operation] will
have a name of the format <database_name>/operations/<operation_id>
and
can be used to track preparation of the database. The
[metadata][google.longrunning.Operation.metadata] field type is
[CreateDatabaseMetadata][google.spanner.admin.database.v1.CreateDatabaseMetadata]. The
[response][google.longrunning.Operation.response] field type is
[Database][google.spanner.admin.database.v1.Database], if successful.
Parameters | |
---|---|
Name | Description |
request | CreateDatabaseRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
CreateDatabase(CreateDatabaseRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation CreateDatabase(CreateDatabaseRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Creates a new Cloud Spanner database and starts to prepare it for serving.
The returned [long-running operation][google.longrunning.Operation] will
have a name of the format <database_name>/operations/<operation_id>
and
can be used to track preparation of the database. The
[metadata][google.longrunning.Operation.metadata] field type is
[CreateDatabaseMetadata][google.spanner.admin.database.v1.CreateDatabaseMetadata]. The
[response][google.longrunning.Operation.response] field type is
[Database][google.spanner.admin.database.v1.Database], if successful.
Parameters | |
---|---|
Name | Description |
request | CreateDatabaseRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
CreateDatabaseAsync(CreateDatabaseRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> CreateDatabaseAsync(CreateDatabaseRequest request, CallOptions options)
Creates a new Cloud Spanner database and starts to prepare it for serving.
The returned [long-running operation][google.longrunning.Operation] will
have a name of the format <database_name>/operations/<operation_id>
and
can be used to track preparation of the database. The
[metadata][google.longrunning.Operation.metadata] field type is
[CreateDatabaseMetadata][google.spanner.admin.database.v1.CreateDatabaseMetadata]. The
[response][google.longrunning.Operation.response] field type is
[Database][google.spanner.admin.database.v1.Database], if successful.
Parameters | |
---|---|
Name | Description |
request | CreateDatabaseRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
CreateDatabaseAsync(CreateDatabaseRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> CreateDatabaseAsync(CreateDatabaseRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Creates a new Cloud Spanner database and starts to prepare it for serving.
The returned [long-running operation][google.longrunning.Operation] will
have a name of the format <database_name>/operations/<operation_id>
and
can be used to track preparation of the database. The
[metadata][google.longrunning.Operation.metadata] field type is
[CreateDatabaseMetadata][google.spanner.admin.database.v1.CreateDatabaseMetadata]. The
[response][google.longrunning.Operation.response] field type is
[Database][google.spanner.admin.database.v1.Database], if successful.
Parameters | |
---|---|
Name | Description |
request | CreateDatabaseRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
CreateOperationsClient()
public virtual Operations.OperationsClient CreateOperationsClient()
Creates a new instance of Operations.OperationsClient using the same call invoker as this client.
Returns | |
---|---|
Type | Description |
Operations.OperationsClient | A new Operations client for the same target as this client. |
DeleteBackup(DeleteBackupRequest, CallOptions)
public virtual Empty DeleteBackup(DeleteBackupRequest request, CallOptions options)
Deletes a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | DeleteBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Empty | The response received from the server. |
DeleteBackup(DeleteBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Empty DeleteBackup(DeleteBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Deletes a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | DeleteBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Empty | The response received from the server. |
DeleteBackupAsync(DeleteBackupRequest, CallOptions)
public virtual AsyncUnaryCall<Empty> DeleteBackupAsync(DeleteBackupRequest request, CallOptions options)
Deletes a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | DeleteBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Empty> | The call object. |
DeleteBackupAsync(DeleteBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Empty> DeleteBackupAsync(DeleteBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Deletes a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | DeleteBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Empty> | The call object. |
DropDatabase(DropDatabaseRequest, CallOptions)
public virtual Empty DropDatabase(DropDatabaseRequest request, CallOptions options)
Drops (aka deletes) a Cloud Spanner database.
Completed backups for the database will be retained according to their
expire_time
.
Note: Cloud Spanner might continue to accept requests for a few seconds
after the database has been deleted.
Parameters | |
---|---|
Name | Description |
request | DropDatabaseRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Empty | The response received from the server. |
DropDatabase(DropDatabaseRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Empty DropDatabase(DropDatabaseRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Drops (aka deletes) a Cloud Spanner database.
Completed backups for the database will be retained according to their
expire_time
.
Note: Cloud Spanner might continue to accept requests for a few seconds
after the database has been deleted.
Parameters | |
---|---|
Name | Description |
request | DropDatabaseRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Empty | The response received from the server. |
DropDatabaseAsync(DropDatabaseRequest, CallOptions)
public virtual AsyncUnaryCall<Empty> DropDatabaseAsync(DropDatabaseRequest request, CallOptions options)
Drops (aka deletes) a Cloud Spanner database.
Completed backups for the database will be retained according to their
expire_time
.
Note: Cloud Spanner might continue to accept requests for a few seconds
after the database has been deleted.
Parameters | |
---|---|
Name | Description |
request | DropDatabaseRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Empty> | The call object. |
DropDatabaseAsync(DropDatabaseRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Empty> DropDatabaseAsync(DropDatabaseRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Drops (aka deletes) a Cloud Spanner database.
Completed backups for the database will be retained according to their
expire_time
.
Note: Cloud Spanner might continue to accept requests for a few seconds
after the database has been deleted.
Parameters | |
---|---|
Name | Description |
request | DropDatabaseRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Empty> | The call object. |
GetBackup(GetBackupRequest, CallOptions)
public virtual Backup GetBackup(GetBackupRequest request, CallOptions options)
Gets metadata on a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | GetBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Backup | The response received from the server. |
GetBackup(GetBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Backup GetBackup(GetBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Gets metadata on a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | GetBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Backup | The response received from the server. |
GetBackupAsync(GetBackupRequest, CallOptions)
public virtual AsyncUnaryCall<Backup> GetBackupAsync(GetBackupRequest request, CallOptions options)
Gets metadata on a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | GetBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Backup> | The call object. |
GetBackupAsync(GetBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Backup> GetBackupAsync(GetBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Gets metadata on a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | GetBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Backup> | The call object. |
GetDatabase(GetDatabaseRequest, CallOptions)
public virtual Database GetDatabase(GetDatabaseRequest request, CallOptions options)
Gets the state of a Cloud Spanner database.
Parameters | |
---|---|
Name | Description |
request | GetDatabaseRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Database | The response received from the server. |
GetDatabase(GetDatabaseRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Database GetDatabase(GetDatabaseRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Gets the state of a Cloud Spanner database.
Parameters | |
---|---|
Name | Description |
request | GetDatabaseRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Database | The response received from the server. |
GetDatabaseAsync(GetDatabaseRequest, CallOptions)
public virtual AsyncUnaryCall<Database> GetDatabaseAsync(GetDatabaseRequest request, CallOptions options)
Gets the state of a Cloud Spanner database.
Parameters | |
---|---|
Name | Description |
request | GetDatabaseRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Database> | The call object. |
GetDatabaseAsync(GetDatabaseRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Database> GetDatabaseAsync(GetDatabaseRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Gets the state of a Cloud Spanner database.
Parameters | |
---|---|
Name | Description |
request | GetDatabaseRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Database> | The call object. |
GetDatabaseDdl(GetDatabaseDdlRequest, CallOptions)
public virtual GetDatabaseDdlResponse GetDatabaseDdl(GetDatabaseDdlRequest request, CallOptions options)
Returns the schema of a Cloud Spanner database as a list of formatted DDL statements. This method does not show pending schema updates, those may be queried using the [Operations][google.longrunning.Operations] API.
Parameters | |
---|---|
Name | Description |
request | GetDatabaseDdlRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
GetDatabaseDdlResponse | The response received from the server. |
GetDatabaseDdl(GetDatabaseDdlRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual GetDatabaseDdlResponse GetDatabaseDdl(GetDatabaseDdlRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Returns the schema of a Cloud Spanner database as a list of formatted DDL statements. This method does not show pending schema updates, those may be queried using the [Operations][google.longrunning.Operations] API.
Parameters | |
---|---|
Name | Description |
request | GetDatabaseDdlRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
GetDatabaseDdlResponse | The response received from the server. |
GetDatabaseDdlAsync(GetDatabaseDdlRequest, CallOptions)
public virtual AsyncUnaryCall<GetDatabaseDdlResponse> GetDatabaseDdlAsync(GetDatabaseDdlRequest request, CallOptions options)
Returns the schema of a Cloud Spanner database as a list of formatted DDL statements. This method does not show pending schema updates, those may be queried using the [Operations][google.longrunning.Operations] API.
Parameters | |
---|---|
Name | Description |
request | GetDatabaseDdlRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<GetDatabaseDdlResponse> | The call object. |
GetDatabaseDdlAsync(GetDatabaseDdlRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<GetDatabaseDdlResponse> GetDatabaseDdlAsync(GetDatabaseDdlRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Returns the schema of a Cloud Spanner database as a list of formatted DDL statements. This method does not show pending schema updates, those may be queried using the [Operations][google.longrunning.Operations] API.
Parameters | |
---|---|
Name | Description |
request | GetDatabaseDdlRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<GetDatabaseDdlResponse> | The call object. |
GetIamPolicy(GetIamPolicyRequest, CallOptions)
public virtual Policy GetIamPolicy(GetIamPolicyRequest request, CallOptions options)
Gets the access control policy for a database or backup resource. Returns an empty policy if a database or backup exists but does not have a policy set.
Authorization requires spanner.databases.getIamPolicy
permission on
[resource][google.iam.v1.GetIamPolicyRequest.resource].
For backups, authorization requires spanner.backups.getIamPolicy
permission on [resource][google.iam.v1.GetIamPolicyRequest.resource].
Parameters | |
---|---|
Name | Description |
request | GetIamPolicyRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Policy | The response received from the server. |
GetIamPolicy(GetIamPolicyRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Policy GetIamPolicy(GetIamPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Gets the access control policy for a database or backup resource. Returns an empty policy if a database or backup exists but does not have a policy set.
Authorization requires spanner.databases.getIamPolicy
permission on
[resource][google.iam.v1.GetIamPolicyRequest.resource].
For backups, authorization requires spanner.backups.getIamPolicy
permission on [resource][google.iam.v1.GetIamPolicyRequest.resource].
Parameters | |
---|---|
Name | Description |
request | GetIamPolicyRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Policy | The response received from the server. |
GetIamPolicyAsync(GetIamPolicyRequest, CallOptions)
public virtual AsyncUnaryCall<Policy> GetIamPolicyAsync(GetIamPolicyRequest request, CallOptions options)
Gets the access control policy for a database or backup resource. Returns an empty policy if a database or backup exists but does not have a policy set.
Authorization requires spanner.databases.getIamPolicy
permission on
[resource][google.iam.v1.GetIamPolicyRequest.resource].
For backups, authorization requires spanner.backups.getIamPolicy
permission on [resource][google.iam.v1.GetIamPolicyRequest.resource].
Parameters | |
---|---|
Name | Description |
request | GetIamPolicyRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Policy> | The call object. |
GetIamPolicyAsync(GetIamPolicyRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Policy> GetIamPolicyAsync(GetIamPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Gets the access control policy for a database or backup resource. Returns an empty policy if a database or backup exists but does not have a policy set.
Authorization requires spanner.databases.getIamPolicy
permission on
[resource][google.iam.v1.GetIamPolicyRequest.resource].
For backups, authorization requires spanner.backups.getIamPolicy
permission on [resource][google.iam.v1.GetIamPolicyRequest.resource].
Parameters | |
---|---|
Name | Description |
request | GetIamPolicyRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Policy> | The call object. |
ListBackupOperations(ListBackupOperationsRequest, CallOptions)
public virtual ListBackupOperationsResponse ListBackupOperations(ListBackupOperationsRequest request, CallOptions options)
Lists the backup [long-running operations][google.longrunning.Operation] in
the given instance. A backup operation has a name of the form
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation>
.
The long-running operation
[metadata][google.longrunning.Operation.metadata] field type
metadata.type_url
describes the type of the metadata. Operations returned
include those that have completed/failed/canceled within the last 7 days,
and pending operations. Operations returned are ordered by
operation.metadata.value.progress.start_time
in descending order starting
from the most recently started operation.
Parameters | |
---|---|
Name | Description |
request | ListBackupOperationsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
ListBackupOperationsResponse | The response received from the server. |
ListBackupOperations(ListBackupOperationsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual ListBackupOperationsResponse ListBackupOperations(ListBackupOperationsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Lists the backup [long-running operations][google.longrunning.Operation] in
the given instance. A backup operation has a name of the form
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation>
.
The long-running operation
[metadata][google.longrunning.Operation.metadata] field type
metadata.type_url
describes the type of the metadata. Operations returned
include those that have completed/failed/canceled within the last 7 days,
and pending operations. Operations returned are ordered by
operation.metadata.value.progress.start_time
in descending order starting
from the most recently started operation.
Parameters | |
---|---|
Name | Description |
request | ListBackupOperationsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
ListBackupOperationsResponse | The response received from the server. |
ListBackupOperationsAsync(ListBackupOperationsRequest, CallOptions)
public virtual AsyncUnaryCall<ListBackupOperationsResponse> ListBackupOperationsAsync(ListBackupOperationsRequest request, CallOptions options)
Lists the backup [long-running operations][google.longrunning.Operation] in
the given instance. A backup operation has a name of the form
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation>
.
The long-running operation
[metadata][google.longrunning.Operation.metadata] field type
metadata.type_url
describes the type of the metadata. Operations returned
include those that have completed/failed/canceled within the last 7 days,
and pending operations. Operations returned are ordered by
operation.metadata.value.progress.start_time
in descending order starting
from the most recently started operation.
Parameters | |
---|---|
Name | Description |
request | ListBackupOperationsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ListBackupOperationsResponse> | The call object. |
ListBackupOperationsAsync(ListBackupOperationsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<ListBackupOperationsResponse> ListBackupOperationsAsync(ListBackupOperationsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Lists the backup [long-running operations][google.longrunning.Operation] in
the given instance. A backup operation has a name of the form
projects/<project>/instances/<instance>/backups/<backup>/operations/<operation>
.
The long-running operation
[metadata][google.longrunning.Operation.metadata] field type
metadata.type_url
describes the type of the metadata. Operations returned
include those that have completed/failed/canceled within the last 7 days,
and pending operations. Operations returned are ordered by
operation.metadata.value.progress.start_time
in descending order starting
from the most recently started operation.
Parameters | |
---|---|
Name | Description |
request | ListBackupOperationsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ListBackupOperationsResponse> | The call object. |
ListBackups(ListBackupsRequest, CallOptions)
public virtual ListBackupsResponse ListBackups(ListBackupsRequest request, CallOptions options)
Lists completed and pending backups.
Backups returned are ordered by create_time
in descending order,
starting from the most recent create_time
.
Parameters | |
---|---|
Name | Description |
request | ListBackupsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
ListBackupsResponse | The response received from the server. |
ListBackups(ListBackupsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual ListBackupsResponse ListBackups(ListBackupsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Lists completed and pending backups.
Backups returned are ordered by create_time
in descending order,
starting from the most recent create_time
.
Parameters | |
---|---|
Name | Description |
request | ListBackupsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
ListBackupsResponse | The response received from the server. |
ListBackupsAsync(ListBackupsRequest, CallOptions)
public virtual AsyncUnaryCall<ListBackupsResponse> ListBackupsAsync(ListBackupsRequest request, CallOptions options)
Lists completed and pending backups.
Backups returned are ordered by create_time
in descending order,
starting from the most recent create_time
.
Parameters | |
---|---|
Name | Description |
request | ListBackupsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ListBackupsResponse> | The call object. |
ListBackupsAsync(ListBackupsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<ListBackupsResponse> ListBackupsAsync(ListBackupsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Lists completed and pending backups.
Backups returned are ordered by create_time
in descending order,
starting from the most recent create_time
.
Parameters | |
---|---|
Name | Description |
request | ListBackupsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ListBackupsResponse> | The call object. |
ListDatabaseOperations(ListDatabaseOperationsRequest, CallOptions)
public virtual ListDatabaseOperationsResponse ListDatabaseOperations(ListDatabaseOperationsRequest request, CallOptions options)
Lists database [longrunning-operations][google.longrunning.Operation].
A database operation has a name of the form
projects/<project>/instances/<instance>/databases/<database>/operations/<operation>
.
The long-running operation
[metadata][google.longrunning.Operation.metadata] field type
metadata.type_url
describes the type of the metadata. Operations returned
include those that have completed/failed/canceled within the last 7 days,
and pending operations.
Parameters | |
---|---|
Name | Description |
request | ListDatabaseOperationsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
ListDatabaseOperationsResponse | The response received from the server. |
ListDatabaseOperations(ListDatabaseOperationsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual ListDatabaseOperationsResponse ListDatabaseOperations(ListDatabaseOperationsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Lists database [longrunning-operations][google.longrunning.Operation].
A database operation has a name of the form
projects/<project>/instances/<instance>/databases/<database>/operations/<operation>
.
The long-running operation
[metadata][google.longrunning.Operation.metadata] field type
metadata.type_url
describes the type of the metadata. Operations returned
include those that have completed/failed/canceled within the last 7 days,
and pending operations.
Parameters | |
---|---|
Name | Description |
request | ListDatabaseOperationsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
ListDatabaseOperationsResponse | The response received from the server. |
ListDatabaseOperationsAsync(ListDatabaseOperationsRequest, CallOptions)
public virtual AsyncUnaryCall<ListDatabaseOperationsResponse> ListDatabaseOperationsAsync(ListDatabaseOperationsRequest request, CallOptions options)
Lists database [longrunning-operations][google.longrunning.Operation].
A database operation has a name of the form
projects/<project>/instances/<instance>/databases/<database>/operations/<operation>
.
The long-running operation
[metadata][google.longrunning.Operation.metadata] field type
metadata.type_url
describes the type of the metadata. Operations returned
include those that have completed/failed/canceled within the last 7 days,
and pending operations.
Parameters | |
---|---|
Name | Description |
request | ListDatabaseOperationsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ListDatabaseOperationsResponse> | The call object. |
ListDatabaseOperationsAsync(ListDatabaseOperationsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<ListDatabaseOperationsResponse> ListDatabaseOperationsAsync(ListDatabaseOperationsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Lists database [longrunning-operations][google.longrunning.Operation].
A database operation has a name of the form
projects/<project>/instances/<instance>/databases/<database>/operations/<operation>
.
The long-running operation
[metadata][google.longrunning.Operation.metadata] field type
metadata.type_url
describes the type of the metadata. Operations returned
include those that have completed/failed/canceled within the last 7 days,
and pending operations.
Parameters | |
---|---|
Name | Description |
request | ListDatabaseOperationsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ListDatabaseOperationsResponse> | The call object. |
ListDatabases(ListDatabasesRequest, CallOptions)
public virtual ListDatabasesResponse ListDatabases(ListDatabasesRequest request, CallOptions options)
Lists Cloud Spanner databases.
Parameters | |
---|---|
Name | Description |
request | ListDatabasesRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
ListDatabasesResponse | The response received from the server. |
ListDatabases(ListDatabasesRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual ListDatabasesResponse ListDatabases(ListDatabasesRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Lists Cloud Spanner databases.
Parameters | |
---|---|
Name | Description |
request | ListDatabasesRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
ListDatabasesResponse | The response received from the server. |
ListDatabasesAsync(ListDatabasesRequest, CallOptions)
public virtual AsyncUnaryCall<ListDatabasesResponse> ListDatabasesAsync(ListDatabasesRequest request, CallOptions options)
Lists Cloud Spanner databases.
Parameters | |
---|---|
Name | Description |
request | ListDatabasesRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ListDatabasesResponse> | The call object. |
ListDatabasesAsync(ListDatabasesRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<ListDatabasesResponse> ListDatabasesAsync(ListDatabasesRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Lists Cloud Spanner databases.
Parameters | |
---|---|
Name | Description |
request | ListDatabasesRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<ListDatabasesResponse> | The call object. |
NewInstance(ClientBase.ClientBaseConfiguration)
protected override DatabaseAdmin.DatabaseAdminClient NewInstance(ClientBase.ClientBaseConfiguration configuration)
Creates a new instance of client from given ClientBaseConfiguration
.
Parameter | |
---|---|
Name | Description |
configuration | ClientBase.ClientBaseConfiguration |
Returns | |
---|---|
Type | Description |
DatabaseAdmin.DatabaseAdminClient |
RestoreDatabase(RestoreDatabaseRequest, CallOptions)
public virtual Operation RestoreDatabase(RestoreDatabaseRequest request, CallOptions options)
Create a new database by restoring from a completed backup. The new
database must be in the same project and in an instance with the same
instance configuration as the instance containing
the backup. The returned database [long-running
operation][google.longrunning.Operation] has a name of the format
projects/<project>/instances/<instance>/databases/<database>/operations/<operation_id>
,
and can be used to track the progress of the operation, and to cancel it.
The [metadata][google.longrunning.Operation.metadata] field type is
[RestoreDatabaseMetadata][google.spanner.admin.database.v1.RestoreDatabaseMetadata].
The [response][google.longrunning.Operation.response] type
is [Database][google.spanner.admin.database.v1.Database], if
successful. Cancelling the returned operation will stop the restore and
delete the database.
There can be only one database being restored into an instance at a time.
Once the restore operation completes, a new restore operation can be
initiated, without waiting for the optimize operation associated with the
first restore to complete.
Parameters | |
---|---|
Name | Description |
request | RestoreDatabaseRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
RestoreDatabase(RestoreDatabaseRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation RestoreDatabase(RestoreDatabaseRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Create a new database by restoring from a completed backup. The new
database must be in the same project and in an instance with the same
instance configuration as the instance containing
the backup. The returned database [long-running
operation][google.longrunning.Operation] has a name of the format
projects/<project>/instances/<instance>/databases/<database>/operations/<operation_id>
,
and can be used to track the progress of the operation, and to cancel it.
The [metadata][google.longrunning.Operation.metadata] field type is
[RestoreDatabaseMetadata][google.spanner.admin.database.v1.RestoreDatabaseMetadata].
The [response][google.longrunning.Operation.response] type
is [Database][google.spanner.admin.database.v1.Database], if
successful. Cancelling the returned operation will stop the restore and
delete the database.
There can be only one database being restored into an instance at a time.
Once the restore operation completes, a new restore operation can be
initiated, without waiting for the optimize operation associated with the
first restore to complete.
Parameters | |
---|---|
Name | Description |
request | RestoreDatabaseRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
RestoreDatabaseAsync(RestoreDatabaseRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> RestoreDatabaseAsync(RestoreDatabaseRequest request, CallOptions options)
Create a new database by restoring from a completed backup. The new
database must be in the same project and in an instance with the same
instance configuration as the instance containing
the backup. The returned database [long-running
operation][google.longrunning.Operation] has a name of the format
projects/<project>/instances/<instance>/databases/<database>/operations/<operation_id>
,
and can be used to track the progress of the operation, and to cancel it.
The [metadata][google.longrunning.Operation.metadata] field type is
[RestoreDatabaseMetadata][google.spanner.admin.database.v1.RestoreDatabaseMetadata].
The [response][google.longrunning.Operation.response] type
is [Database][google.spanner.admin.database.v1.Database], if
successful. Cancelling the returned operation will stop the restore and
delete the database.
There can be only one database being restored into an instance at a time.
Once the restore operation completes, a new restore operation can be
initiated, without waiting for the optimize operation associated with the
first restore to complete.
Parameters | |
---|---|
Name | Description |
request | RestoreDatabaseRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
RestoreDatabaseAsync(RestoreDatabaseRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> RestoreDatabaseAsync(RestoreDatabaseRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Create a new database by restoring from a completed backup. The new
database must be in the same project and in an instance with the same
instance configuration as the instance containing
the backup. The returned database [long-running
operation][google.longrunning.Operation] has a name of the format
projects/<project>/instances/<instance>/databases/<database>/operations/<operation_id>
,
and can be used to track the progress of the operation, and to cancel it.
The [metadata][google.longrunning.Operation.metadata] field type is
[RestoreDatabaseMetadata][google.spanner.admin.database.v1.RestoreDatabaseMetadata].
The [response][google.longrunning.Operation.response] type
is [Database][google.spanner.admin.database.v1.Database], if
successful. Cancelling the returned operation will stop the restore and
delete the database.
There can be only one database being restored into an instance at a time.
Once the restore operation completes, a new restore operation can be
initiated, without waiting for the optimize operation associated with the
first restore to complete.
Parameters | |
---|---|
Name | Description |
request | RestoreDatabaseRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
SetIamPolicy(SetIamPolicyRequest, CallOptions)
public virtual Policy SetIamPolicy(SetIamPolicyRequest request, CallOptions options)
Sets the access control policy on a database or backup resource. Replaces any existing policy.
Authorization requires spanner.databases.setIamPolicy
permission on [resource][google.iam.v1.SetIamPolicyRequest.resource].
For backups, authorization requires spanner.backups.setIamPolicy
permission on [resource][google.iam.v1.SetIamPolicyRequest.resource].
Parameters | |
---|---|
Name | Description |
request | SetIamPolicyRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Policy | The response received from the server. |
SetIamPolicy(SetIamPolicyRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Policy SetIamPolicy(SetIamPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Sets the access control policy on a database or backup resource. Replaces any existing policy.
Authorization requires spanner.databases.setIamPolicy
permission on [resource][google.iam.v1.SetIamPolicyRequest.resource].
For backups, authorization requires spanner.backups.setIamPolicy
permission on [resource][google.iam.v1.SetIamPolicyRequest.resource].
Parameters | |
---|---|
Name | Description |
request | SetIamPolicyRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Policy | The response received from the server. |
SetIamPolicyAsync(SetIamPolicyRequest, CallOptions)
public virtual AsyncUnaryCall<Policy> SetIamPolicyAsync(SetIamPolicyRequest request, CallOptions options)
Sets the access control policy on a database or backup resource. Replaces any existing policy.
Authorization requires spanner.databases.setIamPolicy
permission on [resource][google.iam.v1.SetIamPolicyRequest.resource].
For backups, authorization requires spanner.backups.setIamPolicy
permission on [resource][google.iam.v1.SetIamPolicyRequest.resource].
Parameters | |
---|---|
Name | Description |
request | SetIamPolicyRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Policy> | The call object. |
SetIamPolicyAsync(SetIamPolicyRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Policy> SetIamPolicyAsync(SetIamPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Sets the access control policy on a database or backup resource. Replaces any existing policy.
Authorization requires spanner.databases.setIamPolicy
permission on [resource][google.iam.v1.SetIamPolicyRequest.resource].
For backups, authorization requires spanner.backups.setIamPolicy
permission on [resource][google.iam.v1.SetIamPolicyRequest.resource].
Parameters | |
---|---|
Name | Description |
request | SetIamPolicyRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Policy> | The call object. |
TestIamPermissions(TestIamPermissionsRequest, CallOptions)
public virtual TestIamPermissionsResponse TestIamPermissions(TestIamPermissionsRequest request, CallOptions options)
Returns permissions that the caller has on the specified database or backup resource.
Attempting this RPC on a non-existent Cloud Spanner database will
result in a NOT_FOUND error if the user has
spanner.databases.list
permission on the containing Cloud
Spanner instance. Otherwise returns an empty set of permissions.
Calling this method on a backup that does not exist will
result in a NOT_FOUND error if the user has
spanner.backups.list
permission on the containing instance.
Parameters | |
---|---|
Name | Description |
request | TestIamPermissionsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
TestIamPermissionsResponse | The response received from the server. |
TestIamPermissions(TestIamPermissionsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual TestIamPermissionsResponse TestIamPermissions(TestIamPermissionsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Returns permissions that the caller has on the specified database or backup resource.
Attempting this RPC on a non-existent Cloud Spanner database will
result in a NOT_FOUND error if the user has
spanner.databases.list
permission on the containing Cloud
Spanner instance. Otherwise returns an empty set of permissions.
Calling this method on a backup that does not exist will
result in a NOT_FOUND error if the user has
spanner.backups.list
permission on the containing instance.
Parameters | |
---|---|
Name | Description |
request | TestIamPermissionsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
TestIamPermissionsResponse | The response received from the server. |
TestIamPermissionsAsync(TestIamPermissionsRequest, CallOptions)
public virtual AsyncUnaryCall<TestIamPermissionsResponse> TestIamPermissionsAsync(TestIamPermissionsRequest request, CallOptions options)
Returns permissions that the caller has on the specified database or backup resource.
Attempting this RPC on a non-existent Cloud Spanner database will
result in a NOT_FOUND error if the user has
spanner.databases.list
permission on the containing Cloud
Spanner instance. Otherwise returns an empty set of permissions.
Calling this method on a backup that does not exist will
result in a NOT_FOUND error if the user has
spanner.backups.list
permission on the containing instance.
Parameters | |
---|---|
Name | Description |
request | TestIamPermissionsRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<TestIamPermissionsResponse> | The call object. |
TestIamPermissionsAsync(TestIamPermissionsRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<TestIamPermissionsResponse> TestIamPermissionsAsync(TestIamPermissionsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Returns permissions that the caller has on the specified database or backup resource.
Attempting this RPC on a non-existent Cloud Spanner database will
result in a NOT_FOUND error if the user has
spanner.databases.list
permission on the containing Cloud
Spanner instance. Otherwise returns an empty set of permissions.
Calling this method on a backup that does not exist will
result in a NOT_FOUND error if the user has
spanner.backups.list
permission on the containing instance.
Parameters | |
---|---|
Name | Description |
request | TestIamPermissionsRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<TestIamPermissionsResponse> | The call object. |
UpdateBackup(UpdateBackupRequest, CallOptions)
public virtual Backup UpdateBackup(UpdateBackupRequest request, CallOptions options)
Updates a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | UpdateBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Backup | The response received from the server. |
UpdateBackup(UpdateBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Backup UpdateBackup(UpdateBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Updates a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | UpdateBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Backup | The response received from the server. |
UpdateBackupAsync(UpdateBackupRequest, CallOptions)
public virtual AsyncUnaryCall<Backup> UpdateBackupAsync(UpdateBackupRequest request, CallOptions options)
Updates a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | UpdateBackupRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Backup> | The call object. |
UpdateBackupAsync(UpdateBackupRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Backup> UpdateBackupAsync(UpdateBackupRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Updates a pending or completed [Backup][google.spanner.admin.database.v1.Backup].
Parameters | |
---|---|
Name | Description |
request | UpdateBackupRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Backup> | The call object. |
UpdateDatabaseDdl(UpdateDatabaseDdlRequest, CallOptions)
public virtual Operation UpdateDatabaseDdl(UpdateDatabaseDdlRequest request, CallOptions options)
Updates the schema of a Cloud Spanner database by
creating/altering/dropping tables, columns, indexes, etc. The returned
[long-running operation][google.longrunning.Operation] will have a name of
the format <database_name>/operations/<operation_id>
and can be used to
track execution of the schema change(s). The
[metadata][google.longrunning.Operation.metadata] field type is
[UpdateDatabaseDdlMetadata][google.spanner.admin.database.v1.UpdateDatabaseDdlMetadata]. The operation has no response.
Parameters | |
---|---|
Name | Description |
request | UpdateDatabaseDdlRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
UpdateDatabaseDdl(UpdateDatabaseDdlRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual Operation UpdateDatabaseDdl(UpdateDatabaseDdlRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Updates the schema of a Cloud Spanner database by
creating/altering/dropping tables, columns, indexes, etc. The returned
[long-running operation][google.longrunning.Operation] will have a name of
the format <database_name>/operations/<operation_id>
and can be used to
track execution of the schema change(s). The
[metadata][google.longrunning.Operation.metadata] field type is
[UpdateDatabaseDdlMetadata][google.spanner.admin.database.v1.UpdateDatabaseDdlMetadata]. The operation has no response.
Parameters | |
---|---|
Name | Description |
request | UpdateDatabaseDdlRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
Operation | The response received from the server. |
UpdateDatabaseDdlAsync(UpdateDatabaseDdlRequest, CallOptions)
public virtual AsyncUnaryCall<Operation> UpdateDatabaseDdlAsync(UpdateDatabaseDdlRequest request, CallOptions options)
Updates the schema of a Cloud Spanner database by
creating/altering/dropping tables, columns, indexes, etc. The returned
[long-running operation][google.longrunning.Operation] will have a name of
the format <database_name>/operations/<operation_id>
and can be used to
track execution of the schema change(s). The
[metadata][google.longrunning.Operation.metadata] field type is
[UpdateDatabaseDdlMetadata][google.spanner.admin.database.v1.UpdateDatabaseDdlMetadata]. The operation has no response.
Parameters | |
---|---|
Name | Description |
request | UpdateDatabaseDdlRequest The request to send to the server. |
options | CallOptions The options for the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |
UpdateDatabaseDdlAsync(UpdateDatabaseDdlRequest, Metadata, Nullable<DateTime>, CancellationToken)
public virtual AsyncUnaryCall<Operation> UpdateDatabaseDdlAsync(UpdateDatabaseDdlRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Updates the schema of a Cloud Spanner database by
creating/altering/dropping tables, columns, indexes, etc. The returned
[long-running operation][google.longrunning.Operation] will have a name of
the format <database_name>/operations/<operation_id>
and can be used to
track execution of the schema change(s). The
[metadata][google.longrunning.Operation.metadata] field type is
[UpdateDatabaseDdlMetadata][google.spanner.admin.database.v1.UpdateDatabaseDdlMetadata]. The operation has no response.
Parameters | |
---|---|
Name | Description |
request | UpdateDatabaseDdlRequest The request to send to the server. |
headers | Metadata The initial metadata to send with the call. This parameter is optional. |
deadline | Nullable<DateTime> An optional deadline for the call. The call will be cancelled if deadline is hit. |
cancellationToken | CancellationToken An optional token for canceling the call. |
Returns | |
---|---|
Type | Description |
AsyncUnaryCall<Operation> | The call object. |