- 4.52.0 (latest)
- 4.51.0
- 4.50.0
- 4.49.0
- 4.48.0
- 4.46.0
- 4.45.0
- 4.44.0
- 4.43.0
- 4.42.0
- 4.41.0
- 4.40.0
- 4.39.0
- 4.38.0
- 4.37.0
- 4.36.0
- 4.34.0
- 4.33.0
- 4.32.0
- 4.31.0
- 4.30.0
- 4.29.0
- 4.28.0
- 4.27.0
- 4.26.0
- 4.25.0
- 4.24.0
- 4.21.0
- 4.20.0
- 4.19.0
- 4.18.0
- 4.17.0
- 4.16.0
- 4.15.0
- 4.14.0
- 4.13.0
- 4.12.0
- 4.11.0
- 4.10.0
- 4.9.0
- 4.8.0
- 4.6.0
- 4.5.0
- 4.4.0
- 4.3.0
- 4.2.0
- 4.1.0
- 4.0.8
- 3.1.2
- 3.0.3
- 2.3.1
com.google.cloud.dataproc.v1
A client to Cloud Dataproc API
The interfaces provided are listed below, along with usage samples.
AutoscalingPolicyServiceClient
Service Description: The API interface for managing autoscaling policies in the Dataproc API.
Sample for AutoscalingPolicyServiceClient:
// 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 (AutoscalingPolicyServiceClient autoscalingPolicyServiceClient =
AutoscalingPolicyServiceClient.create()) {
LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
AutoscalingPolicy policy = AutoscalingPolicy.newBuilder().build();
AutoscalingPolicy response =
autoscalingPolicyServiceClient.createAutoscalingPolicy(parent, policy);
}
BatchControllerClient
Service Description: The BatchController provides methods to manage batch workloads.
Sample for BatchControllerClient:
// 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 (BatchControllerClient batchControllerClient = BatchControllerClient.create()) {
BatchName name = BatchName.of("[PROJECT]", "[LOCATION]", "[BATCH]");
Batch response = batchControllerClient.getBatch(name);
}
ClusterControllerClient
Service Description: The ClusterControllerService provides methods to manage clusters of Compute Engine instances.
Sample for ClusterControllerClient:
// 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 (ClusterControllerClient clusterControllerClient = ClusterControllerClient.create()) {
String projectId = "projectId-894832108";
String region = "region-934795532";
String clusterName = "clusterName-1141738587";
Cluster response = clusterControllerClient.getCluster(projectId, region, clusterName);
}
JobControllerClient
Service Description: The JobController provides methods to manage jobs.
Sample for JobControllerClient:
// 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 (JobControllerClient jobControllerClient = JobControllerClient.create()) {
String projectId = "projectId-894832108";
String region = "region-934795532";
Job job = Job.newBuilder().build();
Job response = jobControllerClient.submitJob(projectId, region, job);
}
NodeGroupControllerClient
Service Description: The NodeGroupControllerService
provides methods to manage node groups
of Compute Engine managed instances.
Sample for NodeGroupControllerClient:
// 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 (NodeGroupControllerClient nodeGroupControllerClient = NodeGroupControllerClient.create()) {
NodeGroupName name = NodeGroupName.of("[PROJECT]", "[REGION]", "[CLUSTER]", "[NODE_GROUP]");
NodeGroup response = nodeGroupControllerClient.getNodeGroup(name);
}
WorkflowTemplateServiceClient
Service Description: The API interface for managing Workflow Templates in the Dataproc API.
Sample for WorkflowTemplateServiceClient:
// 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 (WorkflowTemplateServiceClient workflowTemplateServiceClient =
WorkflowTemplateServiceClient.create()) {
LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
WorkflowTemplate template = WorkflowTemplate.newBuilder().build();
WorkflowTemplate response =
workflowTemplateServiceClient.createWorkflowTemplate(parent, template);
}