Show / Hide Table of Contents

Class ProjectsResource.InstancesResource.BackupsResource

The "backups" collection of methods.

Inheritance
object
ProjectsResource.InstancesResource.BackupsResource
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Google.Apis.Spanner.v1
Assembly: Google.Apis.Spanner.v1.dll
Syntax
public class ProjectsResource.InstancesResource.BackupsResource

Constructors

BackupsResource(IClientService)

Constructs a new resource.

Declaration
public BackupsResource(IClientService service)
Parameters
Type Name Description
IClientService service

Properties

Operations

Gets the Operations resource.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.OperationsResource Operations { get; }
Property Value
Type Description
ProjectsResource.InstancesResource.BackupsResource.OperationsResource

Methods

Copy(CopyBackupRequest, string)

Starts copying a Cloud Spanner Backup. The returned backup long-running operation will have a name of the format projects//instances//backups//operations/ and can be used to track copying of the backup. The operation is associated with the destination backup. The metadata field type is CopyBackupMetadata. The response field type is Backup, if successful. Cancelling the returned operation will stop the copying and delete the destination backup. Concurrent CopyBackup requests can run on the same source backup.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.CopyRequest Copy(CopyBackupRequest body, string parent)
Parameters
Type Name Description
CopyBackupRequest body

The body of the request.

string parent

Required. The name of the destination instance that will contain the backup copy. Values are of the form: projects//instances/.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.CopyRequest

Create(Backup, string)

Starts creating a new Cloud Spanner Backup. The returned backup long-running operation will have a name of the format projects//instances//backups//operations/ and can be used to track creation of the backup. The metadata field type is CreateBackupMetadata. The response field type is 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.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.CreateRequest Create(Backup body, string parent)
Parameters
Type Name Description
Backup body

The body of the request.

string parent

Required. The name of the instance in which the backup will be created. This must be the same instance that contains the database the backup will be created from. The backup will be stored in the location(s) specified in the instance configuration of this instance. Values are of the form projects//instances/.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.CreateRequest

Delete(string)

Deletes a pending or completed Backup.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.DeleteRequest Delete(string name)
Parameters
Type Name Description
string name

Required. Name of the backup to delete. Values are of the form projects//instances//backups/.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.DeleteRequest

Get(string)

Gets metadata on a pending or completed Backup.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.GetRequest Get(string name)
Parameters
Type Name Description
string name

Required. Name of the backup. Values are of the form projects//instances//backups/.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.GetRequest

GetIamPolicy(GetIamPolicyRequest, string)

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. For backups, authorization requires spanner.backups.getIamPolicy permission on resource. For backup schedules, authorization requires spanner.backupSchedules.getIamPolicy permission on resource.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.GetIamPolicyRequest GetIamPolicy(GetIamPolicyRequest body, string resource)
Parameters
Type Name Description
GetIamPolicyRequest body

The body of the request.

string resource

REQUIRED: The Cloud Spanner resource for which the policy is being retrieved. The format is projects//instances/ for instance resources and projects//instances//databases/ for database resources.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.GetIamPolicyRequest

List(string)

Lists completed and pending backups. Backups returned are ordered by create_time in descending order, starting from the most recent create_time.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.ListRequest List(string parent)
Parameters
Type Name Description
string parent

Required. The instance to list backups from. Values are of the form projects//instances/.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.ListRequest

Patch(Backup, string)

Updates a pending or completed Backup.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.PatchRequest Patch(Backup body, string name)
Parameters
Type Name Description
Backup body

The body of the request.

string name

Output only for the CreateBackup operation. Required for the UpdateBackup operation. A globally unique identifier for the backup which cannot be changed. Values are of the form projects//instances//backups/a-z*[a-z0-9] The final segment of the name must be between 2 and 60 characters in length. The backup is stored in the location(s) specified in the instance configuration of the instance containing the backup, identified by the prefix of the backup name of the form projects//instances/.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.PatchRequest

SetIamPolicy(SetIamPolicyRequest, string)

Sets the access control policy on a database or backup resource. Replaces any existing policy. Authorization requires spanner.databases.setIamPolicy permission on resource. For backups, authorization requires spanner.backups.setIamPolicy permission on resource. For backup schedules, authorization requires spanner.backupSchedules.setIamPolicy permission on resource.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.SetIamPolicyRequest SetIamPolicy(SetIamPolicyRequest body, string resource)
Parameters
Type Name Description
SetIamPolicyRequest body

The body of the request.

string resource

REQUIRED: The Cloud Spanner resource for which the policy is being set. The format is projects//instances/ for instance resources and projects//instances//databases/ for databases resources.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.SetIamPolicyRequest

TestIamPermissions(TestIamPermissionsRequest, string)

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. Calling this method on a backup schedule that does not exist will result in a NOT_FOUND error if the user has spanner.backupSchedules.list permission on the containing database.

Declaration
public virtual ProjectsResource.InstancesResource.BackupsResource.TestIamPermissionsRequest TestIamPermissions(TestIamPermissionsRequest body, string resource)
Parameters
Type Name Description
TestIamPermissionsRequest body

The body of the request.

string resource

REQUIRED: The Cloud Spanner resource for which permissions are being tested. The format is projects//instances/ for instance resources and projects//instances//databases/ for database resources.

Returns
Type Description
ProjectsResource.InstancesResource.BackupsResource.TestIamPermissionsRequest
In this article
Back to top Generated by DocFX