public abstract class HypercomputeClusterClientReference documentation and code samples for the Cluster Director v1beta API class HypercomputeClusterClient.
HypercomputeCluster client wrapper, for convenient use.
Derived Types
Namespace
Google.Cloud.HypercomputeCluster.V1BetaAssembly
Google.Cloud.HypercomputeCluster.V1Beta.dll
Remarks
Service describing handlers for resources
Properties
CreateClusterOperationsClient
public virtual OperationsClient CreateClusterOperationsClient { get; }The long-running operations client for CreateCluster.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
DefaultEndpoint
public static string DefaultEndpoint { get; }The default endpoint for the HypercomputeCluster service, which is a host of "hypercomputecluster.googleapis.com" and a port of 443.
| Property Value | |
|---|---|
| Type | Description |
string |
|
DefaultScopes
public static IReadOnlyList<string> DefaultScopes { get; }The default HypercomputeCluster scopes.
| Property Value | |
|---|---|
| Type | Description |
IReadOnlyListstring |
|
The default HypercomputeCluster scopes are:
DeleteClusterOperationsClient
public virtual OperationsClient DeleteClusterOperationsClient { get; }The long-running operations client for DeleteCluster.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
GrpcClient
public virtual HypercomputeCluster.HypercomputeClusterClient GrpcClient { get; }The underlying gRPC HypercomputeCluster client
| Property Value | |
|---|---|
| Type | Description |
HypercomputeClusterHypercomputeClusterClient |
|
LocationsClient
public virtual LocationsClient LocationsClient { get; }The LocationsClient associated with this client.
| Property Value | |
|---|---|
| Type | Description |
LocationsClient |
|
ServiceMetadata
public static ServiceMetadata ServiceMetadata { get; }The service metadata associated with this client type.
| Property Value | |
|---|---|
| Type | Description |
ServiceMetadata |
|
UpdateClusterOperationsClient
public virtual OperationsClient UpdateClusterOperationsClient { get; }The long-running operations client for UpdateCluster.
| Property Value | |
|---|---|
| Type | Description |
OperationsClient |
|
Methods
Create()
public static HypercomputeClusterClient Create()Synchronously creates a HypercomputeClusterClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use HypercomputeClusterClientBuilder.
| Returns | |
|---|---|
| Type | Description |
HypercomputeClusterClient |
The created HypercomputeClusterClient. |
CreateAsync(CancellationToken)
public static Task<HypercomputeClusterClient> CreateAsync(CancellationToken cancellationToken = default)Asynchronously creates a HypercomputeClusterClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use HypercomputeClusterClientBuilder.
| Parameter | |
|---|---|
| Name | Description |
cancellationToken |
CancellationTokenThe CancellationToken to use while creating the client. |
| Returns | |
|---|---|
| Type | Description |
TaskHypercomputeClusterClient |
The task representing the created HypercomputeClusterClient. |
CreateCluster(LocationName, Cluster, string, CallSettings)
public virtual Operation<Cluster, OperationMetadata> CreateCluster(LocationName parent, Cluster cluster, string clusterId, CallSettings callSettings = null)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Parent location in which the cluster should be created, in the
format |
cluster |
ClusterRequired. Cluster to create. |
clusterId |
stringRequired. ID of the cluster to create. Must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters). |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationClusterOperationMetadata |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Cluster cluster = new Cluster();
string clusterId = "";
// Make the request
Operation<Cluster, OperationMetadata> response = hypercomputeClusterClient.CreateCluster(parent, cluster, clusterId);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = hypercomputeClusterClient.PollOnceCreateCluster(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
CreateCluster(CreateClusterRequest, CallSettings)
public virtual Operation<Cluster, OperationMetadata> CreateCluster(CreateClusterRequest request, CallSettings callSettings = null)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
CreateClusterRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationClusterOperationMetadata |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
CreateClusterRequest request = new CreateClusterRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
ClusterId = "",
Cluster = new Cluster(),
RequestId = "",
};
// Make the request
Operation<Cluster, OperationMetadata> response = hypercomputeClusterClient.CreateCluster(request);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = hypercomputeClusterClient.PollOnceCreateCluster(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
CreateCluster(string, Cluster, string, CallSettings)
public virtual Operation<Cluster, OperationMetadata> CreateCluster(string parent, Cluster cluster, string clusterId, CallSettings callSettings = null)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Parent location in which the cluster should be created, in the
format |
cluster |
ClusterRequired. Cluster to create. |
clusterId |
stringRequired. ID of the cluster to create. Must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters). |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationClusterOperationMetadata |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Cluster cluster = new Cluster();
string clusterId = "";
// Make the request
Operation<Cluster, OperationMetadata> response = hypercomputeClusterClient.CreateCluster(parent, cluster, clusterId);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = hypercomputeClusterClient.PollOnceCreateCluster(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
CreateClusterAsync(LocationName, Cluster, string, CallSettings)
public virtual Task<Operation<Cluster, OperationMetadata>> CreateClusterAsync(LocationName parent, Cluster cluster, string clusterId, CallSettings callSettings = null)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Parent location in which the cluster should be created, in the
format |
cluster |
ClusterRequired. Cluster to create. |
clusterId |
stringRequired. ID of the cluster to create. Must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters). |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Cluster cluster = new Cluster();
string clusterId = "";
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.CreateClusterAsync(parent, cluster, clusterId);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceCreateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
CreateClusterAsync(LocationName, Cluster, string, CancellationToken)
public virtual Task<Operation<Cluster, OperationMetadata>> CreateClusterAsync(LocationName parent, Cluster cluster, string clusterId, CancellationToken cancellationToken)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Parent location in which the cluster should be created, in the
format |
cluster |
ClusterRequired. Cluster to create. |
clusterId |
stringRequired. ID of the cluster to create. Must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters). |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
Cluster cluster = new Cluster();
string clusterId = "";
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.CreateClusterAsync(parent, cluster, clusterId);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceCreateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
CreateClusterAsync(CreateClusterRequest, CallSettings)
public virtual Task<Operation<Cluster, OperationMetadata>> CreateClusterAsync(CreateClusterRequest request, CallSettings callSettings = null)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
CreateClusterRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
CreateClusterRequest request = new CreateClusterRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
ClusterId = "",
Cluster = new Cluster(),
RequestId = "",
};
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.CreateClusterAsync(request);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceCreateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
CreateClusterAsync(CreateClusterRequest, CancellationToken)
public virtual Task<Operation<Cluster, OperationMetadata>> CreateClusterAsync(CreateClusterRequest request, CancellationToken cancellationToken)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
CreateClusterRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
CreateClusterRequest request = new CreateClusterRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
ClusterId = "",
Cluster = new Cluster(),
RequestId = "",
};
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.CreateClusterAsync(request);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceCreateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
CreateClusterAsync(string, Cluster, string, CallSettings)
public virtual Task<Operation<Cluster, OperationMetadata>> CreateClusterAsync(string parent, Cluster cluster, string clusterId, CallSettings callSettings = null)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Parent location in which the cluster should be created, in the
format |
cluster |
ClusterRequired. Cluster to create. |
clusterId |
stringRequired. ID of the cluster to create. Must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters). |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Cluster cluster = new Cluster();
string clusterId = "";
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.CreateClusterAsync(parent, cluster, clusterId);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceCreateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
CreateClusterAsync(string, Cluster, string, CancellationToken)
public virtual Task<Operation<Cluster, OperationMetadata>> CreateClusterAsync(string parent, Cluster cluster, string clusterId, CancellationToken cancellationToken)Creates a new Cluster in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Parent location in which the cluster should be created, in the
format |
cluster |
ClusterRequired. Cluster to create. |
clusterId |
stringRequired. ID of the cluster to create. Must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters). |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
Cluster cluster = new Cluster();
string clusterId = "";
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.CreateClusterAsync(parent, cluster, clusterId);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceCreateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
DeleteCluster(ClusterName, CallSettings)
public virtual Operation<Empty, OperationMetadata> DeleteCluster(ClusterName name, CallSettings callSettings = null)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
ClusterNameRequired. Name of the cluster to delete, in the format
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationEmptyOperationMetadata |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
ClusterName name = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]");
// Make the request
Operation<Empty, OperationMetadata> response = hypercomputeClusterClient.DeleteCluster(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 = hypercomputeClusterClient.PollOnceDeleteCluster(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;
}
DeleteCluster(DeleteClusterRequest, CallSettings)
public virtual Operation<Empty, OperationMetadata> DeleteCluster(DeleteClusterRequest request, CallSettings callSettings = null)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
DeleteClusterRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationEmptyOperationMetadata |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
DeleteClusterRequest request = new DeleteClusterRequest
{
ClusterName = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]"),
RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = hypercomputeClusterClient.DeleteCluster(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 = hypercomputeClusterClient.PollOnceDeleteCluster(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;
}
DeleteCluster(string, CallSettings)
public virtual Operation<Empty, OperationMetadata> DeleteCluster(string name, CallSettings callSettings = null)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Name of the cluster to delete, in the format
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationEmptyOperationMetadata |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/clusters/[CLUSTER]";
// Make the request
Operation<Empty, OperationMetadata> response = hypercomputeClusterClient.DeleteCluster(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 = hypercomputeClusterClient.PollOnceDeleteCluster(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;
}
DeleteClusterAsync(ClusterName, CallSettings)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteClusterAsync(ClusterName name, CallSettings callSettings = null)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
ClusterNameRequired. Name of the cluster to delete, in the format
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
ClusterName name = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]");
// Make the request
Operation<Empty, OperationMetadata> response = await hypercomputeClusterClient.DeleteClusterAsync(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 hypercomputeClusterClient.PollOnceDeleteClusterAsync(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;
}
DeleteClusterAsync(ClusterName, CancellationToken)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteClusterAsync(ClusterName name, CancellationToken cancellationToken)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
ClusterNameRequired. Name of the cluster to delete, in the format
|
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
ClusterName name = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]");
// Make the request
Operation<Empty, OperationMetadata> response = await hypercomputeClusterClient.DeleteClusterAsync(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 hypercomputeClusterClient.PollOnceDeleteClusterAsync(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;
}
DeleteClusterAsync(DeleteClusterRequest, CallSettings)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteClusterAsync(DeleteClusterRequest request, CallSettings callSettings = null)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
DeleteClusterRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
DeleteClusterRequest request = new DeleteClusterRequest
{
ClusterName = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]"),
RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await hypercomputeClusterClient.DeleteClusterAsync(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 hypercomputeClusterClient.PollOnceDeleteClusterAsync(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;
}
DeleteClusterAsync(DeleteClusterRequest, CancellationToken)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteClusterAsync(DeleteClusterRequest request, CancellationToken cancellationToken)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
DeleteClusterRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
DeleteClusterRequest request = new DeleteClusterRequest
{
ClusterName = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]"),
RequestId = "",
};
// Make the request
Operation<Empty, OperationMetadata> response = await hypercomputeClusterClient.DeleteClusterAsync(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 hypercomputeClusterClient.PollOnceDeleteClusterAsync(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;
}
DeleteClusterAsync(string, CallSettings)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteClusterAsync(string name, CallSettings callSettings = null)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Name of the cluster to delete, in the format
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/clusters/[CLUSTER]";
// Make the request
Operation<Empty, OperationMetadata> response = await hypercomputeClusterClient.DeleteClusterAsync(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 hypercomputeClusterClient.PollOnceDeleteClusterAsync(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;
}
DeleteClusterAsync(string, CancellationToken)
public virtual Task<Operation<Empty, OperationMetadata>> DeleteClusterAsync(string name, CancellationToken cancellationToken)Deletes a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Name of the cluster to delete, in the format
|
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/clusters/[CLUSTER]";
// Make the request
Operation<Empty, OperationMetadata> response = await hypercomputeClusterClient.DeleteClusterAsync(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 hypercomputeClusterClient.PollOnceDeleteClusterAsync(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;
}
GetCluster(ClusterName, CallSettings)
public virtual Cluster GetCluster(ClusterName name, CallSettings callSettings = null)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
ClusterNameRequired. Name of the cluster to retrieve, in the format
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
Cluster |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
ClusterName name = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]");
// Make the request
Cluster response = hypercomputeClusterClient.GetCluster(name);
GetCluster(GetClusterRequest, CallSettings)
public virtual Cluster GetCluster(GetClusterRequest request, CallSettings callSettings = null)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
GetClusterRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
Cluster |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
GetClusterRequest request = new GetClusterRequest
{
ClusterName = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]"),
};
// Make the request
Cluster response = hypercomputeClusterClient.GetCluster(request);
GetCluster(string, CallSettings)
public virtual Cluster GetCluster(string name, CallSettings callSettings = null)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Name of the cluster to retrieve, in the format
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
Cluster |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/clusters/[CLUSTER]";
// Make the request
Cluster response = hypercomputeClusterClient.GetCluster(name);
GetClusterAsync(ClusterName, CallSettings)
public virtual Task<Cluster> GetClusterAsync(ClusterName name, CallSettings callSettings = null)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
ClusterNameRequired. Name of the cluster to retrieve, in the format
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskCluster |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
ClusterName name = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]");
// Make the request
Cluster response = await hypercomputeClusterClient.GetClusterAsync(name);
GetClusterAsync(ClusterName, CancellationToken)
public virtual Task<Cluster> GetClusterAsync(ClusterName name, CancellationToken cancellationToken)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
ClusterNameRequired. Name of the cluster to retrieve, in the format
|
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskCluster |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
ClusterName name = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]");
// Make the request
Cluster response = await hypercomputeClusterClient.GetClusterAsync(name);
GetClusterAsync(GetClusterRequest, CallSettings)
public virtual Task<Cluster> GetClusterAsync(GetClusterRequest request, CallSettings callSettings = null)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
GetClusterRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskCluster |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
GetClusterRequest request = new GetClusterRequest
{
ClusterName = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]"),
};
// Make the request
Cluster response = await hypercomputeClusterClient.GetClusterAsync(request);
GetClusterAsync(GetClusterRequest, CancellationToken)
public virtual Task<Cluster> GetClusterAsync(GetClusterRequest request, CancellationToken cancellationToken)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
GetClusterRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskCluster |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
GetClusterRequest request = new GetClusterRequest
{
ClusterName = ClusterName.FromProjectLocationCluster("[PROJECT]", "[LOCATION]", "[CLUSTER]"),
};
// Make the request
Cluster response = await hypercomputeClusterClient.GetClusterAsync(request);
GetClusterAsync(string, CallSettings)
public virtual Task<Cluster> GetClusterAsync(string name, CallSettings callSettings = null)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Name of the cluster to retrieve, in the format
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskCluster |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/clusters/[CLUSTER]";
// Make the request
Cluster response = await hypercomputeClusterClient.GetClusterAsync(name);
GetClusterAsync(string, CancellationToken)
public virtual Task<Cluster> GetClusterAsync(string name, CancellationToken cancellationToken)Gets details of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
name |
stringRequired. Name of the cluster to retrieve, in the format
|
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskCluster |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/clusters/[CLUSTER]";
// Make the request
Cluster response = await hypercomputeClusterClient.GetClusterAsync(name);
ListClusters(LocationName, string, int?, CallSettings)
public virtual PagedEnumerable<ListClustersResponse, Cluster> ListClusters(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)Lists Clusters in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Parent location of the clusters to list, in the format
|
pageToken |
stringThe token returned from the previous request. A value of |
pageSize |
intThe size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedEnumerableListClustersResponseCluster |
A pageable sequence of Cluster resources. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedEnumerable<ListClustersResponse, Cluster> response = hypercomputeClusterClient.ListClusters(parent);
// Iterate over all response items, lazily performing RPCs as required
foreach (Cluster 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 (ListClustersResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Cluster 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<Cluster> 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 (Cluster 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;
ListClusters(ListClustersRequest, CallSettings)
public virtual PagedEnumerable<ListClustersResponse, Cluster> ListClusters(ListClustersRequest request, CallSettings callSettings = null)Lists Clusters in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
ListClustersRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedEnumerableListClustersResponseCluster |
A pageable sequence of Cluster resources. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
ListClustersRequest request = new ListClustersRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
Filter = "",
OrderBy = "",
};
// Make the request
PagedEnumerable<ListClustersResponse, Cluster> response = hypercomputeClusterClient.ListClusters(request);
// Iterate over all response items, lazily performing RPCs as required
foreach (Cluster 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 (ListClustersResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Cluster 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<Cluster> 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 (Cluster 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;
ListClusters(string, string, int?, CallSettings)
public virtual PagedEnumerable<ListClustersResponse, Cluster> ListClusters(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)Lists Clusters in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Parent location of the clusters to list, in the format
|
pageToken |
stringThe token returned from the previous request. A value of |
pageSize |
intThe size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedEnumerableListClustersResponseCluster |
A pageable sequence of Cluster resources. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedEnumerable<ListClustersResponse, Cluster> response = hypercomputeClusterClient.ListClusters(parent);
// Iterate over all response items, lazily performing RPCs as required
foreach (Cluster 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 (ListClustersResponse page in response.AsRawResponses())
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Cluster 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<Cluster> 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 (Cluster 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;
ListClustersAsync(LocationName, string, int?, CallSettings)
public virtual PagedAsyncEnumerable<ListClustersResponse, Cluster> ListClustersAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)Lists Clusters in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
LocationNameRequired. Parent location of the clusters to list, in the format
|
pageToken |
stringThe token returned from the previous request. A value of |
pageSize |
intThe size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedAsyncEnumerableListClustersResponseCluster |
A pageable asynchronous sequence of Cluster resources. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
// Make the request
PagedAsyncEnumerable<ListClustersResponse, Cluster> response = hypercomputeClusterClient.ListClustersAsync(parent);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Cluster 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((ListClustersResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Cluster 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<Cluster> 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 (Cluster 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;
ListClustersAsync(ListClustersRequest, CallSettings)
public virtual PagedAsyncEnumerable<ListClustersResponse, Cluster> ListClustersAsync(ListClustersRequest request, CallSettings callSettings = null)Lists Clusters in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
request |
ListClustersRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedAsyncEnumerableListClustersResponseCluster |
A pageable asynchronous sequence of Cluster resources. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
ListClustersRequest request = new ListClustersRequest
{
ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
Filter = "",
OrderBy = "",
};
// Make the request
PagedAsyncEnumerable<ListClustersResponse, Cluster> response = hypercomputeClusterClient.ListClustersAsync(request);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Cluster 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((ListClustersResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Cluster 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<Cluster> 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 (Cluster 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;
ListClustersAsync(string, string, int?, CallSettings)
public virtual PagedAsyncEnumerable<ListClustersResponse, Cluster> ListClustersAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)Lists Clusters in a given project and location.
| Parameters | |
|---|---|
| Name | Description |
parent |
stringRequired. Parent location of the clusters to list, in the format
|
pageToken |
stringThe token returned from the previous request. A value of |
pageSize |
intThe size of page to request. The response will not be larger than this, but may be smaller. A value of
|
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
PagedAsyncEnumerableListClustersResponseCluster |
A pageable asynchronous sequence of Cluster resources. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
// Make the request
PagedAsyncEnumerable<ListClustersResponse, Cluster> response = hypercomputeClusterClient.ListClustersAsync(parent);
// Iterate over all response items, lazily performing RPCs as required
await response.ForEachAsync((Cluster 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((ListClustersResponse page) =>
{
// Do something with each page of items
Console.WriteLine("A page of results:");
foreach (Cluster 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<Cluster> 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 (Cluster 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;
PollOnceCreateCluster(string, CallSettings)
public virtual Operation<Cluster, OperationMetadata> PollOnceCreateCluster(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of CreateCluster.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationClusterOperationMetadata |
The result of polling the operation. |
PollOnceCreateClusterAsync(string, CallSettings)
public virtual Task<Operation<Cluster, OperationMetadata>> PollOnceCreateClusterAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
CreateCluster.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A task representing the result of polling the operation. |
PollOnceDeleteCluster(string, CallSettings)
public virtual Operation<Empty, OperationMetadata> PollOnceDeleteCluster(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of DeleteCluster.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationEmptyOperationMetadata |
The result of polling the operation. |
PollOnceDeleteClusterAsync(string, CallSettings)
public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteClusterAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
DeleteCluster.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationEmptyOperationMetadata |
A task representing the result of polling the operation. |
PollOnceUpdateCluster(string, CallSettings)
public virtual Operation<Cluster, OperationMetadata> PollOnceUpdateCluster(string operationName, CallSettings callSettings = null)Poll an operation once, using an operationName from a previous invocation of UpdateCluster.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationClusterOperationMetadata |
The result of polling the operation. |
PollOnceUpdateClusterAsync(string, CallSettings)
public virtual Task<Operation<Cluster, OperationMetadata>> PollOnceUpdateClusterAsync(string operationName, CallSettings callSettings = null)Asynchronously poll an operation once, using an operationName from a previous invocation of
UpdateCluster.
| Parameters | |
|---|---|
| Name | Description |
operationName |
stringThe name of a previously invoked operation. Must not be |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A task representing the result of polling the operation. |
ShutdownDefaultChannelsAsync()
public static Task ShutdownDefaultChannelsAsync()Shuts down any channels automatically created by Create() and CreateAsync(CancellationToken). Channels which weren't automatically created are not affected.
| Returns | |
|---|---|
| Type | Description |
Task |
A task representing the asynchronous shutdown operation. |
After calling this method, further calls to Create() and CreateAsync(CancellationToken) will create new channels, which could in turn be shut down by another call to this method.
UpdateCluster(Cluster, FieldMask, CallSettings)
public virtual Operation<Cluster, OperationMetadata> UpdateCluster(Cluster cluster, FieldMask updateMask, CallSettings callSettings = null)Updates the parameters of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
cluster |
ClusterRequired. Cluster to update. |
updateMask |
FieldMaskOptional. Mask specifying which fields in the cluster to update. All paths must be specified explicitly - wildcards are not supported. At least one path must be provided. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationClusterOperationMetadata |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
Cluster cluster = new Cluster();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Cluster, OperationMetadata> response = hypercomputeClusterClient.UpdateCluster(cluster, updateMask);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = hypercomputeClusterClient.PollOnceUpdateCluster(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
UpdateCluster(UpdateClusterRequest, CallSettings)
public virtual Operation<Cluster, OperationMetadata> UpdateCluster(UpdateClusterRequest request, CallSettings callSettings = null)Updates the parameters of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
UpdateClusterRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
OperationClusterOperationMetadata |
The RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = HypercomputeClusterClient.Create();
// Initialize request argument(s)
UpdateClusterRequest request = new UpdateClusterRequest
{
UpdateMask = new FieldMask(),
Cluster = new Cluster(),
RequestId = "",
};
// Make the request
Operation<Cluster, OperationMetadata> response = hypercomputeClusterClient.UpdateCluster(request);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = hypercomputeClusterClient.PollOnceUpdateCluster(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
UpdateClusterAsync(Cluster, FieldMask, CallSettings)
public virtual Task<Operation<Cluster, OperationMetadata>> UpdateClusterAsync(Cluster cluster, FieldMask updateMask, CallSettings callSettings = null)Updates the parameters of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
cluster |
ClusterRequired. Cluster to update. |
updateMask |
FieldMaskOptional. Mask specifying which fields in the cluster to update. All paths must be specified explicitly - wildcards are not supported. At least one path must be provided. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
Cluster cluster = new Cluster();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.UpdateClusterAsync(cluster, updateMask);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceUpdateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
UpdateClusterAsync(Cluster, FieldMask, CancellationToken)
public virtual Task<Operation<Cluster, OperationMetadata>> UpdateClusterAsync(Cluster cluster, FieldMask updateMask, CancellationToken cancellationToken)Updates the parameters of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
cluster |
ClusterRequired. Cluster to update. |
updateMask |
FieldMaskOptional. Mask specifying which fields in the cluster to update. All paths must be specified explicitly - wildcards are not supported. At least one path must be provided. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
Cluster cluster = new Cluster();
FieldMask updateMask = new FieldMask();
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.UpdateClusterAsync(cluster, updateMask);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceUpdateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
UpdateClusterAsync(UpdateClusterRequest, CallSettings)
public virtual Task<Operation<Cluster, OperationMetadata>> UpdateClusterAsync(UpdateClusterRequest request, CallSettings callSettings = null)Updates the parameters of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
UpdateClusterRequestThe request object containing all of the parameters for the API call. |
callSettings |
CallSettingsIf not null, applies overrides to this RPC call. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
UpdateClusterRequest request = new UpdateClusterRequest
{
UpdateMask = new FieldMask(),
Cluster = new Cluster(),
RequestId = "",
};
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.UpdateClusterAsync(request);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceUpdateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}
UpdateClusterAsync(UpdateClusterRequest, CancellationToken)
public virtual Task<Operation<Cluster, OperationMetadata>> UpdateClusterAsync(UpdateClusterRequest request, CancellationToken cancellationToken)Updates the parameters of a single Cluster.
| Parameters | |
|---|---|
| Name | Description |
request |
UpdateClusterRequestThe request object containing all of the parameters for the API call. |
cancellationToken |
CancellationTokenA CancellationToken to use for this RPC. |
| Returns | |
|---|---|
| Type | Description |
TaskOperationClusterOperationMetadata |
A Task containing the RPC response. |
// Create client
HypercomputeClusterClient hypercomputeClusterClient = await HypercomputeClusterClient.CreateAsync();
// Initialize request argument(s)
UpdateClusterRequest request = new UpdateClusterRequest
{
UpdateMask = new FieldMask(),
Cluster = new Cluster(),
RequestId = "",
};
// Make the request
Operation<Cluster, OperationMetadata> response = await hypercomputeClusterClient.UpdateClusterAsync(request);
// Poll until the returned long-running operation is complete
Operation<Cluster, OperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
Cluster 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<Cluster, OperationMetadata> retrievedResponse = await hypercomputeClusterClient.PollOnceUpdateClusterAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
Cluster retrievedResult = retrievedResponse.Result;
}