Package com.google.cloud.workstations.v1beta (0.3.0)

A client to Cloud Workstations API

The interfaces provided are listed below, along with usage samples.

WorkstationsClient

Service Description: Service for interacting with Cloud Workstations.

Sample for WorkstationsClient:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (WorkstationsClient workstationsClient = WorkstationsClient.create()) {
   WorkstationClusterName name =
       WorkstationClusterName.of("[PROJECT]", "[LOCATION]", "[WORKSTATION_CLUSTER]");
   WorkstationCluster response = workstationsClient.getWorkstationCluster(name);
 }
 

Classes

CreateWorkstationClusterRequest

Message for creating a CreateWorkstationCluster.

Protobuf type google.cloud.workstations.v1beta.CreateWorkstationClusterRequest

CreateWorkstationClusterRequest.Builder

Message for creating a CreateWorkstationCluster.

Protobuf type google.cloud.workstations.v1beta.CreateWorkstationClusterRequest

CreateWorkstationConfigRequest

Message for creating a CreateWorkstationConfig.

Protobuf type google.cloud.workstations.v1beta.CreateWorkstationConfigRequest

CreateWorkstationConfigRequest.Builder

Message for creating a CreateWorkstationConfig.

Protobuf type google.cloud.workstations.v1beta.CreateWorkstationConfigRequest

CreateWorkstationRequest

Message for creating a CreateWorkstation.

Protobuf type google.cloud.workstations.v1beta.CreateWorkstationRequest

CreateWorkstationRequest.Builder

Message for creating a CreateWorkstation.

Protobuf type google.cloud.workstations.v1beta.CreateWorkstationRequest

DeleteWorkstationClusterRequest

Message for deleting a workstation cluster.

Protobuf type google.cloud.workstations.v1beta.DeleteWorkstationClusterRequest

DeleteWorkstationClusterRequest.Builder

Message for deleting a workstation cluster.

Protobuf type google.cloud.workstations.v1beta.DeleteWorkstationClusterRequest

DeleteWorkstationConfigRequest

Message for deleting a workstation configuration.

Protobuf type google.cloud.workstations.v1beta.DeleteWorkstationConfigRequest

DeleteWorkstationConfigRequest.Builder

Message for deleting a workstation configuration.

Protobuf type google.cloud.workstations.v1beta.DeleteWorkstationConfigRequest

DeleteWorkstationRequest

Request message for DeleteWorkstation.

Protobuf type google.cloud.workstations.v1beta.DeleteWorkstationRequest

DeleteWorkstationRequest.Builder

Request message for DeleteWorkstation.

Protobuf type google.cloud.workstations.v1beta.DeleteWorkstationRequest

GenerateAccessTokenRequest

Request message for GenerateAccessToken.

Protobuf type google.cloud.workstations.v1beta.GenerateAccessTokenRequest

GenerateAccessTokenRequest.Builder

Request message for GenerateAccessToken.

Protobuf type google.cloud.workstations.v1beta.GenerateAccessTokenRequest

GenerateAccessTokenResponse

Response message for GenerateAccessToken.

Protobuf type google.cloud.workstations.v1beta.GenerateAccessTokenResponse

GenerateAccessTokenResponse.Builder

Response message for GenerateAccessToken.

Protobuf type google.cloud.workstations.v1beta.GenerateAccessTokenResponse

GetWorkstationClusterRequest

Request message for GetWorkstationCluster.

Protobuf type google.cloud.workstations.v1beta.GetWorkstationClusterRequest

GetWorkstationClusterRequest.Builder

Request message for GetWorkstationCluster.

Protobuf type google.cloud.workstations.v1beta.GetWorkstationClusterRequest

GetWorkstationConfigRequest

Request message for GetWorkstationConfig.

Protobuf type google.cloud.workstations.v1beta.GetWorkstationConfigRequest

GetWorkstationConfigRequest.Builder

Request message for GetWorkstationConfig.

Protobuf type google.cloud.workstations.v1beta.GetWorkstationConfigRequest

GetWorkstationRequest

Request message for GetWorkstation.

Protobuf type google.cloud.workstations.v1beta.GetWorkstationRequest

GetWorkstationRequest.Builder

Request message for GetWorkstation.

Protobuf type google.cloud.workstations.v1beta.GetWorkstationRequest

ListUsableWorkstationConfigsRequest

Request message for ListUsableWorkstationConfigs.

Protobuf type google.cloud.workstations.v1beta.ListUsableWorkstationConfigsRequest

ListUsableWorkstationConfigsRequest.Builder

Request message for ListUsableWorkstationConfigs.

Protobuf type google.cloud.workstations.v1beta.ListUsableWorkstationConfigsRequest

ListUsableWorkstationConfigsResponse

Response message for ListUsableWorkstationConfigs.

Protobuf type google.cloud.workstations.v1beta.ListUsableWorkstationConfigsResponse

ListUsableWorkstationConfigsResponse.Builder

Response message for ListUsableWorkstationConfigs.

Protobuf type google.cloud.workstations.v1beta.ListUsableWorkstationConfigsResponse

ListUsableWorkstationsRequest

Request message for ListUsableWorkstations.

Protobuf type google.cloud.workstations.v1beta.ListUsableWorkstationsRequest

ListUsableWorkstationsRequest.Builder

Request message for ListUsableWorkstations.

Protobuf type google.cloud.workstations.v1beta.ListUsableWorkstationsRequest

ListUsableWorkstationsResponse

Response message for ListUsableWorkstations.

Protobuf type google.cloud.workstations.v1beta.ListUsableWorkstationsResponse

ListUsableWorkstationsResponse.Builder

Response message for ListUsableWorkstations.

Protobuf type google.cloud.workstations.v1beta.ListUsableWorkstationsResponse

ListWorkstationClustersRequest

Request message for ListWorkstationClusters.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationClustersRequest

ListWorkstationClustersRequest.Builder

Request message for ListWorkstationClusters.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationClustersRequest

ListWorkstationClustersResponse

Response message for ListWorkstationClusters.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationClustersResponse

ListWorkstationClustersResponse.Builder

Response message for ListWorkstationClusters.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationClustersResponse

ListWorkstationConfigsRequest

Request message for ListWorkstationConfigs.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationConfigsRequest

ListWorkstationConfigsRequest.Builder

Request message for ListWorkstationConfigs.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationConfigsRequest

ListWorkstationConfigsResponse

Response message for ListWorkstationConfigs.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationConfigsResponse

ListWorkstationConfigsResponse.Builder

Response message for ListWorkstationConfigs.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationConfigsResponse

ListWorkstationsRequest

Request message for ListWorkstations.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationsRequest

ListWorkstationsRequest.Builder

Request message for ListWorkstations.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationsRequest

ListWorkstationsResponse

Response message for ListWorkstations.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationsResponse

ListWorkstationsResponse.Builder

Response message for ListWorkstations.

Protobuf type google.cloud.workstations.v1beta.ListWorkstationsResponse

LocationName

LocationName.Builder

Builder for projects/{project}/locations/{location}.

OperationMetadata

Metadata for long-running operations.

Protobuf type google.cloud.workstations.v1beta.OperationMetadata

OperationMetadata.Builder

Metadata for long-running operations.

Protobuf type google.cloud.workstations.v1beta.OperationMetadata

StartWorkstationRequest

Request message for StartWorkstation.

Protobuf type google.cloud.workstations.v1beta.StartWorkstationRequest

StartWorkstationRequest.Builder

Request message for StartWorkstation.

Protobuf type google.cloud.workstations.v1beta.StartWorkstationRequest

StopWorkstationRequest

Request message for StopWorkstation.

Protobuf type google.cloud.workstations.v1beta.StopWorkstationRequest

StopWorkstationRequest.Builder

Request message for StopWorkstation.

Protobuf type google.cloud.workstations.v1beta.StopWorkstationRequest

UpdateWorkstationClusterRequest

Request message for UpdateWorkstationCluster.

Protobuf type google.cloud.workstations.v1beta.UpdateWorkstationClusterRequest

UpdateWorkstationClusterRequest.Builder

Request message for UpdateWorkstationCluster.

Protobuf type google.cloud.workstations.v1beta.UpdateWorkstationClusterRequest

UpdateWorkstationConfigRequest

Request message for UpdateWorkstationConfig.

Protobuf type google.cloud.workstations.v1beta.UpdateWorkstationConfigRequest

UpdateWorkstationConfigRequest.Builder

Request message for UpdateWorkstationConfig.

Protobuf type google.cloud.workstations.v1beta.UpdateWorkstationConfigRequest

UpdateWorkstationRequest

Request message for UpdateWorkstation.

Protobuf type google.cloud.workstations.v1beta.UpdateWorkstationRequest

UpdateWorkstationRequest.Builder

Request message for UpdateWorkstation.

Protobuf type google.cloud.workstations.v1beta.UpdateWorkstationRequest

Workstation

A single instance of a developer workstation with its own persistent storage.

Protobuf type google.cloud.workstations.v1beta.Workstation

Workstation.Builder

A single instance of a developer workstation with its own persistent storage.

Protobuf type google.cloud.workstations.v1beta.Workstation

WorkstationCluster

A grouping of workstation configurations and the associated workstations in that region.

Protobuf type google.cloud.workstations.v1beta.WorkstationCluster

WorkstationCluster.Builder

A grouping of workstation configurations and the associated workstations in that region.

Protobuf type google.cloud.workstations.v1beta.WorkstationCluster

WorkstationCluster.PrivateClusterConfig

Configuration options for private clusters.

Protobuf type google.cloud.workstations.v1beta.WorkstationCluster.PrivateClusterConfig

WorkstationCluster.PrivateClusterConfig.Builder

Configuration options for private clusters.

Protobuf type google.cloud.workstations.v1beta.WorkstationCluster.PrivateClusterConfig

WorkstationClusterName

WorkstationClusterName.Builder

Builder for projects/{project}/locations/{location}/workstationClusters/{workstation_cluster}.

WorkstationConfig

A set of configuration options describing how a workstation will be run. Workstation configurations are intended to be shared across multiple workstations.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig

WorkstationConfig.Builder

A set of configuration options describing how a workstation will be run. Workstation configurations are intended to be shared across multiple workstations.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig

WorkstationConfig.Container

A Docker container.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Container

WorkstationConfig.Container.Builder

A Docker container.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Container

WorkstationConfig.CustomerEncryptionKey

A customer-managed encryption key for the Compute Engine resources of this workstation configuration.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.CustomerEncryptionKey

WorkstationConfig.CustomerEncryptionKey.Builder

A customer-managed encryption key for the Compute Engine resources of this workstation configuration.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.CustomerEncryptionKey

WorkstationConfig.Host

Runtime host for a workstation.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Host

WorkstationConfig.Host.Builder

Runtime host for a workstation.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Host

WorkstationConfig.Host.GceInstance

A runtime using a Compute Engine instance.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Host.GceInstance

WorkstationConfig.Host.GceInstance.Builder

A runtime using a Compute Engine instance.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Host.GceInstance

WorkstationConfig.Host.GceInstance.GceConfidentialInstanceConfig

A set of Compute Engine Confidential VM instance options.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Host.GceInstance.GceConfidentialInstanceConfig

WorkstationConfig.Host.GceInstance.GceConfidentialInstanceConfig.Builder

A set of Compute Engine Confidential VM instance options.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Host.GceInstance.GceConfidentialInstanceConfig

WorkstationConfig.Host.GceInstance.GceShieldedInstanceConfig

A set of Compute Engine Shielded instance options.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Host.GceInstance.GceShieldedInstanceConfig

WorkstationConfig.Host.GceInstance.GceShieldedInstanceConfig.Builder

A set of Compute Engine Shielded instance options.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.Host.GceInstance.GceShieldedInstanceConfig

WorkstationConfig.PersistentDirectory

A directory to persist across workstation sessions.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory

WorkstationConfig.PersistentDirectory.Builder

A directory to persist across workstation sessions.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory

WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk

A PersistentDirectory backed by a Compute Engine regional persistent disk.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk

WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.Builder

A PersistentDirectory backed by a Compute Engine regional persistent disk.

Protobuf type google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk

WorkstationConfigName

WorkstationConfigName.Builder

Builder for projects/{project}/locations/{location}/workstationClusters/{workstation_cluster}/workstationConfigs/{workstation_config}.

WorkstationName

WorkstationName.Builder

Builder for projects/{project}/locations/{location}/workstationClusters/{workstation_cluster}/workstationConfigs/{workstation_config}/workstations/{workstation}.

WorkstationsClient

Service Description: Service for interacting with Cloud Workstations.

This class provides the ability to make remote calls to the backing service through method calls that map to API methods. Sample code to get started:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 try (WorkstationsClient workstationsClient = WorkstationsClient.create()) {
   WorkstationClusterName name =
       WorkstationClusterName.of("[PROJECT]", "[LOCATION]", "[WORKSTATION_CLUSTER]");
   WorkstationCluster response = workstationsClient.getWorkstationCluster(name);
 }
 

Note: close() needs to be called on the WorkstationsClient object to clean up resources such as threads. In the example above, try-with-resources is used, which automatically calls close().

The surface of this class includes several types of Java methods for each of the API's methods:

  1. A "flattened" method. With this type of method, the fields of the request type have been converted into function parameters. It may be the case that not all fields are available as parameters, and not every API method will have a flattened method entry point.
  2. A "request object" method. This type of method only takes one parameter, a request object, which must be constructed before the call. Not every API method will have a request object method.
  3. A "callable" method. This type of method takes no parameters and returns an immutable API callable object, which can be used to initiate calls to the service.

See the individual methods for example code.

Many parameters require resource names to be formatted in a particular way. To assist with these names, this class includes a format method for each type of name, and additionally a parse method to extract the individual identifiers contained within names that are returned.

This class can be customized by passing in a custom instance of WorkstationsSettings to create(). For example:

To customize credentials:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 WorkstationsSettings workstationsSettings =
     WorkstationsSettings.newBuilder()
         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
         .build();
 WorkstationsClient workstationsClient = WorkstationsClient.create(workstationsSettings);
 

To customize the endpoint:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 WorkstationsSettings workstationsSettings =
     WorkstationsSettings.newBuilder().setEndpoint(myEndpoint).build();
 WorkstationsClient workstationsClient = WorkstationsClient.create(workstationsSettings);
 

To use REST (HTTP1.1/JSON) transport (instead of gRPC) for sending and receiving requests over the wire:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 WorkstationsSettings workstationsSettings = WorkstationsSettings.newHttpJsonBuilder().build();
 WorkstationsClient workstationsClient = WorkstationsClient.create(workstationsSettings);
 

Please refer to the GitHub repository's samples for more quickstart code snippets.

WorkstationsClient.ListUsableWorkstationConfigsFixedSizeCollection

WorkstationsClient.ListUsableWorkstationConfigsPage

WorkstationsClient.ListUsableWorkstationConfigsPagedResponse

WorkstationsClient.ListUsableWorkstationsFixedSizeCollection

WorkstationsClient.ListUsableWorkstationsPage

WorkstationsClient.ListUsableWorkstationsPagedResponse

WorkstationsClient.ListWorkstationClustersFixedSizeCollection

WorkstationsClient.ListWorkstationClustersPage

WorkstationsClient.ListWorkstationClustersPagedResponse

WorkstationsClient.ListWorkstationConfigsFixedSizeCollection

WorkstationsClient.ListWorkstationConfigsPage

WorkstationsClient.ListWorkstationConfigsPagedResponse

WorkstationsClient.ListWorkstationsFixedSizeCollection

WorkstationsClient.ListWorkstationsPage

WorkstationsClient.ListWorkstationsPagedResponse

WorkstationsGrpc

Service for interacting with Cloud Workstations.

WorkstationsGrpc.WorkstationsBlockingStub

A stub to allow clients to do synchronous rpc calls to service Workstations.

Service for interacting with Cloud Workstations.

WorkstationsGrpc.WorkstationsFutureStub

A stub to allow clients to do ListenableFuture-style rpc calls to service Workstations.

Service for interacting with Cloud Workstations.

WorkstationsGrpc.WorkstationsImplBase

Base class for the server implementation of the service Workstations.

Service for interacting with Cloud Workstations.

WorkstationsGrpc.WorkstationsStub

A stub to allow clients to do asynchronous rpc calls to service Workstations.

Service for interacting with Cloud Workstations.

WorkstationsProto

WorkstationsSettings

Settings class to configure an instance of WorkstationsClient.

The default instance has everything set to sensible defaults:

  • The default service address (workstations.googleapis.com) and default port (443) are used.
  • Credentials are acquired automatically through Application Default Credentials.
  • Retries are configured for idempotent methods but not for non-idempotent methods.

The builder of this class is recursive, so contained classes are themselves builders. When build() is called, the tree of builders is called to create the complete settings object.

For example, to set the total timeout of getWorkstationCluster to 30 seconds:


 // This snippet has been automatically generated and should be regarded as a code template only.
 // It will require modifications to work:
 // - It may require correct/in-range values for request initialization.
 // - It may require specifying regional endpoints when creating the service client as shown in
 // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
 WorkstationsSettings.Builder workstationsSettingsBuilder = WorkstationsSettings.newBuilder();
 workstationsSettingsBuilder
     .getWorkstationClusterSettings()
     .setRetrySettings(
         workstationsSettingsBuilder
             .getWorkstationClusterSettings()
             .getRetrySettings()
             .toBuilder()
             .setTotalTimeout(Duration.ofSeconds(30))
             .build());
 WorkstationsSettings workstationsSettings = workstationsSettingsBuilder.build();
 

WorkstationsSettings.Builder

Builder for WorkstationsSettings.

Interfaces

CreateWorkstationClusterRequestOrBuilder

CreateWorkstationConfigRequestOrBuilder

CreateWorkstationRequestOrBuilder

DeleteWorkstationClusterRequestOrBuilder

DeleteWorkstationConfigRequestOrBuilder

DeleteWorkstationRequestOrBuilder

GenerateAccessTokenRequestOrBuilder

GenerateAccessTokenResponseOrBuilder

GetWorkstationClusterRequestOrBuilder

GetWorkstationConfigRequestOrBuilder

GetWorkstationRequestOrBuilder

ListUsableWorkstationConfigsRequestOrBuilder

ListUsableWorkstationConfigsResponseOrBuilder

ListUsableWorkstationsRequestOrBuilder

ListUsableWorkstationsResponseOrBuilder

ListWorkstationClustersRequestOrBuilder

ListWorkstationClustersResponseOrBuilder

ListWorkstationConfigsRequestOrBuilder

ListWorkstationConfigsResponseOrBuilder

ListWorkstationsRequestOrBuilder

ListWorkstationsResponseOrBuilder

OperationMetadataOrBuilder

StartWorkstationRequestOrBuilder

StopWorkstationRequestOrBuilder

UpdateWorkstationClusterRequestOrBuilder

UpdateWorkstationConfigRequestOrBuilder

UpdateWorkstationRequestOrBuilder

WorkstationCluster.PrivateClusterConfigOrBuilder

WorkstationClusterOrBuilder

WorkstationConfig.ContainerOrBuilder

WorkstationConfig.CustomerEncryptionKeyOrBuilder

WorkstationConfig.Host.GceInstance.GceConfidentialInstanceConfigOrBuilder

WorkstationConfig.Host.GceInstance.GceShieldedInstanceConfigOrBuilder

WorkstationConfig.Host.GceInstanceOrBuilder

WorkstationConfig.HostOrBuilder

WorkstationConfig.PersistentDirectory.GceRegionalPersistentDiskOrBuilder

WorkstationConfig.PersistentDirectoryOrBuilder

WorkstationConfigOrBuilder

WorkstationOrBuilder

WorkstationsGrpc.AsyncService

Service for interacting with Cloud Workstations.

Enums

GenerateAccessTokenRequest.ExpirationCase

Workstation.State

Whether a workstation is running and ready to receive user requests.

Protobuf enum google.cloud.workstations.v1beta.Workstation.State

WorkstationConfig.Host.ConfigCase

WorkstationConfig.PersistentDirectory.DirectoryTypeCase

WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy

Value representing what should happen to the disk after the workstation is deleted.

Protobuf enum google.cloud.workstations.v1beta.WorkstationConfig.PersistentDirectory.GceRegionalPersistentDisk.ReclaimPolicy