public abstract class NotebookServiceClientReference documentation and code samples for the Notebooks v2 API class NotebookServiceClient.
NotebookService client wrapper, for convenient use.
Derived Types
Namespace
Google.Cloud.Notebooks.V2Assembly
Google.Cloud.Notebooks.V2.dll
Remarks
API v2 service for Workbench Notebooks Instances.
Properties
CreateInstanceOperationsClient
public virtual OperationsClient CreateInstanceOperationsClient { get; }The long-running operations client for CreateInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
DefaultEndpoint
public static string DefaultEndpoint { get; }The default endpoint for the NotebookService service, which is a host of "notebooks.googleapis.com" and a port of 443.
| Property Value | |
|---|---|
| Type | Description |
string |
|
DefaultScopes
public static IReadOnlyList<string> DefaultScopes { get; }The default NotebookService scopes.
| Property Value | |
|---|---|
| Type | Description |
IReadOnlyListstring |
|
The default NotebookService scopes are:
DeleteInstanceOperationsClient
public virtual OperationsClient DeleteInstanceOperationsClient { get; }The long-running operations client for DeleteInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
DiagnoseInstanceOperationsClient
public virtual OperationsClient DiagnoseInstanceOperationsClient { get; }The long-running operations client for DiagnoseInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
GrpcClient
public virtual NotebookService.NotebookServiceClient GrpcClient { get; }The underlying gRPC NotebookService client
| Property Value | |
|---|---|
| Type | Description |
NotebookServiceNotebookServiceClient |
|
IAMPolicyClient
public virtual IAMPolicyClient IAMPolicyClient { get; }The IAMPolicyClient associated with this client.
| Property Value | |
|---|---|
| Type | Description |
IAMPolicyClient |
|
LocationsClient
public virtual LocationsClient LocationsClient { get; }The LocationsClient associated with this client.
| Property Value | |
|---|---|
| Type | Description |
LocationsClient |
|
ResetInstanceOperationsClient
public virtual OperationsClient ResetInstanceOperationsClient { get; }The long-running operations client for ResetInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
RollbackInstanceOperationsClient
public virtual OperationsClient RollbackInstanceOperationsClient { get; }The long-running operations client for RollbackInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
ServiceMetadata
public static ServiceMetadata ServiceMetadata { get; }The service metadata associated with this client type.
| Property Value | |
|---|---|
| Type | Description |
ServiceMetadata |
|
StartInstanceOperationsClient
public virtual OperationsClient StartInstanceOperationsClient { get; }The long-running operations client for StartInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
StopInstanceOperationsClient
public virtual OperationsClient StopInstanceOperationsClient { get; }The long-running operations client for StopInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
UpdateInstanceOperationsClient
public virtual OperationsClient UpdateInstanceOperationsClient { get; }The long-running operations client for UpdateInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
UpgradeInstanceOperationsClient
public virtual OperationsClient UpgradeInstanceOperationsClient { get; }The long-running operations client for UpgradeInstance.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
Methods
CheckInstanceUpgradability(CheckInstanceUpgradabilityRequest, CallSettings)
public virtual CheckInstanceUpgradabilityResponse CheckInstanceUpgradability(CheckInstanceUpgradabilityRequest request, CallSettings callSettings = null)Checks whether a notebook instance is upgradable.
| Parameters | |
|---|---|
| Name | Description |
request |
CheckInstanceUpgradabilityRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
CheckInstanceUpgradabilityResponse |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
CheckInstanceUpgradabilityRequest request = new CheckInstanceUpgradabilityRequest
{
NotebookInstance = "",
};
// Make the request
CheckInstanceUpgradabilityResponse response = notebookServiceClient.CheckInstanceUpgradability(request);
CheckInstanceUpgradabilityAsync(CheckInstanceUpgradabilityRequest, CallSettings)
public virtual Task<CheckInstanceUpgradabilityResponse> CheckInstanceUpgradabilityAsync(CheckInstanceUpgradabilityRequest request, CallSettings callSettings = null)Checks whether a notebook instance is upgradable.
| Parameters | |
|---|---|
| Name | Description |
request |
CheckInstanceUpgradabilityRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskCheckInstanceUpgradabilityResponse |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
CheckInstanceUpgradabilityRequest request = new CheckInstanceUpgradabilityRequest
{
NotebookInstance = "",
};
// Make the request
CheckInstanceUpgradabilityResponse response = await notebookServiceClient.CheckInstanceUpgradabilityAsync(request);
CheckInstanceUpgradabilityAsync(CheckInstanceUpgradabilityRequest, CancellationToken)
public virtual Task<CheckInstanceUpgradabilityResponse> CheckInstanceUpgradabilityAsync(CheckInstanceUpgradabilityRequest request, CancellationToken cancellationToken)Checks whether a notebook instance is upgradable.
| Parameters | |
|---|---|
| Name | Description |
request |
CheckInstanceUpgradabilityRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskCheckInstanceUpgradabilityResponse |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
CheckInstanceUpgradabilityRequest request = new CheckInstanceUpgradabilityRequest
{
NotebookInstance = "",
};
// Make the request
CheckInstanceUpgradabilityResponse response = await notebookServiceClient.CheckInstanceUpgradabilityAsync(request);
Create()
public static NotebookServiceClient Create()Synchronously creates a NotebookServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use NotebookServiceClientBuilder.
| Returns | |
|---|---|
| Type | Description |
NotebookServiceClient |
The created NotebookServiceClient. |
CreateAsync(CancellationToken)
public static Task<NotebookServiceClient> CreateAsync(CancellationToken cancellationToken = default)Asynchronously creates a NotebookServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use NotebookServiceClientBuilder.
| Parameter | |
|---|---|
| Name | Description |
cancellationToken |
CancellationTokenThe CancellationToken to use while creating the client. |
| Returns | |
|---|---|
| Type | Description |
TaskNotebookServiceClient |
The task representing the created NotebookServiceClient. |
CreateInstance(LocationName, Instance, string, CallSettings)
public virtual Operation<Instance, OperationMetadata> CreateInstance(LocationName parent, Instance instance, string instanceId, CallSettings callSettings = null)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Format:
|
instance |
InstanceRequired. The instance to be created. |
instanceId |
stringRequired. User-defined unique ID of this instance. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Instance instance = new Instance();
string instanceId = "";
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.CreateInstance(parent, instance, instanceId);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceCreateInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
CreateInstance(CreateInstanceRequest, CallSettings)
public virtual Operation<Instance, OperationMetadata> CreateInstance(CreateInstanceRequest request, CallSettings callSettings = null)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
CreateInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
CreateInstanceRequest request = new CreateInstanceRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
InstanceId = "",
Instance = new Instance(),
RequestId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.CreateInstance(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceCreateInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
CreateInstance(string, Instance, string, CallSettings)
public virtual Operation<Instance, OperationMetadata> CreateInstance(string parent, Instance instance, string instanceId, CallSettings callSettings = null)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Format:
|
instance |
InstanceRequired. The instance to be created. |
instanceId |
stringRequired. User-defined unique ID of this instance. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Instance instance = new Instance();
string instanceId = "";
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.CreateInstance(parent, instance, instanceId);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceCreateInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
CreateInstanceAsync(LocationName, Instance, string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> CreateInstanceAsync(LocationName parent, Instance instance, string instanceId, CallSettings callSettings = null)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Format:
|
instance |
InstanceRequired. The instance to be created. |
instanceId |
stringRequired. User-defined unique ID of this instance. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Instance instance = new Instance();
string instanceId = "";
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.CreateInstanceAsync(parent, instance, instanceId);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceCreateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
CreateInstanceAsync(LocationName, Instance, string, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> CreateInstanceAsync(LocationName parent, Instance instance, string instanceId, CancellationToken cancellationToken)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Format:
|
instance |
InstanceRequired. The instance to be created. |
instanceId |
stringRequired. User-defined unique ID of this instance. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Instance instance = new Instance();
string instanceId = "";
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.CreateInstanceAsync(parent, instance, instanceId);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceCreateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
CreateInstanceAsync(CreateInstanceRequest, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> CreateInstanceAsync(CreateInstanceRequest request, CallSettings callSettings = null)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
CreateInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
CreateInstanceRequest request = new CreateInstanceRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
InstanceId = "",
Instance = new Instance(),
RequestId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.CreateInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceCreateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
CreateInstanceAsync(CreateInstanceRequest, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> CreateInstanceAsync(CreateInstanceRequest request, CancellationToken cancellationToken)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
CreateInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
CreateInstanceRequest request = new CreateInstanceRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
InstanceId = "",
Instance = new Instance(),
RequestId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.CreateInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceCreateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
CreateInstanceAsync(string, Instance, string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> CreateInstanceAsync(string parent, Instance instance, string instanceId, CallSettings callSettings = null)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Format:
|
instance |
InstanceRequired. The instance to be created. |
instanceId |
stringRequired. User-defined unique ID of this instance. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Instance instance = new Instance();
string instanceId = "";
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.CreateInstanceAsync(parent, instance, instanceId);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceCreateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
CreateInstanceAsync(string, Instance, string, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> CreateInstanceAsync(string parent, Instance instance, string instanceId, CancellationToken cancellationToken)Creates a new Instance in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Format:
|
instance |
InstanceRequired. The instance to be created. |
instanceId |
stringRequired. User-defined unique ID of this instance. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Instance instance = new Instance();
string instanceId = "";
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.CreateInstanceAsync(parent, instance, instanceId);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceCreateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DeleteInstance(DeleteInstanceRequest, CallSettings)
public virtual Operation<Empty, OperationMetadata> DeleteInstance(DeleteInstanceRequest request, CallSettings callSettings = null)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
DeleteInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationEmptyOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
DeleteInstanceRequest request = new DeleteInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = notebookServiceClient.DeleteInstance(request);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceDeleteInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DeleteInstance(InstanceName, CallSettings)
public virtual Operation<Empty, OperationMetadata> DeleteInstance(InstanceName name, CallSettings callSettings = null)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationEmptyOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
// Make the request
Operation<Empty, OperationMetadata> response = notebookServiceClient.DeleteInstance(name);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceDeleteInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DeleteInstance(string, CallSettings)
public virtual Operation<Empty, OperationMetadata> DeleteInstance(string name, CallSettings callSettings = null)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationEmptyOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
// Make the request
Operation<Empty, OperationMetadata> response = notebookServiceClient.DeleteInstance(name);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceDeleteInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DeleteInstanceAsync(DeleteInstanceRequest, CallSettings)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteInstanceAsync(DeleteInstanceRequest request, CallSettings callSettings = null)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
DeleteInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteInstanceRequest request = new DeleteInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await notebookServiceClient.DeleteInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDeleteInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DeleteInstanceAsync(DeleteInstanceRequest, CancellationToken)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteInstanceAsync(DeleteInstanceRequest request, CancellationToken cancellationToken)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
DeleteInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteInstanceRequest request = new DeleteInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await notebookServiceClient.DeleteInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDeleteInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DeleteInstanceAsync(InstanceName, CallSettings)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteInstanceAsync(InstanceName name, CallSettings callSettings = null)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
// Make the request
Operation<Empty, OperationMetadata> response = await notebookServiceClient.DeleteInstanceAsync(name);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDeleteInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DeleteInstanceAsync(InstanceName, CancellationToken)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteInstanceAsync(InstanceName name, CancellationToken cancellationToken)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
// Make the request
Operation<Empty, OperationMetadata> response = await notebookServiceClient.DeleteInstanceAsync(name);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDeleteInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DeleteInstanceAsync(string, CallSettings)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteInstanceAsync(string name, CallSettings callSettings = null)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
// Make the request
Operation<Empty, OperationMetadata> response = await notebookServiceClient.DeleteInstanceAsync(name);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDeleteInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DeleteInstanceAsync(string, CancellationToken)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteInstanceAsync(string name, CancellationToken cancellationToken)Deletes a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
// Make the request
Operation<Empty, OperationMetadata> response = await notebookServiceClient.DeleteInstanceAsync(name);
// Poll until the returned long-running operation is complete
Operation<Empty, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Empty result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Empty, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDeleteInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Empty retrievedResult = retrievedResponse.Result;
}
DiagnoseInstance(DiagnoseInstanceRequest, CallSettings)
public virtual Operation<Instance, OperationMetadata> DiagnoseInstance(DiagnoseInstanceRequest request, CallSettings callSettings = null)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
DiagnoseInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
DiagnoseInstanceRequest request = new DiagnoseInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
DiagnosticConfig = new DiagnosticConfig(),
TimeoutMinutes = 0,
};
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.DiagnoseInstance(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceDiagnoseInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DiagnoseInstance(InstanceName, DiagnosticConfig, CallSettings)
public virtual Operation<Instance, OperationMetadata> DiagnoseInstance(InstanceName name, DiagnosticConfig diagnosticConfig, CallSettings callSettings = null)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
diagnosticConfig |
DiagnosticConfigRequired. Defines flags that are used to run the diagnostic tool |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.DiagnoseInstance(name, diagnosticConfig);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceDiagnoseInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DiagnoseInstance(string, DiagnosticConfig, CallSettings)
public virtual Operation<Instance, OperationMetadata> DiagnoseInstance(string name, DiagnosticConfig diagnosticConfig, CallSettings callSettings = null)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
diagnosticConfig |
DiagnosticConfigRequired. Defines flags that are used to run the diagnostic tool |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.DiagnoseInstance(name, diagnosticConfig);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceDiagnoseInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DiagnoseInstanceAsync(DiagnoseInstanceRequest, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> DiagnoseInstanceAsync(DiagnoseInstanceRequest request, CallSettings callSettings = null)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
DiagnoseInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
DiagnoseInstanceRequest request = new DiagnoseInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
DiagnosticConfig = new DiagnosticConfig(),
TimeoutMinutes = 0,
};
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.DiagnoseInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDiagnoseInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DiagnoseInstanceAsync(DiagnoseInstanceRequest, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> DiagnoseInstanceAsync(DiagnoseInstanceRequest request, CancellationToken cancellationToken)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
DiagnoseInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
DiagnoseInstanceRequest request = new DiagnoseInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
DiagnosticConfig = new DiagnosticConfig(),
TimeoutMinutes = 0,
};
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.DiagnoseInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDiagnoseInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DiagnoseInstanceAsync(InstanceName, DiagnosticConfig, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> DiagnoseInstanceAsync(InstanceName name, DiagnosticConfig diagnosticConfig, CallSettings callSettings = null)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
diagnosticConfig |
DiagnosticConfigRequired. Defines flags that are used to run the diagnostic tool |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.DiagnoseInstanceAsync(name, diagnosticConfig);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDiagnoseInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DiagnoseInstanceAsync(InstanceName, DiagnosticConfig, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> DiagnoseInstanceAsync(InstanceName name, DiagnosticConfig diagnosticConfig, CancellationToken cancellationToken)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
diagnosticConfig |
DiagnosticConfigRequired. Defines flags that are used to run the diagnostic tool |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.DiagnoseInstanceAsync(name, diagnosticConfig);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDiagnoseInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DiagnoseInstanceAsync(string, DiagnosticConfig, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> DiagnoseInstanceAsync(string name, DiagnosticConfig diagnosticConfig, CallSettings callSettings = null)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
diagnosticConfig |
DiagnosticConfigRequired. Defines flags that are used to run the diagnostic tool |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.DiagnoseInstanceAsync(name, diagnosticConfig);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDiagnoseInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
DiagnoseInstanceAsync(string, DiagnosticConfig, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> DiagnoseInstanceAsync(string name, DiagnosticConfig diagnosticConfig, CancellationToken cancellationToken)Creates a Diagnostic File and runs Diagnostic Tool given an Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
diagnosticConfig |
DiagnosticConfigRequired. Defines flags that are used to run the diagnostic tool |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.DiagnoseInstanceAsync(name, diagnosticConfig);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceDiagnoseInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
GetInstance(GetInstanceRequest, CallSettings)
public virtual Instance GetInstance(GetInstanceRequest request, CallSettings callSettings = null)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
GetInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
Instance |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
GetInstanceRequest request = new GetInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
};
// Make the request
Instance response = notebookServiceClient.GetInstance(request);
GetInstance(InstanceName, CallSettings)
public virtual Instance GetInstance(InstanceName name, CallSettings callSettings = null)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
Instance |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
// Make the request
Instance response = notebookServiceClient.GetInstance(name);
GetInstance(string, CallSettings)
public virtual Instance GetInstance(string name, CallSettings callSettings = null)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
Instance |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
// Make the request
Instance response = notebookServiceClient.GetInstance(name);
GetInstanceAsync(GetInstanceRequest, CallSettings)
public virtual Task<Instance> GetInstanceAsync(GetInstanceRequest request, CallSettings callSettings = null)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
GetInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskInstance |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
GetInstanceRequest request = new GetInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
};
// Make the request
Instance response = await notebookServiceClient.GetInstanceAsync(request);
GetInstanceAsync(GetInstanceRequest, CancellationToken)
public virtual Task<Instance> GetInstanceAsync(GetInstanceRequest request, CancellationToken cancellationToken)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
GetInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskInstance |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
GetInstanceRequest request = new GetInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
};
// Make the request
Instance response = await notebookServiceClient.GetInstanceAsync(request);
GetInstanceAsync(InstanceName, CallSettings)
public virtual Task<Instance> GetInstanceAsync(InstanceName name, CallSettings callSettings = null)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskInstance |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
// Make the request
Instance response = await notebookServiceClient.GetInstanceAsync(name);
GetInstanceAsync(InstanceName, CancellationToken)
public virtual Task<Instance> GetInstanceAsync(InstanceName name, CancellationToken cancellationToken)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
InstanceNameRequired. Format:
|
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskInstance |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
InstanceName name = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]");
// Make the request
Instance response = await notebookServiceClient.GetInstanceAsync(name);
GetInstanceAsync(string, CallSettings)
public virtual Task<Instance> GetInstanceAsync(string name, CallSettings callSettings = null)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskInstance |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
// Make the request
Instance response = await notebookServiceClient.GetInstanceAsync(name);
GetInstanceAsync(string, CancellationToken)
public virtual Task<Instance> GetInstanceAsync(string name, CancellationToken cancellationToken)Gets details of a single Instance.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Format:
|
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskInstance |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/instances/[INSTANCE]";
// Make the request
Instance response = await notebookServiceClient.GetInstanceAsync(name);
ListInstances(LocationName, string, int?, CallSettings)
public virtual PagedEnumerable<ListInstancesResponse, Instance> ListInstances(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)Lists instances in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Format:
|
pageToken |
stringThe token returned from the previous request. A value of |
pageSize |
intThe size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedEnumerableListInstancesResponseInstance |
A pageable sequence of Instance resources. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListInstancesResponse, Instance> response = notebookServiceClient.ListInstances(parent);
// Iterate over all response items, lazily performing RPCs as required
foreach (Instance item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListInstancesResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Instance item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Instance> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Instance item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
ListInstances(ListInstancesRequest, CallSettings)
public virtual PagedEnumerable<ListInstancesResponse, Instance> ListInstances(ListInstancesRequest request, CallSettings callSettings = null)Lists instances in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
ListInstancesRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedEnumerableListInstancesResponseInstance |
A pageable sequence of Instance resources. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
ListInstancesRequest request = new ListInstancesRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
OrderBy = "",
Filter = "",
};
// Make the request
PagedEnumerable<ListInstancesResponse, Instance> response = notebookServiceClient.ListInstances(request);
// Iterate over all response items, lazily performing RPCs as required
foreach (Instance item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListInstancesResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Instance item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Instance> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Instance item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
ListInstances(string, string, int?, CallSettings)
public virtual PagedEnumerable<ListInstancesResponse, Instance> ListInstances(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)Lists instances in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Format:
|
pageToken |
stringThe token returned from the previous request. A value of |
pageSize |
intThe size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedEnumerableListInstancesResponseInstance |
A pageable sequence of Instance resources. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListInstancesResponse, Instance> response = notebookServiceClient.ListInstances(parent);
// Iterate over all response items, lazily performing RPCs as required
foreach (Instance item in response)
{
// Do something with each item
Console.WriteLine(item);
}
// Or iterate over pages (of server-defined size), performing one RPC per page
foreach (ListInstancesResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Instance item in page)
{
// Do something with each item
Console.WriteLine(item);
}
}
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Instance> singlePage = response.ReadPage(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Instance item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
ListInstancesAsync(LocationName, string, int?, CallSettings)
public virtual PagedAsyncEnumerable<ListInstancesResponse, Instance> ListInstancesAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)Lists instances in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Format:
|
pageToken |
stringThe token returned from the previous request. A value of |
pageSize |
intThe size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedAsyncEnumerableListInstancesResponseInstance |
A pageable asynchronous sequence of Instance resources. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListInstancesResponse, Instance> response = notebookServiceClient.ListInstancesAsync(parent);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Instance item) =>
{
// Do something with each item
Console.WriteLine(item);
});
// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListInstancesResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Instance item in page)
{
// Do something with each item
Console.WriteLine(item);
}
});
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Instance> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Instance item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
ListInstancesAsync(ListInstancesRequest, CallSettings)
public virtual PagedAsyncEnumerable<ListInstancesResponse, Instance> ListInstancesAsync(ListInstancesRequest request, CallSettings callSettings = null)Lists instances in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
ListInstancesRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedAsyncEnumerableListInstancesResponseInstance |
A pageable asynchronous sequence of Instance resources. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
ListInstancesRequest request = new ListInstancesRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
OrderBy = "",
Filter = "",
};
// Make the request
PagedAsyncEnumerable<ListInstancesResponse, Instance> response = notebookServiceClient.ListInstancesAsync(request);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Instance item) =>
{
// Do something with each item
Console.WriteLine(item);
});
// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListInstancesResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Instance item in page)
{
// Do something with each item
Console.WriteLine(item);
}
});
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Instance> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Instance item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
ListInstancesAsync(string, string, int?, CallSettings)
public virtual PagedAsyncEnumerable<ListInstancesResponse, Instance> ListInstancesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)Lists instances in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Format:
|
pageToken |
stringThe token returned from the previous request. A value of |
pageSize |
intThe size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedAsyncEnumerableListInstancesResponseInstance |
A pageable asynchronous sequence of Instance resources. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListInstancesResponse, Instance> response = notebookServiceClient.ListInstancesAsync(parent);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Instance item) =>
{
// Do something with each item
Console.WriteLine(item);
});
// Or iterate over pages (of server-defined size), performing one RPC per page
await response.AsRawResponses().ForEachAsync((ListInstancesResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Instance item in page)
{
// Do something with each item
Console.WriteLine(item);
}
});
// Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
int pageSize = 10;
Page<Instance> singlePage = await response.ReadPageAsync(pageSize);
// Do something with the page of items
Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
foreach (Instance item in singlePage)
{
// Do something with each item
Console.WriteLine(item);
}
// Store the pageToken, for when the next page is required.
string nextPageToken = singlePage.NextPageToken;
PollOnceCreateInstance(string, CallSettings)
public virtual Operation<Instance, OperationMetadata> PollOnceCreateInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of CreateInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The result of polling the operation. |
PollOnceCreateInstanceAsync(string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> PollOnceCreateInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
CreateInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A task representing the result of polling the operation. |
PollOnceDeleteInstance(string, CallSettings)
public virtual Operation<Empty, OperationMetadata> PollOnceDeleteInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of DeleteInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationEmptyOperationMetadata |
The result of polling the operation. |
PollOnceDeleteInstanceAsync(string, CallSettings)
public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
DeleteInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A task representing the result of polling the operation. |
PollOnceDiagnoseInstance(string, CallSettings)
public virtual Operation<Instance, OperationMetadata> PollOnceDiagnoseInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of DiagnoseInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The result of polling the operation. |
PollOnceDiagnoseInstanceAsync(string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> PollOnceDiagnoseInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
DiagnoseInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A task representing the result of polling the operation. |
PollOnceResetInstance(string, CallSettings)
public virtual Operation<Instance, OperationMetadata> PollOnceResetInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of ResetInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The result of polling the operation. |
PollOnceResetInstanceAsync(string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> PollOnceResetInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
ResetInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A task representing the result of polling the operation. |
PollOnceRollbackInstance(string, CallSettings)
public virtual Operation<Instance, OperationMetadata> PollOnceRollbackInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of RollbackInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The result of polling the operation. |
PollOnceRollbackInstanceAsync(string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> PollOnceRollbackInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
RollbackInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A task representing the result of polling the operation. |
PollOnceStartInstance(string, CallSettings)
public virtual Operation<Instance, OperationMetadata> PollOnceStartInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of StartInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The result of polling the operation. |
PollOnceStartInstanceAsync(string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> PollOnceStartInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
StartInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A task representing the result of polling the operation. |
PollOnceStopInstance(string, CallSettings)
public virtual Operation<Instance, OperationMetadata> PollOnceStopInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of StopInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The result of polling the operation. |
PollOnceStopInstanceAsync(string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> PollOnceStopInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
StopInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A task representing the result of polling the operation. |
PollOnceUpdateInstance(string, CallSettings)
public virtual Operation<Instance, OperationMetadata> PollOnceUpdateInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of UpdateInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The result of polling the operation. |
PollOnceUpdateInstanceAsync(string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> PollOnceUpdateInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
UpdateInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A task representing the result of polling the operation. |
PollOnceUpgradeInstance(string, CallSettings)
public virtual Operation<Instance, OperationMetadata> PollOnceUpgradeInstance(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of UpgradeInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The result of polling the operation. |
PollOnceUpgradeInstanceAsync(string, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> PollOnceUpgradeInstanceAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
UpgradeInstance.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A task representing the result of polling the operation. |
ResetInstance(ResetInstanceRequest, CallSettings)
public virtual Operation<Instance, OperationMetadata> ResetInstance(ResetInstanceRequest request, CallSettings callSettings = null)Resets a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
ResetInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
ResetInstanceRequest request = new ResetInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.ResetInstance(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceResetInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
ResetInstanceAsync(ResetInstanceRequest, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> ResetInstanceAsync(ResetInstanceRequest request, CallSettings callSettings = null)Resets a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
ResetInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
ResetInstanceRequest request = new ResetInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.ResetInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceResetInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
ResetInstanceAsync(ResetInstanceRequest, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> ResetInstanceAsync(ResetInstanceRequest request, CancellationToken cancellationToken)Resets a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
ResetInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
ResetInstanceRequest request = new ResetInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.ResetInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceResetInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
RollbackInstance(RollbackInstanceRequest, CallSettings)
public virtual Operation<Instance, OperationMetadata> RollbackInstance(RollbackInstanceRequest request, CallSettings callSettings = null)Rollbacks a notebook instance to the previous version.
| Parameters | |
|---|---|
| Name | Description |
request |
RollbackInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
RollbackInstanceRequest request = new RollbackInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
TargetSnapshot = "",
RevisionId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.RollbackInstance(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceRollbackInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
RollbackInstanceAsync(RollbackInstanceRequest, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> RollbackInstanceAsync(RollbackInstanceRequest request, CallSettings callSettings = null)Rollbacks a notebook instance to the previous version.
| Parameters | |
|---|---|
| Name | Description |
request |
RollbackInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RollbackInstanceRequest request = new RollbackInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
TargetSnapshot = "",
RevisionId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.RollbackInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceRollbackInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
RollbackInstanceAsync(RollbackInstanceRequest, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> RollbackInstanceAsync(RollbackInstanceRequest request, CancellationToken cancellationToken)Rollbacks a notebook instance to the previous version.
| Parameters | |
|---|---|
| Name | Description |
request |
RollbackInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RollbackInstanceRequest request = new RollbackInstanceRequest
{
InstanceName = InstanceName.FromProjectLocationInstance("[PROJECT]", "[LOCATION]", "[INSTANCE]"),
TargetSnapshot = "",
RevisionId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.RollbackInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceRollbackInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
ShutdownDefaultChannelsAsync()
public static Task ShutdownDefaultChannelsAsync()Shuts down any channels automatically created by Create() and CreateAsync(CancellationToken). Channels which weren't automatically created are not affected.
| Returns | |
|---|---|
| Type | Description |
Task |
A task representing the asynchronous shutdown operation. |
After calling this method, further calls to Create() and CreateAsync(CancellationToken) will create new channels, which could in turn be shut down by another call to this method.
StartInstance(StartInstanceRequest, CallSettings)
public virtual Operation<Instance, OperationMetadata> StartInstance(StartInstanceRequest request, CallSettings callSettings = null)Starts a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
StartInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
StartInstanceRequest request = new StartInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.StartInstance(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceStartInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
StartInstanceAsync(StartInstanceRequest, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> StartInstanceAsync(StartInstanceRequest request, CallSettings callSettings = null)Starts a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
StartInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
StartInstanceRequest request = new StartInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.StartInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceStartInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
StartInstanceAsync(StartInstanceRequest, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> StartInstanceAsync(StartInstanceRequest request, CancellationToken cancellationToken)Starts a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
StartInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
StartInstanceRequest request = new StartInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.StartInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceStartInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
StopInstance(StopInstanceRequest, CallSettings)
public virtual Operation<Instance, OperationMetadata> StopInstance(StopInstanceRequest request, CallSettings callSettings = null)Stops a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
StopInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
StopInstanceRequest request = new StopInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.StopInstance(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceStopInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
StopInstanceAsync(StopInstanceRequest, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> StopInstanceAsync(StopInstanceRequest request, CallSettings callSettings = null)Stops a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
StopInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
StopInstanceRequest request = new StopInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.StopInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceStopInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
StopInstanceAsync(StopInstanceRequest, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> StopInstanceAsync(StopInstanceRequest request, CancellationToken cancellationToken)Stops a notebook instance.
| Parameters | |
|---|---|
| Name | Description |
request |
StopInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
StopInstanceRequest request = new StopInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.StopInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceStopInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpdateInstance(Instance, FieldMask, CallSettings)
public virtual Operation<Instance, OperationMetadata> UpdateInstance(Instance instance, FieldMask updateMask, CallSettings callSettings = null)UpdateInstance updates an Instance.
| Parameters | |
|---|---|
| Name | Description |
instance |
InstanceRequired. A representation of an instance. |
updateMask |
FieldMaskRequired. Mask used to update an instance |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
Instance instance = new Instance();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.UpdateInstance(instance, updateMask);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceUpdateInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpdateInstance(UpdateInstanceRequest, CallSettings)
public virtual Operation<Instance, OperationMetadata> UpdateInstance(UpdateInstanceRequest request, CallSettings callSettings = null)UpdateInstance updates an Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
UpdateInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
UpdateInstanceRequest request = new UpdateInstanceRequest
{
Instance = new Instance(),
UpdateMask = new FieldMask(),
RequestId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.UpdateInstance(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceUpdateInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpdateInstanceAsync(Instance, FieldMask, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> UpdateInstanceAsync(Instance instance, FieldMask updateMask, CallSettings callSettings = null)UpdateInstance updates an Instance.
| Parameters | |
|---|---|
| Name | Description |
instance |
InstanceRequired. A representation of an instance. |
updateMask |
FieldMaskRequired. Mask used to update an instance |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
Instance instance = new Instance();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.UpdateInstanceAsync(instance, updateMask);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceUpdateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpdateInstanceAsync(Instance, FieldMask, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> UpdateInstanceAsync(Instance instance, FieldMask updateMask, CancellationToken cancellationToken)UpdateInstance updates an Instance.
| Parameters | |
|---|---|
| Name | Description |
instance |
InstanceRequired. A representation of an instance. |
updateMask |
FieldMaskRequired. Mask used to update an instance |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
Instance instance = new Instance();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.UpdateInstanceAsync(instance, updateMask);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceUpdateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpdateInstanceAsync(UpdateInstanceRequest, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> UpdateInstanceAsync(UpdateInstanceRequest request, CallSettings callSettings = null)UpdateInstance updates an Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
UpdateInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateInstanceRequest request = new UpdateInstanceRequest
{
Instance = new Instance(),
UpdateMask = new FieldMask(),
RequestId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.UpdateInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceUpdateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpdateInstanceAsync(UpdateInstanceRequest, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> UpdateInstanceAsync(UpdateInstanceRequest request, CancellationToken cancellationToken)UpdateInstance updates an Instance.
| Parameters | |
|---|---|
| Name | Description |
request |
UpdateInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateInstanceRequest request = new UpdateInstanceRequest
{
Instance = new Instance(),
UpdateMask = new FieldMask(),
RequestId = "",
};
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.UpdateInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceUpdateInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpgradeInstance(UpgradeInstanceRequest, CallSettings)
public virtual Operation<Instance, OperationMetadata> UpgradeInstance(UpgradeInstanceRequest request, CallSettings callSettings = null)Upgrades a notebook instance to the latest version.
| Parameters | |
|---|---|
| Name | Description |
request |
UpgradeInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationInstanceOperationMetadata |
The RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = NotebookServiceClient.Create();
// Initialize request argument(s)
UpgradeInstanceRequest request = new UpgradeInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = notebookServiceClient.UpgradeInstance(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = notebookServiceClient.PollOnceUpgradeInstance(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpgradeInstanceAsync(UpgradeInstanceRequest, CallSettings)
public virtual Task<Operation<Instance, OperationMetadata>> UpgradeInstanceAsync(UpgradeInstanceRequest request, CallSettings callSettings = null)Upgrades a notebook instance to the latest version.
| Parameters | |
|---|---|
| Name | Description |
request |
UpgradeInstanceRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
UpgradeInstanceRequest request = new UpgradeInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.UpgradeInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceUpgradeInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}
UpgradeInstanceAsync(UpgradeInstanceRequest, CancellationToken)
public virtual Task<Operation<Instance, OperationMetadata>> UpgradeInstanceAsync(UpgradeInstanceRequest request, CancellationToken cancellationToken)Upgrades a notebook instance to the latest version.
| Parameters | |
|---|---|
| Name | Description |
request |
UpgradeInstanceRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationInstanceOperationMetadata |
A Task containing the RPC response. |
// Create client
NotebookServiceClient notebookServiceClient = await NotebookServiceClient.CreateAsync();
// Initialize request argument(s)
UpgradeInstanceRequest request = new UpgradeInstanceRequest { Name = "", };
// Make the request
Operation<Instance, OperationMetadata> response = await notebookServiceClient.UpgradeInstanceAsync(request);
// Poll until the returned long-running operation is complete
Operation<Instance, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Instance result = completedResponse.Result;
// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<Instance, OperationMetadata> retrievedResponse = await notebookServiceClient.PollOnceUpgradeInstanceAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Instance retrievedResult = retrievedResponse.Result;
}