Class ProjectsResource.InstancesResource.DatabasesResource.RestoreRequest
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 has a name of the format
projects//instances//databases//operations/
, and can be used to track the progress of the
operation, and to cancel it. The metadata field type is RestoreDatabaseMetadata. The response type
is 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.
Inheritance
Inherited Members
Namespace: Google.Apis.Spanner.v1
Assembly: Google.Apis.Spanner.v1.dll
Syntax
public class ProjectsResource.InstancesResource.DatabasesResource.RestoreRequest : SpannerBaseServiceRequest<Operation>, IClientServiceRequest<Operation>, IClientServiceRequest
Constructors
RestoreRequest(IClientService, RestoreDatabaseRequest, string)
Constructs a new Restore request.
Declaration
public RestoreRequest(IClientService service, RestoreDatabaseRequest body, string parent)
Parameters
Type | Name | Description |
---|---|---|
IClientService | service | |
RestoreDatabaseRequest | body | |
string | parent |
Properties
HttpMethod
Gets the HTTP method.
Declaration
public override string HttpMethod { get; }
Property Value
Type | Description |
---|---|
string |
Overrides
MethodName
Gets the method name.
Declaration
public override string MethodName { get; }
Property Value
Type | Description |
---|---|
string |
Overrides
Parent
Required. The name of the instance in which to create the restored database. This instance must
be in the same project and have the same instance configuration as the instance containing the
source backup. Values are of the form projects//instances/
.
Declaration
[RequestParameter("parent", RequestParameterType.Path)]
public virtual string Parent { get; }
Property Value
Type | Description |
---|---|
string |
RestPath
Gets the REST path.
Declaration
public override string RestPath { get; }
Property Value
Type | Description |
---|---|
string |
Overrides
Methods
GetBody()
Returns the body of the request.
Declaration
protected override object GetBody()
Returns
Type | Description |
---|---|
object |
Overrides
InitParameters()
Initializes Restore parameter list.
Declaration
protected override void InitParameters()