AI Platform Notebooks v1 API - Class ManagedNotebookServiceClient (2.2.0)

public abstract class ManagedNotebookServiceClient

Reference documentation and code samples for the AI Platform Notebooks v1 API class ManagedNotebookServiceClient.

ManagedNotebookService client wrapper, for convenient use.

Inheritance

Object > ManagedNotebookServiceClient

Namespace

Google.Cloud.Notebooks.V1

Assembly

Google.Cloud.Notebooks.V1.dll

Remarks

API v1 service for Managed Notebooks.

Properties

CreateRuntimeOperationsClient

public virtual OperationsClient CreateRuntimeOperationsClient { get; }

The long-running operations client for CreateRuntime.

Property Value
TypeDescription
OperationsClient

DefaultEndpoint

public static string DefaultEndpoint { get; }

The default endpoint for the ManagedNotebookService service, which is a host of "notebooks.googleapis.com" and a port of 443.

Property Value
TypeDescription
String

DefaultScopes

public static IReadOnlyList<string> DefaultScopes { get; }

The default ManagedNotebookService scopes.

Property Value
TypeDescription
IReadOnlyList<String>
Remarks

The default ManagedNotebookService scopes are:

DeleteRuntimeOperationsClient

public virtual OperationsClient DeleteRuntimeOperationsClient { get; }

The long-running operations client for DeleteRuntime.

Property Value
TypeDescription
OperationsClient

DiagnoseRuntimeOperationsClient

public virtual OperationsClient DiagnoseRuntimeOperationsClient { get; }

The long-running operations client for DiagnoseRuntime.

Property Value
TypeDescription
OperationsClient

GrpcClient

public virtual ManagedNotebookService.ManagedNotebookServiceClient GrpcClient { get; }

The underlying gRPC ManagedNotebookService client

Property Value
TypeDescription
ManagedNotebookService.ManagedNotebookServiceClient

IAMPolicyClient

public virtual IAMPolicyClient IAMPolicyClient { get; }

The IAMPolicyClient associated with this client.

Property Value
TypeDescription
IAMPolicyClient

LocationsClient

public virtual LocationsClient LocationsClient { get; }

The LocationsClient associated with this client.

Property Value
TypeDescription
LocationsClient

ReportRuntimeEventOperationsClient

public virtual OperationsClient ReportRuntimeEventOperationsClient { get; }

The long-running operations client for ReportRuntimeEvent.

Property Value
TypeDescription
OperationsClient

ResetRuntimeOperationsClient

public virtual OperationsClient ResetRuntimeOperationsClient { get; }

The long-running operations client for ResetRuntime.

Property Value
TypeDescription
OperationsClient

ServiceMetadata

public static ServiceMetadata ServiceMetadata { get; }

The service metadata associated with this client type.

Property Value
TypeDescription
ServiceMetadata

StartRuntimeOperationsClient

public virtual OperationsClient StartRuntimeOperationsClient { get; }

The long-running operations client for StartRuntime.

Property Value
TypeDescription
OperationsClient

StopRuntimeOperationsClient

public virtual OperationsClient StopRuntimeOperationsClient { get; }

The long-running operations client for StopRuntime.

Property Value
TypeDescription
OperationsClient

SwitchRuntimeOperationsClient

public virtual OperationsClient SwitchRuntimeOperationsClient { get; }

The long-running operations client for SwitchRuntime.

Property Value
TypeDescription
OperationsClient

UpdateRuntimeOperationsClient

public virtual OperationsClient UpdateRuntimeOperationsClient { get; }

The long-running operations client for UpdateRuntime.

Property Value
TypeDescription
OperationsClient

UpgradeRuntimeOperationsClient

public virtual OperationsClient UpgradeRuntimeOperationsClient { get; }

The long-running operations client for UpgradeRuntime.

Property Value
TypeDescription
OperationsClient

Methods

Create()

public static ManagedNotebookServiceClient Create()

Synchronously creates a ManagedNotebookServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use ManagedNotebookServiceClientBuilder.

Returns
TypeDescription
ManagedNotebookServiceClient

The created ManagedNotebookServiceClient.

CreateAsync(CancellationToken)

public static Task<ManagedNotebookServiceClient> CreateAsync(CancellationToken cancellationToken = default(CancellationToken))

Asynchronously creates a ManagedNotebookServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use ManagedNotebookServiceClientBuilder.

Parameter
NameDescription
cancellationTokenCancellationToken

The CancellationToken to use while creating the client.

Returns
TypeDescription
Task<ManagedNotebookServiceClient>

The task representing the created ManagedNotebookServiceClient.

CreateRuntime(CreateRuntimeRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> CreateRuntime(CreateRuntimeRequest request, CallSettings callSettings = null)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
requestCreateRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
CreateRuntimeRequest request = new CreateRuntimeRequest
{
    ParentAsRuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    RuntimeId = "",
    Runtime = new Runtime(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.CreateRuntime(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceCreateRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

CreateRuntime(RuntimeName, String, Runtime, CallSettings)

public virtual Operation<Runtime, OperationMetadata> CreateRuntime(RuntimeName parent, string runtimeId, Runtime runtime, CallSettings callSettings = null)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
parentRuntimeName

Required. Format: parent=projects/{project_id}/locations/{location}

runtimeIdString

Required. User-defined unique ID of this Runtime.

runtimeRuntime

Required. The Runtime to be created.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
RuntimeName parent = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
string runtimeId = "";
Runtime runtime = new Runtime();
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.CreateRuntime(parent, runtimeId, runtime);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceCreateRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

CreateRuntime(String, String, Runtime, CallSettings)

public virtual Operation<Runtime, OperationMetadata> CreateRuntime(string parent, string runtimeId, Runtime runtime, CallSettings callSettings = null)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
parentString

Required. Format: parent=projects/{project_id}/locations/{location}

runtimeIdString

Required. User-defined unique ID of this Runtime.

runtimeRuntime

Required. The Runtime to be created.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
string runtimeId = "";
Runtime runtime = new Runtime();
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.CreateRuntime(parent, runtimeId, runtime);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceCreateRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

CreateRuntimeAsync(CreateRuntimeRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> CreateRuntimeAsync(CreateRuntimeRequest request, CallSettings callSettings = null)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
requestCreateRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
CreateRuntimeRequest request = new CreateRuntimeRequest
{
    ParentAsRuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    RuntimeId = "",
    Runtime = new Runtime(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.CreateRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceCreateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

CreateRuntimeAsync(CreateRuntimeRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> CreateRuntimeAsync(CreateRuntimeRequest request, CancellationToken cancellationToken)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
requestCreateRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
CreateRuntimeRequest request = new CreateRuntimeRequest
{
    ParentAsRuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    RuntimeId = "",
    Runtime = new Runtime(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.CreateRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceCreateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

CreateRuntimeAsync(RuntimeName, String, Runtime, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> CreateRuntimeAsync(RuntimeName parent, string runtimeId, Runtime runtime, CallSettings callSettings = null)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
parentRuntimeName

Required. Format: parent=projects/{project_id}/locations/{location}

runtimeIdString

Required. User-defined unique ID of this Runtime.

runtimeRuntime

Required. The Runtime to be created.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName parent = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
string runtimeId = "";
Runtime runtime = new Runtime();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.CreateRuntimeAsync(parent, runtimeId, runtime);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceCreateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

CreateRuntimeAsync(RuntimeName, String, Runtime, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> CreateRuntimeAsync(RuntimeName parent, string runtimeId, Runtime runtime, CancellationToken cancellationToken)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
parentRuntimeName

Required. Format: parent=projects/{project_id}/locations/{location}

runtimeIdString

Required. User-defined unique ID of this Runtime.

runtimeRuntime

Required. The Runtime to be created.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName parent = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
string runtimeId = "";
Runtime runtime = new Runtime();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.CreateRuntimeAsync(parent, runtimeId, runtime);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceCreateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

CreateRuntimeAsync(String, String, Runtime, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> CreateRuntimeAsync(string parent, string runtimeId, Runtime runtime, CallSettings callSettings = null)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
parentString

Required. Format: parent=projects/{project_id}/locations/{location}

runtimeIdString

Required. User-defined unique ID of this Runtime.

runtimeRuntime

Required. The Runtime to be created.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
string runtimeId = "";
Runtime runtime = new Runtime();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.CreateRuntimeAsync(parent, runtimeId, runtime);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceCreateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

CreateRuntimeAsync(String, String, Runtime, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> CreateRuntimeAsync(string parent, string runtimeId, Runtime runtime, CancellationToken cancellationToken)

Creates a new Runtime in a given project and location.

Parameters
NameDescription
parentString

Required. Format: parent=projects/{project_id}/locations/{location}

runtimeIdString

Required. User-defined unique ID of this Runtime.

runtimeRuntime

Required. The Runtime to be created.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
string runtimeId = "";
Runtime runtime = new Runtime();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.CreateRuntimeAsync(parent, runtimeId, runtime);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceCreateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DeleteRuntime(DeleteRuntimeRequest, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteRuntime(DeleteRuntimeRequest request, CallSettings callSettings = null)

Deletes a single Runtime.

Parameters
NameDescription
requestDeleteRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Empty, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
DeleteRuntimeRequest request = new DeleteRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = managedNotebookServiceClient.DeleteRuntime(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 = managedNotebookServiceClient.PollOnceDeleteRuntime(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;
}

DeleteRuntime(RuntimeName, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteRuntime(RuntimeName name, CallSettings callSettings = null)

Deletes a single Runtime.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Empty, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Operation<Empty, OperationMetadata> response = managedNotebookServiceClient.DeleteRuntime(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 = managedNotebookServiceClient.PollOnceDeleteRuntime(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;
}

DeleteRuntime(String, CallSettings)

public virtual Operation<Empty, OperationMetadata> DeleteRuntime(string name, CallSettings callSettings = null)

Deletes a single Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Empty, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Operation<Empty, OperationMetadata> response = managedNotebookServiceClient.DeleteRuntime(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 = managedNotebookServiceClient.PollOnceDeleteRuntime(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;
}

DeleteRuntimeAsync(DeleteRuntimeRequest, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRuntimeAsync(DeleteRuntimeRequest request, CallSettings callSettings = null)

Deletes a single Runtime.

Parameters
NameDescription
requestDeleteRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteRuntimeRequest request = new DeleteRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await managedNotebookServiceClient.DeleteRuntimeAsync(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 managedNotebookServiceClient.PollOnceDeleteRuntimeAsync(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;
}

DeleteRuntimeAsync(DeleteRuntimeRequest, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRuntimeAsync(DeleteRuntimeRequest request, CancellationToken cancellationToken)

Deletes a single Runtime.

Parameters
NameDescription
requestDeleteRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteRuntimeRequest request = new DeleteRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await managedNotebookServiceClient.DeleteRuntimeAsync(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 managedNotebookServiceClient.PollOnceDeleteRuntimeAsync(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;
}

DeleteRuntimeAsync(RuntimeName, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRuntimeAsync(RuntimeName name, CallSettings callSettings = null)

Deletes a single Runtime.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Operation<Empty, OperationMetadata> response = await managedNotebookServiceClient.DeleteRuntimeAsync(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 managedNotebookServiceClient.PollOnceDeleteRuntimeAsync(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;
}

DeleteRuntimeAsync(RuntimeName, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRuntimeAsync(RuntimeName name, CancellationToken cancellationToken)

Deletes a single Runtime.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Operation<Empty, OperationMetadata> response = await managedNotebookServiceClient.DeleteRuntimeAsync(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 managedNotebookServiceClient.PollOnceDeleteRuntimeAsync(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;
}

DeleteRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRuntimeAsync(string name, CallSettings callSettings = null)

Deletes a single Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Operation<Empty, OperationMetadata> response = await managedNotebookServiceClient.DeleteRuntimeAsync(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 managedNotebookServiceClient.PollOnceDeleteRuntimeAsync(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;
}

DeleteRuntimeAsync(String, CancellationToken)

public virtual Task<Operation<Empty, OperationMetadata>> DeleteRuntimeAsync(string name, CancellationToken cancellationToken)

Deletes a single Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Operation<Empty, OperationMetadata> response = await managedNotebookServiceClient.DeleteRuntimeAsync(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 managedNotebookServiceClient.PollOnceDeleteRuntimeAsync(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;
}

DiagnoseRuntime(DiagnoseRuntimeRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> DiagnoseRuntime(DiagnoseRuntimeRequest request, CallSettings callSettings = null)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
requestDiagnoseRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
DiagnoseRuntimeRequest request = new DiagnoseRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    DiagnosticConfig = new DiagnosticConfig(),
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.DiagnoseRuntime(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceDiagnoseRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DiagnoseRuntime(RuntimeName, DiagnosticConfig, CallSettings)

public virtual Operation<Runtime, OperationMetadata> DiagnoseRuntime(RuntimeName name, DiagnosticConfig diagnosticConfig, CallSettings callSettings = null)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtimes_id}

diagnosticConfigDiagnosticConfig

Required. Defines flags that are used to run the diagnostic tool

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.DiagnoseRuntime(name, diagnosticConfig);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceDiagnoseRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DiagnoseRuntime(String, DiagnosticConfig, CallSettings)

public virtual Operation<Runtime, OperationMetadata> DiagnoseRuntime(string name, DiagnosticConfig diagnosticConfig, CallSettings callSettings = null)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtimes_id}

diagnosticConfigDiagnosticConfig

Required. Defines flags that are used to run the diagnostic tool

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.DiagnoseRuntime(name, diagnosticConfig);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceDiagnoseRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DiagnoseRuntimeAsync(DiagnoseRuntimeRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> DiagnoseRuntimeAsync(DiagnoseRuntimeRequest request, CallSettings callSettings = null)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
requestDiagnoseRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
DiagnoseRuntimeRequest request = new DiagnoseRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    DiagnosticConfig = new DiagnosticConfig(),
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.DiagnoseRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceDiagnoseRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DiagnoseRuntimeAsync(DiagnoseRuntimeRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> DiagnoseRuntimeAsync(DiagnoseRuntimeRequest request, CancellationToken cancellationToken)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
requestDiagnoseRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
DiagnoseRuntimeRequest request = new DiagnoseRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    DiagnosticConfig = new DiagnosticConfig(),
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.DiagnoseRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceDiagnoseRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DiagnoseRuntimeAsync(RuntimeName, DiagnosticConfig, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> DiagnoseRuntimeAsync(RuntimeName name, DiagnosticConfig diagnosticConfig, CallSettings callSettings = null)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtimes_id}

diagnosticConfigDiagnosticConfig

Required. Defines flags that are used to run the diagnostic tool

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.DiagnoseRuntimeAsync(name, diagnosticConfig);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceDiagnoseRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DiagnoseRuntimeAsync(RuntimeName, DiagnosticConfig, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> DiagnoseRuntimeAsync(RuntimeName name, DiagnosticConfig diagnosticConfig, CancellationToken cancellationToken)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtimes_id}

diagnosticConfigDiagnosticConfig

Required. Defines flags that are used to run the diagnostic tool

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.DiagnoseRuntimeAsync(name, diagnosticConfig);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceDiagnoseRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DiagnoseRuntimeAsync(String, DiagnosticConfig, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> DiagnoseRuntimeAsync(string name, DiagnosticConfig diagnosticConfig, CallSettings callSettings = null)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtimes_id}

diagnosticConfigDiagnosticConfig

Required. Defines flags that are used to run the diagnostic tool

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.DiagnoseRuntimeAsync(name, diagnosticConfig);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceDiagnoseRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

DiagnoseRuntimeAsync(String, DiagnosticConfig, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> DiagnoseRuntimeAsync(string name, DiagnosticConfig diagnosticConfig, CancellationToken cancellationToken)

Creates a Diagnostic File and runs Diagnostic Tool given a Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtimes_id}

diagnosticConfigDiagnosticConfig

Required. Defines flags that are used to run the diagnostic tool

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
DiagnosticConfig diagnosticConfig = new DiagnosticConfig();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.DiagnoseRuntimeAsync(name, diagnosticConfig);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceDiagnoseRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

GetRuntime(GetRuntimeRequest, CallSettings)

public virtual Runtime GetRuntime(GetRuntimeRequest request, CallSettings callSettings = null)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
requestGetRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Runtime

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
GetRuntimeRequest request = new GetRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
};
// Make the request
Runtime response = managedNotebookServiceClient.GetRuntime(request);

GetRuntime(RuntimeName, CallSettings)

public virtual Runtime GetRuntime(RuntimeName name, CallSettings callSettings = null)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Runtime

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Runtime response = managedNotebookServiceClient.GetRuntime(name);

GetRuntime(String, CallSettings)

public virtual Runtime GetRuntime(string name, CallSettings callSettings = null)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Runtime

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Runtime response = managedNotebookServiceClient.GetRuntime(name);

GetRuntimeAsync(GetRuntimeRequest, CallSettings)

public virtual Task<Runtime> GetRuntimeAsync(GetRuntimeRequest request, CallSettings callSettings = null)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
requestGetRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Runtime>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
GetRuntimeRequest request = new GetRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
};
// Make the request
Runtime response = await managedNotebookServiceClient.GetRuntimeAsync(request);

GetRuntimeAsync(GetRuntimeRequest, CancellationToken)

public virtual Task<Runtime> GetRuntimeAsync(GetRuntimeRequest request, CancellationToken cancellationToken)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
requestGetRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Runtime>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
GetRuntimeRequest request = new GetRuntimeRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
};
// Make the request
Runtime response = await managedNotebookServiceClient.GetRuntimeAsync(request);

GetRuntimeAsync(RuntimeName, CallSettings)

public virtual Task<Runtime> GetRuntimeAsync(RuntimeName name, CallSettings callSettings = null)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Runtime>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Runtime response = await managedNotebookServiceClient.GetRuntimeAsync(name);

GetRuntimeAsync(RuntimeName, CancellationToken)

public virtual Task<Runtime> GetRuntimeAsync(RuntimeName name, CancellationToken cancellationToken)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Runtime>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Runtime response = await managedNotebookServiceClient.GetRuntimeAsync(name);

GetRuntimeAsync(String, CallSettings)

public virtual Task<Runtime> GetRuntimeAsync(string name, CallSettings callSettings = null)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Runtime>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Runtime response = await managedNotebookServiceClient.GetRuntimeAsync(name);

GetRuntimeAsync(String, CancellationToken)

public virtual Task<Runtime> GetRuntimeAsync(string name, CancellationToken cancellationToken)

Gets details of a single Runtime. The location must be a regional endpoint rather than zonal.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Runtime>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Runtime response = await managedNotebookServiceClient.GetRuntimeAsync(name);

ListRuntimes(LocationName, String, Nullable<Int32>, CallSettings)

public virtual PagedEnumerable<ListRuntimesResponse, Runtime> ListRuntimes(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Runtimes in a given project and location.

Parameters
NameDescription
parentLocationName

Required. Format: parent=projects/{project_id}/locations/{location}

pageTokenString

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSizeNullable<Int32>

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerable<ListRuntimesResponse, Runtime>

A pageable sequence of Runtime resources.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListRuntimesResponse, Runtime> response = managedNotebookServiceClient.ListRuntimes(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Runtime 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 (ListRuntimesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Runtime 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<Runtime> 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 (Runtime 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;

ListRuntimes(ListRuntimesRequest, CallSettings)

public virtual PagedEnumerable<ListRuntimesResponse, Runtime> ListRuntimes(ListRuntimesRequest request, CallSettings callSettings = null)

Lists Runtimes in a given project and location.

Parameters
NameDescription
requestListRuntimesRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerable<ListRuntimesResponse, Runtime>

A pageable sequence of Runtime resources.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
ListRuntimesRequest request = new ListRuntimesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
};
// Make the request
PagedEnumerable<ListRuntimesResponse, Runtime> response = managedNotebookServiceClient.ListRuntimes(request);

// Iterate over all response items, lazily performing RPCs as required
foreach (Runtime 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 (ListRuntimesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Runtime 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<Runtime> 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 (Runtime 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;

ListRuntimes(String, String, Nullable<Int32>, CallSettings)

public virtual PagedEnumerable<ListRuntimesResponse, Runtime> ListRuntimes(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Runtimes in a given project and location.

Parameters
NameDescription
parentString

Required. Format: parent=projects/{project_id}/locations/{location}

pageTokenString

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSizeNullable<Int32>

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedEnumerable<ListRuntimesResponse, Runtime>

A pageable sequence of Runtime resources.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListRuntimesResponse, Runtime> response = managedNotebookServiceClient.ListRuntimes(parent);

// Iterate over all response items, lazily performing RPCs as required
foreach (Runtime 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 (ListRuntimesResponse page in response.AsRawResponses())
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Runtime 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<Runtime> 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 (Runtime 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;

ListRuntimesAsync(LocationName, String, Nullable<Int32>, CallSettings)

public virtual PagedAsyncEnumerable<ListRuntimesResponse, Runtime> ListRuntimesAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Runtimes in a given project and location.

Parameters
NameDescription
parentLocationName

Required. Format: parent=projects/{project_id}/locations/{location}

pageTokenString

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSizeNullable<Int32>

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerable<ListRuntimesResponse, Runtime>

A pageable asynchronous sequence of Runtime resources.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListRuntimesResponse, Runtime> response = managedNotebookServiceClient.ListRuntimesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Runtime 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((ListRuntimesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Runtime 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<Runtime> 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 (Runtime 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;

ListRuntimesAsync(ListRuntimesRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListRuntimesResponse, Runtime> ListRuntimesAsync(ListRuntimesRequest request, CallSettings callSettings = null)

Lists Runtimes in a given project and location.

Parameters
NameDescription
requestListRuntimesRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerable<ListRuntimesResponse, Runtime>

A pageable asynchronous sequence of Runtime resources.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
ListRuntimesRequest request = new ListRuntimesRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
};
// Make the request
PagedAsyncEnumerable<ListRuntimesResponse, Runtime> response = managedNotebookServiceClient.ListRuntimesAsync(request);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Runtime 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((ListRuntimesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Runtime 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<Runtime> 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 (Runtime 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;

ListRuntimesAsync(String, String, Nullable<Int32>, CallSettings)

public virtual PagedAsyncEnumerable<ListRuntimesResponse, Runtime> ListRuntimesAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists Runtimes in a given project and location.

Parameters
NameDescription
parentString

Required. Format: parent=projects/{project_id}/locations/{location}

pageTokenString

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSizeNullable<Int32>

The size of page to request. The response will not be larger than this, but may be smaller. A value of null or 0 uses a server-defined page size.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
PagedAsyncEnumerable<ListRuntimesResponse, Runtime>

A pageable asynchronous sequence of Runtime resources.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListRuntimesResponse, Runtime> response = managedNotebookServiceClient.ListRuntimesAsync(parent);

// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Runtime 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((ListRuntimesResponse page) =>
{
    // Do something with each page of items
    Console.WriteLine("A page of results:");
    foreach (Runtime 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<Runtime> 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 (Runtime 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;

PollOnceCreateRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceCreateRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of CreateRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceCreateRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceCreateRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of CreateRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceDeleteRuntime(String, CallSettings)

public virtual Operation<Empty, OperationMetadata> PollOnceDeleteRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DeleteRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Empty, OperationMetadata>

The result of polling the operation.

PollOnceDeleteRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DeleteRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Empty, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceDiagnoseRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceDiagnoseRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of DiagnoseRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceDiagnoseRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceDiagnoseRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of DiagnoseRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceReportRuntimeEvent(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceReportRuntimeEvent(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of ReportRuntimeEvent .

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceReportRuntimeEventAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceReportRuntimeEventAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of ReportRuntimeEvent.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceResetRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceResetRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of ResetRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceResetRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceResetRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of ResetRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceStartRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceStartRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of StartRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceStartRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceStartRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of StartRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceStopRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceStopRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of StopRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceStopRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceStopRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of StopRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceSwitchRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceSwitchRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of SwitchRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceSwitchRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceSwitchRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of SwitchRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceUpdateRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceUpdateRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpdateRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceUpdateRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceUpdateRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpdateRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

PollOnceUpgradeRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> PollOnceUpgradeRuntime(string operationName, CallSettings callSettings = null)

Poll an operation once, using an operationName from a previous invocation of UpgradeRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The result of polling the operation.

PollOnceUpgradeRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> PollOnceUpgradeRuntimeAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an operationName from a previous invocation of UpgradeRuntime.

Parameters
NameDescription
operationNameString

The name of a previously invoked operation. Must not be null or empty.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A task representing the result of polling the operation.

RefreshRuntimeTokenInternal(RefreshRuntimeTokenInternalRequest, CallSettings)

public virtual RefreshRuntimeTokenInternalResponse RefreshRuntimeTokenInternal(RefreshRuntimeTokenInternalRequest request, CallSettings callSettings = null)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
requestRefreshRuntimeTokenInternalRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
RefreshRuntimeTokenInternalResponse

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
RefreshRuntimeTokenInternalRequest request = new RefreshRuntimeTokenInternalRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    VmId = "",
};
// Make the request
RefreshRuntimeTokenInternalResponse response = managedNotebookServiceClient.RefreshRuntimeTokenInternal(request);

RefreshRuntimeTokenInternal(RuntimeName, String, CallSettings)

public virtual RefreshRuntimeTokenInternalResponse RefreshRuntimeTokenInternal(RuntimeName name, string vmId, CallSettings callSettings = null)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

vmIdString

Required. The VM hardware token for authenticating the VM. https://cloud.google.com/compute/docs/instances/verifying-instance-identity

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
RefreshRuntimeTokenInternalResponse

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
string vmId = "";
// Make the request
RefreshRuntimeTokenInternalResponse response = managedNotebookServiceClient.RefreshRuntimeTokenInternal(name, vmId);

RefreshRuntimeTokenInternal(String, String, CallSettings)

public virtual RefreshRuntimeTokenInternalResponse RefreshRuntimeTokenInternal(string name, string vmId, CallSettings callSettings = null)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

vmIdString

Required. The VM hardware token for authenticating the VM. https://cloud.google.com/compute/docs/instances/verifying-instance-identity

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
RefreshRuntimeTokenInternalResponse

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
string vmId = "";
// Make the request
RefreshRuntimeTokenInternalResponse response = managedNotebookServiceClient.RefreshRuntimeTokenInternal(name, vmId);

RefreshRuntimeTokenInternalAsync(RefreshRuntimeTokenInternalRequest, CallSettings)

public virtual Task<RefreshRuntimeTokenInternalResponse> RefreshRuntimeTokenInternalAsync(RefreshRuntimeTokenInternalRequest request, CallSettings callSettings = null)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
requestRefreshRuntimeTokenInternalRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<RefreshRuntimeTokenInternalResponse>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RefreshRuntimeTokenInternalRequest request = new RefreshRuntimeTokenInternalRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    VmId = "",
};
// Make the request
RefreshRuntimeTokenInternalResponse response = await managedNotebookServiceClient.RefreshRuntimeTokenInternalAsync(request);

RefreshRuntimeTokenInternalAsync(RefreshRuntimeTokenInternalRequest, CancellationToken)

public virtual Task<RefreshRuntimeTokenInternalResponse> RefreshRuntimeTokenInternalAsync(RefreshRuntimeTokenInternalRequest request, CancellationToken cancellationToken)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
requestRefreshRuntimeTokenInternalRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<RefreshRuntimeTokenInternalResponse>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RefreshRuntimeTokenInternalRequest request = new RefreshRuntimeTokenInternalRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    VmId = "",
};
// Make the request
RefreshRuntimeTokenInternalResponse response = await managedNotebookServiceClient.RefreshRuntimeTokenInternalAsync(request);

RefreshRuntimeTokenInternalAsync(RuntimeName, String, CallSettings)

public virtual Task<RefreshRuntimeTokenInternalResponse> RefreshRuntimeTokenInternalAsync(RuntimeName name, string vmId, CallSettings callSettings = null)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

vmIdString

Required. The VM hardware token for authenticating the VM. https://cloud.google.com/compute/docs/instances/verifying-instance-identity

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<RefreshRuntimeTokenInternalResponse>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
string vmId = "";
// Make the request
RefreshRuntimeTokenInternalResponse response = await managedNotebookServiceClient.RefreshRuntimeTokenInternalAsync(name, vmId);

RefreshRuntimeTokenInternalAsync(RuntimeName, String, CancellationToken)

public virtual Task<RefreshRuntimeTokenInternalResponse> RefreshRuntimeTokenInternalAsync(RuntimeName name, string vmId, CancellationToken cancellationToken)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

vmIdString

Required. The VM hardware token for authenticating the VM. https://cloud.google.com/compute/docs/instances/verifying-instance-identity

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<RefreshRuntimeTokenInternalResponse>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
string vmId = "";
// Make the request
RefreshRuntimeTokenInternalResponse response = await managedNotebookServiceClient.RefreshRuntimeTokenInternalAsync(name, vmId);

RefreshRuntimeTokenInternalAsync(String, String, CallSettings)

public virtual Task<RefreshRuntimeTokenInternalResponse> RefreshRuntimeTokenInternalAsync(string name, string vmId, CallSettings callSettings = null)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

vmIdString

Required. The VM hardware token for authenticating the VM. https://cloud.google.com/compute/docs/instances/verifying-instance-identity

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<RefreshRuntimeTokenInternalResponse>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
string vmId = "";
// Make the request
RefreshRuntimeTokenInternalResponse response = await managedNotebookServiceClient.RefreshRuntimeTokenInternalAsync(name, vmId);

RefreshRuntimeTokenInternalAsync(String, String, CancellationToken)

public virtual Task<RefreshRuntimeTokenInternalResponse> RefreshRuntimeTokenInternalAsync(string name, string vmId, CancellationToken cancellationToken)

Gets an access token for the consumer service account that the customer attached to the runtime. Only accessible from the tenant instance.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

vmIdString

Required. The VM hardware token for authenticating the VM. https://cloud.google.com/compute/docs/instances/verifying-instance-identity

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<RefreshRuntimeTokenInternalResponse>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
string vmId = "";
// Make the request
RefreshRuntimeTokenInternalResponse response = await managedNotebookServiceClient.RefreshRuntimeTokenInternalAsync(name, vmId);

ReportRuntimeEvent(ReportRuntimeEventRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> ReportRuntimeEvent(ReportRuntimeEventRequest request, CallSettings callSettings = null)

Report and process a runtime event.

Parameters
NameDescription
requestReportRuntimeEventRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
ReportRuntimeEventRequest request = new ReportRuntimeEventRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    VmId = "",
    Event = new Event(),
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.ReportRuntimeEvent(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceReportRuntimeEvent(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ReportRuntimeEvent(RuntimeName, CallSettings)

public virtual Operation<Runtime, OperationMetadata> ReportRuntimeEvent(RuntimeName name, CallSettings callSettings = null)

Report and process a runtime event.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.ReportRuntimeEvent(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceReportRuntimeEvent(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ReportRuntimeEvent(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> ReportRuntimeEvent(string name, CallSettings callSettings = null)

Report and process a runtime event.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.ReportRuntimeEvent(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceReportRuntimeEvent(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ReportRuntimeEventAsync(ReportRuntimeEventRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> ReportRuntimeEventAsync(ReportRuntimeEventRequest request, CallSettings callSettings = null)

Report and process a runtime event.

Parameters
NameDescription
requestReportRuntimeEventRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
ReportRuntimeEventRequest request = new ReportRuntimeEventRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    VmId = "",
    Event = new Event(),
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ReportRuntimeEventAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceReportRuntimeEventAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ReportRuntimeEventAsync(ReportRuntimeEventRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> ReportRuntimeEventAsync(ReportRuntimeEventRequest request, CancellationToken cancellationToken)

Report and process a runtime event.

Parameters
NameDescription
requestReportRuntimeEventRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
ReportRuntimeEventRequest request = new ReportRuntimeEventRequest
{
    RuntimeName = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]"),
    VmId = "",
    Event = new Event(),
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ReportRuntimeEventAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceReportRuntimeEventAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ReportRuntimeEventAsync(RuntimeName, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> ReportRuntimeEventAsync(RuntimeName name, CallSettings callSettings = null)

Report and process a runtime event.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ReportRuntimeEventAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceReportRuntimeEventAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ReportRuntimeEventAsync(RuntimeName, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> ReportRuntimeEventAsync(RuntimeName name, CancellationToken cancellationToken)

Report and process a runtime event.

Parameters
NameDescription
nameRuntimeName

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
RuntimeName name = RuntimeName.FromProjectLocationRuntime("[PROJECT]", "[LOCATION]", "[RUNTIME]");
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ReportRuntimeEventAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceReportRuntimeEventAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ReportRuntimeEventAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> ReportRuntimeEventAsync(string name, CallSettings callSettings = null)

Report and process a runtime event.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ReportRuntimeEventAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceReportRuntimeEventAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ReportRuntimeEventAsync(String, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> ReportRuntimeEventAsync(string name, CancellationToken cancellationToken)

Report and process a runtime event.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/runtimes/[RUNTIME]";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ReportRuntimeEventAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceReportRuntimeEventAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ResetRuntime(ResetRuntimeRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> ResetRuntime(ResetRuntimeRequest request, CallSettings callSettings = null)

Resets a Managed Notebook Runtime.

Parameters
NameDescription
requestResetRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
ResetRuntimeRequest request = new ResetRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.ResetRuntime(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceResetRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ResetRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> ResetRuntime(string name, CallSettings callSettings = null)

Resets a Managed Notebook Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.ResetRuntime(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceResetRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ResetRuntimeAsync(ResetRuntimeRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> ResetRuntimeAsync(ResetRuntimeRequest request, CallSettings callSettings = null)

Resets a Managed Notebook Runtime.

Parameters
NameDescription
requestResetRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
ResetRuntimeRequest request = new ResetRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ResetRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceResetRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ResetRuntimeAsync(ResetRuntimeRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> ResetRuntimeAsync(ResetRuntimeRequest request, CancellationToken cancellationToken)

Resets a Managed Notebook Runtime.

Parameters
NameDescription
requestResetRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
ResetRuntimeRequest request = new ResetRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ResetRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceResetRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ResetRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> ResetRuntimeAsync(string name, CallSettings callSettings = null)

Resets a Managed Notebook Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ResetRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceResetRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

ResetRuntimeAsync(String, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> ResetRuntimeAsync(string name, CancellationToken cancellationToken)

Resets a Managed Notebook Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.ResetRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceResetRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime 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
TypeDescription
Task

A task representing the asynchronous shutdown operation.

Remarks

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.

StartRuntime(StartRuntimeRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> StartRuntime(StartRuntimeRequest request, CallSettings callSettings = null)

Starts a Managed Notebook Runtime. Perform "Start" on GPU instances; "Resume" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
requestStartRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
StartRuntimeRequest request = new StartRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.StartRuntime(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceStartRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StartRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> StartRuntime(string name, CallSettings callSettings = null)

Starts a Managed Notebook Runtime. Perform "Start" on GPU instances; "Resume" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.StartRuntime(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceStartRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StartRuntimeAsync(StartRuntimeRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> StartRuntimeAsync(StartRuntimeRequest request, CallSettings callSettings = null)

Starts a Managed Notebook Runtime. Perform "Start" on GPU instances; "Resume" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
requestStartRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
StartRuntimeRequest request = new StartRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.StartRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceStartRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StartRuntimeAsync(StartRuntimeRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> StartRuntimeAsync(StartRuntimeRequest request, CancellationToken cancellationToken)

Starts a Managed Notebook Runtime. Perform "Start" on GPU instances; "Resume" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
requestStartRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
StartRuntimeRequest request = new StartRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.StartRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceStartRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StartRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> StartRuntimeAsync(string name, CallSettings callSettings = null)

Starts a Managed Notebook Runtime. Perform "Start" on GPU instances; "Resume" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.StartRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceStartRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StartRuntimeAsync(String, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> StartRuntimeAsync(string name, CancellationToken cancellationToken)

Starts a Managed Notebook Runtime. Perform "Start" on GPU instances; "Resume" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.StartRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceStartRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StopRuntime(StopRuntimeRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> StopRuntime(StopRuntimeRequest request, CallSettings callSettings = null)

Stops a Managed Notebook Runtime. Perform "Stop" on GPU instances; "Suspend" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
requestStopRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
StopRuntimeRequest request = new StopRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.StopRuntime(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceStopRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StopRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> StopRuntime(string name, CallSettings callSettings = null)

Stops a Managed Notebook Runtime. Perform "Stop" on GPU instances; "Suspend" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.StopRuntime(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceStopRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StopRuntimeAsync(StopRuntimeRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> StopRuntimeAsync(StopRuntimeRequest request, CallSettings callSettings = null)

Stops a Managed Notebook Runtime. Perform "Stop" on GPU instances; "Suspend" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
requestStopRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
StopRuntimeRequest request = new StopRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.StopRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceStopRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StopRuntimeAsync(StopRuntimeRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> StopRuntimeAsync(StopRuntimeRequest request, CancellationToken cancellationToken)

Stops a Managed Notebook Runtime. Perform "Stop" on GPU instances; "Suspend" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
requestStopRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
StopRuntimeRequest request = new StopRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.StopRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceStopRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StopRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> StopRuntimeAsync(string name, CallSettings callSettings = null)

Stops a Managed Notebook Runtime. Perform "Stop" on GPU instances; "Suspend" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.StopRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceStopRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

StopRuntimeAsync(String, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> StopRuntimeAsync(string name, CancellationToken cancellationToken)

Stops a Managed Notebook Runtime. Perform "Stop" on GPU instances; "Suspend" on CPU instances See: https://cloud.google.com/compute/docs/instances/stop-start-instance https://cloud.google.com/compute/docs/instances/suspend-resume-instance

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.StopRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceStopRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

SwitchRuntime(SwitchRuntimeRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> SwitchRuntime(SwitchRuntimeRequest request, CallSettings callSettings = null)

Switch a Managed Notebook Runtime.

Parameters
NameDescription
requestSwitchRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
SwitchRuntimeRequest request = new SwitchRuntimeRequest
{
    Name = "",
    MachineType = "",
    AcceleratorConfig = new RuntimeAcceleratorConfig(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.SwitchRuntime(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceSwitchRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

SwitchRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> SwitchRuntime(string name, CallSettings callSettings = null)

Switch a Managed Notebook Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.SwitchRuntime(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceSwitchRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

SwitchRuntimeAsync(SwitchRuntimeRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> SwitchRuntimeAsync(SwitchRuntimeRequest request, CallSettings callSettings = null)

Switch a Managed Notebook Runtime.

Parameters
NameDescription
requestSwitchRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
SwitchRuntimeRequest request = new SwitchRuntimeRequest
{
    Name = "",
    MachineType = "",
    AcceleratorConfig = new RuntimeAcceleratorConfig(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.SwitchRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceSwitchRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

SwitchRuntimeAsync(SwitchRuntimeRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> SwitchRuntimeAsync(SwitchRuntimeRequest request, CancellationToken cancellationToken)

Switch a Managed Notebook Runtime.

Parameters
NameDescription
requestSwitchRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
SwitchRuntimeRequest request = new SwitchRuntimeRequest
{
    Name = "",
    MachineType = "",
    AcceleratorConfig = new RuntimeAcceleratorConfig(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.SwitchRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceSwitchRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

SwitchRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> SwitchRuntimeAsync(string name, CallSettings callSettings = null)

Switch a Managed Notebook Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.SwitchRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceSwitchRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

SwitchRuntimeAsync(String, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> SwitchRuntimeAsync(string name, CancellationToken cancellationToken)

Switch a Managed Notebook Runtime.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.SwitchRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceSwitchRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpdateRuntime(Runtime, FieldMask, CallSettings)

public virtual Operation<Runtime, OperationMetadata> UpdateRuntime(Runtime runtime, FieldMask updateMask, CallSettings callSettings = null)

Update Notebook Runtime configuration.

Parameters
NameDescription
runtimeRuntime

Required. The Runtime to be updated.

updateMaskFieldMask

Required. Specifies the path, relative to Runtime, of the field to update. For example, to change the software configuration kernels, the update_mask parameter would be specified as software_config.kernels, and the PATCH request body would specify the new value, as follows:

{ "software_config":{ "kernels": [{ 'repository': 'gcr.io/deeplearning-platform-release/pytorch-gpu', 'tag': 'latest' }], } }

Currently, only the following fields can be updated:

  • software_config.kernels
  • software_config.post_startup_script
  • software_config.custom_gpu_driver_path
  • software_config.idle_shutdown
  • software_config.idle_shutdown_timeout
  • software_config.disable_terminal
callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
Runtime runtime = new Runtime();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.UpdateRuntime(runtime, updateMask);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceUpdateRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpdateRuntime(UpdateRuntimeRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> UpdateRuntime(UpdateRuntimeRequest request, CallSettings callSettings = null)

Update Notebook Runtime configuration.

Parameters
NameDescription
requestUpdateRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
UpdateRuntimeRequest request = new UpdateRuntimeRequest
{
    Runtime = new Runtime(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.UpdateRuntime(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceUpdateRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpdateRuntimeAsync(Runtime, FieldMask, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> UpdateRuntimeAsync(Runtime runtime, FieldMask updateMask, CallSettings callSettings = null)

Update Notebook Runtime configuration.

Parameters
NameDescription
runtimeRuntime

Required. The Runtime to be updated.

updateMaskFieldMask

Required. Specifies the path, relative to Runtime, of the field to update. For example, to change the software configuration kernels, the update_mask parameter would be specified as software_config.kernels, and the PATCH request body would specify the new value, as follows:

{ "software_config":{ "kernels": [{ 'repository': 'gcr.io/deeplearning-platform-release/pytorch-gpu', 'tag': 'latest' }], } }

Currently, only the following fields can be updated:

  • software_config.kernels
  • software_config.post_startup_script
  • software_config.custom_gpu_driver_path
  • software_config.idle_shutdown
  • software_config.idle_shutdown_timeout
  • software_config.disable_terminal
callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
Runtime runtime = new Runtime();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.UpdateRuntimeAsync(runtime, updateMask);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceUpdateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpdateRuntimeAsync(Runtime, FieldMask, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> UpdateRuntimeAsync(Runtime runtime, FieldMask updateMask, CancellationToken cancellationToken)

Update Notebook Runtime configuration.

Parameters
NameDescription
runtimeRuntime

Required. The Runtime to be updated.

updateMaskFieldMask

Required. Specifies the path, relative to Runtime, of the field to update. For example, to change the software configuration kernels, the update_mask parameter would be specified as software_config.kernels, and the PATCH request body would specify the new value, as follows:

{ "software_config":{ "kernels": [{ 'repository': 'gcr.io/deeplearning-platform-release/pytorch-gpu', 'tag': 'latest' }], } }

Currently, only the following fields can be updated:

  • software_config.kernels
  • software_config.post_startup_script
  • software_config.custom_gpu_driver_path
  • software_config.idle_shutdown
  • software_config.idle_shutdown_timeout
  • software_config.disable_terminal
cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
Runtime runtime = new Runtime();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.UpdateRuntimeAsync(runtime, updateMask);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceUpdateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpdateRuntimeAsync(UpdateRuntimeRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> UpdateRuntimeAsync(UpdateRuntimeRequest request, CallSettings callSettings = null)

Update Notebook Runtime configuration.

Parameters
NameDescription
requestUpdateRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateRuntimeRequest request = new UpdateRuntimeRequest
{
    Runtime = new Runtime(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.UpdateRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceUpdateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpdateRuntimeAsync(UpdateRuntimeRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> UpdateRuntimeAsync(UpdateRuntimeRequest request, CancellationToken cancellationToken)

Update Notebook Runtime configuration.

Parameters
NameDescription
requestUpdateRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateRuntimeRequest request = new UpdateRuntimeRequest
{
    Runtime = new Runtime(),
    UpdateMask = new FieldMask(),
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.UpdateRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceUpdateRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpgradeRuntime(UpgradeRuntimeRequest, CallSettings)

public virtual Operation<Runtime, OperationMetadata> UpgradeRuntime(UpgradeRuntimeRequest request, CallSettings callSettings = null)

Upgrades a Managed Notebook Runtime to the latest version.

Parameters
NameDescription
requestUpgradeRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
UpgradeRuntimeRequest request = new UpgradeRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.UpgradeRuntime(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceUpgradeRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpgradeRuntime(String, CallSettings)

public virtual Operation<Runtime, OperationMetadata> UpgradeRuntime(string name, CallSettings callSettings = null)

Upgrades a Managed Notebook Runtime to the latest version.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Operation<Runtime, OperationMetadata>

The RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = ManagedNotebookServiceClient.Create();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = managedNotebookServiceClient.UpgradeRuntime(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = managedNotebookServiceClient.PollOnceUpgradeRuntime(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpgradeRuntimeAsync(UpgradeRuntimeRequest, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> UpgradeRuntimeAsync(UpgradeRuntimeRequest request, CallSettings callSettings = null)

Upgrades a Managed Notebook Runtime to the latest version.

Parameters
NameDescription
requestUpgradeRuntimeRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
UpgradeRuntimeRequest request = new UpgradeRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.UpgradeRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceUpgradeRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpgradeRuntimeAsync(UpgradeRuntimeRequest, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> UpgradeRuntimeAsync(UpgradeRuntimeRequest request, CancellationToken cancellationToken)

Upgrades a Managed Notebook Runtime to the latest version.

Parameters
NameDescription
requestUpgradeRuntimeRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
UpgradeRuntimeRequest request = new UpgradeRuntimeRequest
{
    Name = "",
    RequestId = "",
};
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.UpgradeRuntimeAsync(request);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceUpgradeRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpgradeRuntimeAsync(String, CallSettings)

public virtual Task<Operation<Runtime, OperationMetadata>> UpgradeRuntimeAsync(string name, CallSettings callSettings = null)

Upgrades a Managed Notebook Runtime to the latest version.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.UpgradeRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceUpgradeRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}

UpgradeRuntimeAsync(String, CancellationToken)

public virtual Task<Operation<Runtime, OperationMetadata>> UpgradeRuntimeAsync(string name, CancellationToken cancellationToken)

Upgrades a Managed Notebook Runtime to the latest version.

Parameters
NameDescription
nameString

Required. Format: projects/{project_id}/locations/{location}/runtimes/{runtime_id}

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
Task<Operation<Runtime, OperationMetadata>>

A Task containing the RPC response.

Example
// Create client
ManagedNotebookServiceClient managedNotebookServiceClient = await ManagedNotebookServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "";
// Make the request
Operation<Runtime, OperationMetadata> response = await managedNotebookServiceClient.UpgradeRuntimeAsync(name);

// Poll until the returned long-running operation is complete
Operation<Runtime, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Runtime 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<Runtime, OperationMetadata> retrievedResponse = await managedNotebookServiceClient.PollOnceUpgradeRuntimeAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    Runtime retrievedResult = retrievedResponse.Result;
}