Package google.cloud.dataproc.v1

Index

AutoscalingPolicyService

The API interface for managing autoscaling policies in the Dataproc API.

CreateAutoscalingPolicy

rpc CreateAutoscalingPolicy(CreateAutoscalingPolicyRequest) returns (AutoscalingPolicy)

Creates new autoscaling policy.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

DeleteAutoscalingPolicy

rpc DeleteAutoscalingPolicy(DeleteAutoscalingPolicyRequest) returns (Empty)

Deletes an autoscaling policy. It is an error to delete an autoscaling policy that is in use by one or more clusters.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

GetAutoscalingPolicy

rpc GetAutoscalingPolicy(GetAutoscalingPolicyRequest) returns (AutoscalingPolicy)

Retrieves autoscaling policy.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ListAutoscalingPolicies

rpc ListAutoscalingPolicies(ListAutoscalingPoliciesRequest) returns (ListAutoscalingPoliciesResponse)

Lists autoscaling policies in the project.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

UpdateAutoscalingPolicy

rpc UpdateAutoscalingPolicy(UpdateAutoscalingPolicyRequest) returns (AutoscalingPolicy)

Updates (replaces) autoscaling policy.

Disabled check for update_mask, because all updates will be full replacements.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ClusterController

The ClusterControllerService provides methods to manage clusters of Compute Engine instances.

CreateCluster

rpc CreateCluster(CreateClusterRequest) returns (Operation)

Creates a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

DeleteCluster

rpc DeleteCluster(DeleteClusterRequest) returns (Operation)

Deletes a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

DiagnoseCluster

rpc DiagnoseCluster(DiagnoseClusterRequest) returns (Operation)

Gets cluster diagnostic information. The returned Operation.metadata will be ClusterOperationMetadata. After the operation completes, Operation.response contains DiagnoseClusterResults.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

GetCluster

rpc GetCluster(GetClusterRequest) returns (Cluster)

Gets the resource representation for a cluster in a project.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ListClusters

rpc ListClusters(ListClustersRequest) returns (ListClustersResponse)

Lists all regions/{region}/clusters in a project alphabetically.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

StartCluster

rpc StartCluster(StartClusterRequest) returns (Operation)

Starts a cluster in a project.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

StopCluster

rpc StopCluster(StopClusterRequest) returns (Operation)

Stops a cluster in a project.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

UpdateCluster

rpc UpdateCluster(UpdateClusterRequest) returns (Operation)

Updates a cluster in a project. The returned Operation.metadata will be ClusterOperationMetadata. The cluster must be in a RUNNING state or an error is returned.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

JobController

The JobController provides methods to manage jobs.

CancelJob

rpc CancelJob(CancelJobRequest) returns (Job)

Starts a job cancellation request. To access the job resource after cancellation, call regions/{region}/jobs.list or regions/{region}/jobs.get.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

DeleteJob

rpc DeleteJob(DeleteJobRequest) returns (Empty)

Deletes the job from the project. If the job is active, the delete fails, and the response returns FAILED_PRECONDITION.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

GetJob

rpc GetJob(GetJobRequest) returns (Job)

Gets the resource representation for a job in a project.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ListJobs

rpc ListJobs(ListJobsRequest) returns (ListJobsResponse)

Lists regions/{region}/jobs in a project.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

SubmitJob

rpc SubmitJob(SubmitJobRequest) returns (Job)

Submits a job to a cluster.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

SubmitJobAsOperation

rpc SubmitJobAsOperation(SubmitJobRequest) returns (Operation)

Submits job to a cluster.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

UpdateJob

rpc UpdateJob(UpdateJobRequest) returns (Job)

Updates a job in a project.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

NodeGroupController

The NodeGroupControllerService provides methods to manage node groups of Compute Engine managed instances.

GetNodeGroup

rpc GetNodeGroup(GetNodeGroupRequest) returns (NodeGroup)

Gets the resource representation for a node group in a cluster.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ResizeNodeGroup

rpc ResizeNodeGroup(ResizeNodeGroupRequest) returns (Operation)

Resizes a node group in a cluster. The returned Operation.metadata is NodeGroupOperationMetadata.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

WorkflowTemplateService

The API interface for managing Workflow Templates in the Dataproc API.

CreateWorkflowTemplate

rpc CreateWorkflowTemplate(CreateWorkflowTemplateRequest) returns (WorkflowTemplate)

Creates new workflow template.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

DeleteWorkflowTemplate

rpc DeleteWorkflowTemplate(DeleteWorkflowTemplateRequest) returns (Empty)

Deletes a workflow template. It does not cancel in-progress workflows.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

GetWorkflowTemplate

rpc GetWorkflowTemplate(GetWorkflowTemplateRequest) returns (WorkflowTemplate)

Retrieves the latest workflow template.

Can retrieve previously instantiated template by specifying optional version parameter.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

InstantiateInlineWorkflowTemplate

rpc InstantiateInlineWorkflowTemplate(InstantiateInlineWorkflowTemplateRequest) returns (Operation)

Instantiates a template and begins execution.

This method is equivalent to executing the sequence CreateWorkflowTemplate, InstantiateWorkflowTemplate, DeleteWorkflowTemplate.

The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.

The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.

The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.

On successful completion, Operation.response will be Empty.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

InstantiateWorkflowTemplate

rpc InstantiateWorkflowTemplate(InstantiateWorkflowTemplateRequest) returns (Operation)

Instantiates a template and begins execution.

The returned Operation can be used to track execution of workflow by polling operations.get. The Operation will complete when entire workflow is finished.

The running workflow can be aborted via operations.cancel. This will cause any inflight jobs to be cancelled and workflow-owned clusters to be deleted.

The Operation.metadata will be WorkflowMetadata. Also see Using WorkflowMetadata.

On successful completion, Operation.response will be Empty.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

ListWorkflowTemplates

rpc ListWorkflowTemplates(ListWorkflowTemplatesRequest) returns (ListWorkflowTemplatesResponse)

Lists workflows that match the specified filter in the request.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

UpdateWorkflowTemplate

rpc UpdateWorkflowTemplate(UpdateWorkflowTemplateRequest) returns (WorkflowTemplate)

Updates (replaces) workflow template. The updated template must contain version that matches the current server version.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

For more information, see the Authentication Overview.

AcceleratorConfig

Specifies the type and number of accelerator cards attached to the instances of an instance. See GPUs on Compute Engine.

Fields
accelerator_type_uri

string

Full URL, partial URI, or short name of the accelerator type resource to expose to this instance. See Compute Engine AcceleratorTypes.

Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/zones/[zone]/acceleratorTypes/nvidia-tesla-k80
  • projects/[project_id]/zones/[zone]/acceleratorTypes/nvidia-tesla-k80
  • nvidia-tesla-k80

Auto Zone Exception: If you are using the Dataproc Auto Zone Placement feature, you must use the short name of the accelerator type resource, for example, nvidia-tesla-k80.

accelerator_count

int32

The number of the accelerator cards of this type exposed to this instance.

AutoscalingConfig

Autoscaling Policy config associated with the cluster.

Fields
policy_uri

string

Optional. The autoscaling policy used by the cluster.

Only resource names including projectid and location (region) are valid. Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/locations/[dataproc_region]/autoscalingPolicies/[policy_id]
  • projects/[project_id]/locations/[dataproc_region]/autoscalingPolicies/[policy_id]

Note that the policy must be in the same project and Dataproc region.

AutoscalingPolicy

Describes an autoscaling policy for Dataproc cluster autoscaler.

Fields
id

string

Required. The policy id.

The id must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). Cannot begin or end with underscore or hyphen. Must consist of between 3 and 50 characters.

name

string

Output only. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}

  • For projects.locations.autoscalingPolicies, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id}

worker_config

InstanceGroupAutoscalingPolicyConfig

Required. Describes how the autoscaler will operate for primary workers.

secondary_worker_config

InstanceGroupAutoscalingPolicyConfig

Optional. Describes how the autoscaler will operate for secondary workers.

Union field algorithm. Autoscaling algorithm for policy. algorithm can be only one of the following:
basic_algorithm

BasicAutoscalingAlgorithm

AuxiliaryNodeGroup

Node group identification and configuration information.

Fields
node_group

NodeGroup

Required. Node group configuration.

node_group_id

string

Optional. A node group ID. Generated if not specified.

The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). Cannot begin or end with underscore or hyphen. Must consist of from 3 to 33 characters.

AuxiliaryServicesConfig

Auxiliary services configuration for a Cluster.

Fields
metastore_config

MetastoreConfig

Optional. The Hive Metastore configuration for this workload.

spark_history_server_config

SparkHistoryServerConfig

Optional. The Spark History Server configuration for the workload.

BasicAutoscalingAlgorithm

Basic algorithm for autoscaling.

Fields
cooldown_period

Duration

Optional. Duration between scaling events. A scaling period starts after the update operation from the previous event has completed.

Bounds: [2m, 1d]. Default: 2m.

Union field config.

config can be only one of the following:

yarn_config

BasicYarnAutoscalingConfig

Optional. YARN autoscaling configuration.

BasicYarnAutoscalingConfig

Basic autoscaling configurations for YARN.

Fields
graceful_decommission_timeout

Duration

Required. Timeout for YARN graceful decommissioning of Node Managers. Specifies the duration to wait for jobs to complete before forcefully removing workers (and potentially interrupting jobs). Only applicable to downscaling operations.

Bounds: [0s, 1d].

scale_up_factor

double

Required. Fraction of average YARN pending memory in the last cooldown period for which to add workers. A scale-up factor of 1.0 will result in scaling up so that there is no pending memory remaining after the update (more aggressive scaling). A scale-up factor closer to 0 will result in a smaller magnitude of scaling up (less aggressive scaling). See How autoscaling works for more information.

Bounds: [0.0, 1.0].

scale_down_factor

double

Required. Fraction of average YARN pending memory in the last cooldown period for which to remove workers. A scale-down factor of 1 will result in scaling down so that there is no available memory remaining after the update (more aggressive scaling). A scale-down factor of 0 disables removing workers, which can be beneficial for autoscaling a single job. See How autoscaling works for more information.

Bounds: [0.0, 1.0].

scale_up_min_worker_fraction

double

Optional. Minimum scale-up threshold as a fraction of total cluster size before scaling occurs. For example, in a 20-worker cluster, a threshold of 0.1 means the autoscaler must recommend at least a 2-worker scale-up for the cluster to scale. A threshold of 0 means the autoscaler will scale up on any recommended change.

Bounds: [0.0, 1.0]. Default: 0.0.

scale_down_min_worker_fraction

double

Optional. Minimum scale-down threshold as a fraction of total cluster size before scaling occurs. For example, in a 20-worker cluster, a threshold of 0.1 means the autoscaler must recommend at least a 2 worker scale-down for the cluster to scale. A threshold of 0 means the autoscaler will scale down on any recommended change.

Bounds: [0.0, 1.0]. Default: 0.0.

CancelJobRequest

A request to cancel a job.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the job belongs to.

region

string

Required. The Dataproc region in which to handle the request.

job_id

string

Required. The job ID.

Authorization requires the following IAM permission on the specified resource jobId:

  • dataproc.jobs.cancel

Cluster

Describes the identifying information, config, and status of a Dataproc cluster

Fields
project_id

string

Required. The Google Cloud Platform project ID that the cluster belongs to.

cluster_name

string

Required. The cluster name, which must be unique within a project. The name must start with a lowercase letter, and can contain up to 51 lowercase letters, numbers, and hyphens. It cannot end with a hyphen. The name of a deleted cluster can be reused.

config

ClusterConfig

Optional. The cluster config for a cluster of Compute Engine Instances. Note that Dataproc may set default values, and values may change when clusters are updated.

Exactly one of ClusterConfig or VirtualClusterConfig must be specified.

virtual_cluster_config

VirtualClusterConfig

Optional. The virtual cluster config is used when creating a Dataproc cluster that does not directly control the underlying compute resources, for example, when creating a Dataproc-on-GKE cluster. Dataproc may set default values, and values may change when clusters are updated. Exactly one of config or virtual_cluster_config must be specified.

labels

map<string, string>

Optional. The labels to associate with this cluster. Label keys must contain 1 to 63 characters, and must conform to RFC 1035. Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035. No more than 32 labels can be associated with a cluster.

status

ClusterStatus

Output only. Cluster status.

status_history[]

ClusterStatus

Output only. The previous cluster status.

cluster_uuid

string

Output only. A cluster UUID (Unique Universal Identifier). Dataproc generates this value when it creates the cluster.

metrics

ClusterMetrics

Output only. Contains cluster daemon metrics such as HDFS and YARN stats.

Beta Feature: This report is available for testing purposes only. It may be changed before final release.

ClusterConfig

The cluster config.

Fields
config_bucket

string

Optional. A Cloud Storage bucket used to stage job dependencies, config files, and job driver console output. If you do not specify a staging bucket, Cloud Dataproc will determine a Cloud Storage location (US, ASIA, or EU) for your cluster's staging bucket according to the Compute Engine zone where your cluster is deployed, and then create and manage this project-level, per-location bucket (see Dataproc staging and temp buckets). This field requires a Cloud Storage bucket name, not a gs://... URI to a Cloud Storage bucket.

temp_bucket

string

Optional. A Cloud Storage bucket used to store ephemeral cluster and jobs data, such as Spark and MapReduce history files. If you do not specify a temp bucket, Dataproc will determine a Cloud Storage location (US, ASIA, or EU) for your cluster's temp bucket according to the Compute Engine zone where your cluster is deployed, and then create and manage this project-level, per-location bucket. The default bucket has a TTL of 90 days, but you can use any TTL (or none) if you specify a bucket (see Dataproc staging and temp buckets). This field requires a Cloud Storage bucket name, not a gs://... URI to a Cloud Storage bucket.

gce_cluster_config

GceClusterConfig

Optional. The shared Compute Engine config settings for all instances in a cluster.

master_config

InstanceGroupConfig

Optional. The Compute Engine config settings for the cluster's master instance.

worker_config

InstanceGroupConfig

Optional. The Compute Engine config settings for the cluster's worker instances.

secondary_worker_config

InstanceGroupConfig

Optional. The Compute Engine config settings for a cluster's secondary worker instances

software_config

SoftwareConfig

Optional. The config settings for cluster software.

initialization_actions[]

NodeInitializationAction

Optional. Commands to execute on each node after config is completed. By default, executables are run on master and all worker nodes. You can test a node's role metadata to run an executable on a master or worker node, as shown below using curl (you can also use wget):

ROLE=$(curl -H Metadata-Flavor:Google
http://metadata/computeMetadata/v1/instance/attributes/dataproc-role)
if [[ "${ROLE}" == 'Master' ]]; then
  ... master specific actions ...
else
  ... worker specific actions ...
fi
encryption_config

EncryptionConfig

Optional. Encryption settings for the cluster.

autoscaling_config

AutoscalingConfig

Optional. Autoscaling config for the policy associated with the cluster. Cluster does not autoscale if this field is unset.

security_config

SecurityConfig

Optional. Security settings for the cluster.

lifecycle_config

LifecycleConfig

Optional. Lifecycle setting for the cluster.

endpoint_config

EndpointConfig

Optional. Port/endpoint configuration for this cluster

metastore_config

MetastoreConfig

Optional. Metastore configuration.

dataproc_metric_config

DataprocMetricConfig

Optional. The config for Dataproc metrics.

auxiliary_node_groups[]

AuxiliaryNodeGroup

Optional. The node group settings.

ClusterMetrics

Contains cluster daemon metrics, such as HDFS and YARN stats.

Beta Feature: This report is available for testing purposes only. It may be changed before final release.

Fields
hdfs_metrics

map<string, int64>

The HDFS metrics.

yarn_metrics

map<string, int64>

YARN metrics.

ClusterOperation

The cluster operation triggered by a workflow.

Fields
operation_id

string

Output only. The id of the cluster operation.

error

string

Output only. Error, if operation failed.

done

bool

Output only. Indicates the operation is done.

ClusterOperationMetadata

Metadata describing the operation.

Fields
cluster_name

string

Output only. Name of the cluster for the operation.

cluster_uuid

string

Output only. Cluster UUID for the operation.

status

ClusterOperationStatus

Output only. Current operation status.

status_history[]

ClusterOperationStatus

Output only. The previous operation status.

operation_type

string

Output only. The operation type.

description

string

Output only. Short description of operation.

labels

map<string, string>

Output only. Labels associated with the operation

warnings[]

string

Output only. Errors encountered during operation execution.

child_operation_ids[]

string

Output only. Child operation ids

ClusterOperationStatus

The status of the operation.

Fields
state

State

Output only. A message containing the operation state.

inner_state

string

Output only. A message containing the detailed operation state.

details

string

Output only. A message containing any operation metadata details.

state_start_time

Timestamp

Output only. The time this state was entered.

State

The operation state.

Enums
UNKNOWN Unused.
PENDING The operation has been created.
RUNNING The operation is running.
DONE The operation is done; either cancelled or completed.

ClusterSelector

A selector that chooses target cluster for jobs based on metadata.

Fields
zone

string

Optional. The zone where workflow process executes. This parameter does not affect the selection of the cluster.

If unspecified, the zone of the first cluster matching the selector is used.

cluster_labels

map<string, string>

Required. The cluster labels. Cluster must have all labels to match.

ClusterStatus

The status of a cluster and its instances.

Fields
state

State

Output only. The cluster's state.

detail

string

Optional. Output only. Details of cluster's state.

state_start_time

Timestamp

Output only. Time when this state was entered (see JSON representation of Timestamp).

substate

Substate

Output only. Additional state information that includes status reported by the agent.

State

The cluster state.

Enums
UNKNOWN The cluster state is unknown.
CREATING The cluster is being created and set up. It is not ready for use.
RUNNING

The cluster is currently running and healthy. It is ready for use.

Note: The cluster state changes from "creating" to "running" status after the master node(s), first two primary worker nodes (and the last primary worker node if primary workers > 2) are running.

ERROR The cluster encountered an error. It is not ready for use.
ERROR_DUE_TO_UPDATE The cluster has encountered an error while being updated. Jobs can be submitted to the cluster, but the cluster cannot be updated.
DELETING The cluster is being deleted. It cannot be used.
UPDATING The cluster is being updated. It continues to accept and process jobs.
STOPPING The cluster is being stopped. It cannot be used.
STOPPED The cluster is currently stopped. It is not ready for use.
STARTING The cluster is being started. It is not ready for use.

Substate

The cluster substate.

Enums
UNSPECIFIED The cluster substate is unknown.
UNHEALTHY

The cluster is known to be in an unhealthy state (for example, critical daemons are not running or HDFS capacity is exhausted).

Applies to RUNNING state.

STALE_STATUS

The agent-reported status is out of date (may occur if Dataproc loses communication with Agent).

Applies to RUNNING state.

Component

Cluster components that can be activated.

Enums
COMPONENT_UNSPECIFIED Unspecified component. Specifying this will cause Cluster creation to fail.
ANACONDA The Anaconda python distribution. The Anaconda component is not supported in the Dataproc 2.0 image. The 2.0 image is pre-installed with Miniconda.
DOCKER Docker
DRUID The Druid query engine. (alpha)
HBASE HBase. (beta)
HIVE_WEBHCAT The Hive Web HCatalog (the REST service for accessing HCatalog).
HUDI Hudi.
JUPYTER The Jupyter Notebook.
PRESTO The Presto query engine.
RANGER The Ranger service.
SOLR The Solr service.
ZEPPELIN The Zeppelin notebook.
ZOOKEEPER The Zookeeper service.

ConfidentialInstanceConfig

Confidential Instance Config for clusters using Confidential VMs

Fields
enable_confidential_compute

bool

Optional. Defines whether the instance should have confidential compute enabled.

CreateAutoscalingPolicyRequest

A request to create an autoscaling policy.

Fields
parent

string

Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.autoscalingPolicies.create, the resource name of the region has the following format: projects/{project_id}/regions/{region}

  • For projects.locations.autoscalingPolicies.create, the resource name of the location has the following format: projects/{project_id}/locations/{location}

Authorization requires the following IAM permission on the specified resource parent:

  • dataproc.autoscalingPolicies.create
policy

AutoscalingPolicy

Required. The autoscaling policy to create.

CreateClusterRequest

A request to create a cluster.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the cluster belongs to.

Authorization requires the following IAM permission on the specified resource projectId:

  • dataproc.clusters.create
region

string

Required. The Dataproc region in which to handle the request.

cluster

Cluster

Required. The cluster to create.

request_id

string

Optional. A unique ID used to identify the request. If the server receives two CreateClusterRequests with the same id, then the second request will be ignored and the first google.longrunning.Operation created and stored in the backend is returned.

It is recommended to always set this value to a UUID.

The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

action_on_failed_primary_workers

FailureAction

Optional. Failure action when primary worker creation fails.

CreateWorkflowTemplateRequest

A request to create a workflow template.

Fields
parent

string

Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.workflowTemplates.create, the resource name of the region has the following format: projects/{project_id}/regions/{region}

  • For projects.locations.workflowTemplates.create, the resource name of the location has the following format: projects/{project_id}/locations/{location}

Authorization requires the following IAM permission on the specified resource parent:

  • dataproc.workflowTemplates.create
template

WorkflowTemplate

Required. The Dataproc workflow template to create.

DataprocMetricConfig

Dataproc metric config.

Fields
metrics[]

Metric

Required. Metrics sources to enable.

Metric

A Dataproc custom metric.

Fields
metric_source

MetricSource

Required. A standard set of metrics is collected unless metricOverrides are specified for the metric source (see Custom metrics for more information).

metric_overrides[]

string

Optional. Specify one or more Custom metrics to collect for the metric course (for the SPARK metric source (any Spark metric can be specified).

Provide metrics in the following format:

METRIC_SOURCE:INSTANCE:GROUP:METRIC

Use camelcase as appropriate.

Examples:

yarn:ResourceManager:QueueMetrics:AppsCompleted
spark:driver:DAGScheduler:job.allJobs
sparkHistoryServer:JVM:Memory:NonHeapMemoryUsage.committed
hiveserver2:JVM:Memory:NonHeapMemoryUsage.used

Notes:

  • Only the specified overridden metrics are collected for the metric source. For example, if one or more spark:executive metrics are listed as metric overrides, other SPARK metrics are not collected. The collection of the metrics for other enabled custom metric sources is unaffected. For example, if both SPARK andd YARN metric sources are enabled, and overrides are provided for Spark metrics only, all YARN metrics are collected.

MetricSource

A source for the collection of Dataproc custom metrics (see Custom metrics).

Enums
METRIC_SOURCE_UNSPECIFIED Required unspecified metric source.
MONITORING_AGENT_DEFAULTS Monitoring agent metrics. If this source is enabled, Dataproc enables the monitoring agent in Compute Engine, and collects monitoring agent metrics, which are published with an agent.googleapis.com prefix.
HDFS HDFS metric source.
SPARK Spark metric source.
YARN YARN metric source.
SPARK_HISTORY_SERVER Spark History Server metric source.
HIVESERVER2 Hiveserver2 metric source.
HIVEMETASTORE hivemetastore metric source

DeleteAutoscalingPolicyRequest

A request to delete an autoscaling policy.

Autoscaling policies in use by one or more clusters will not be deleted.

Fields
name

string

Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}

  • For projects.locations.autoscalingPolicies.delete, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id}

Authorization requires the following IAM permission on the specified resource name:

  • dataproc.autoscalingPolicies.delete

DeleteClusterRequest

A request to delete a cluster.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the cluster belongs to.

region

string

Required. The Dataproc region in which to handle the request.

cluster_name

string

Required. The cluster name.

Authorization requires the following IAM permission on the specified resource clusterName:

  • dataproc.clusters.delete
cluster_uuid

string

Optional. Specifying the cluster_uuid means the RPC should fail (with error NOT_FOUND) if cluster with specified UUID does not exist.

request_id

string

Optional. A unique ID used to identify the request. If the server receives two DeleteClusterRequests with the same id, then the second request will be ignored and the first google.longrunning.Operation created and stored in the backend is returned.

It is recommended to always set this value to a UUID.

The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

graceful_termination_timeout

Duration

Optional. The graceful termination timeout for the deletion of the cluster. Indicate the time the request will wait to complete the running jobs on the cluster before its forceful deletion. Default value is 0 indicating that the user has not enabled the graceful termination. Value can be between 60 second and 6 Hours, in case the graceful termination is enabled. (There is no separate flag to check the enabling or disabling of graceful termination, it can be checked by the values in the field).

DeleteJobRequest

A request to delete a job.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the job belongs to.

region

string

Required. The Dataproc region in which to handle the request.

job_id

string

Required. The job ID.

Authorization requires the following IAM permission on the specified resource jobId:

  • dataproc.jobs.delete

DeleteWorkflowTemplateRequest

A request to delete a workflow template.

Currently started workflows will remain running.

Fields
name

string

Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.workflowTemplates.delete, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id}

  • For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

Authorization requires the following IAM permission on the specified resource name:

  • dataproc.workflowTemplates.delete
version

int32

Optional. The version of workflow template to delete. If specified, will only delete the template if the current server version matches specified version.

DiagnoseClusterRequest

A request to collect cluster diagnostic information.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the cluster belongs to.

region

string

Required. The Dataproc region in which to handle the request.

cluster_name

string

Required. The cluster name.

Authorization requires the following IAM permission on the specified resource clusterName:

  • dataproc.clusters.diagnose
tarball_gcs_dir

string

Optional. (Optional) The output Cloud Storage directory for the diagnostic tarball. If not specified, a task-specific directory in the cluster's staging bucket will be used.

Authorization requires the following IAM permission on the specified resource tarballGcsDir:

  • dataproc.clusters.diagnose
tarball_access

TarballAccess

Optional. (Optional) The access type to the diagnostic tarball. If not specified, falls back to default access of the bucket

Authorization requires the following IAM permission on the specified resource tarballAccess:

  • dataproc.clusters.diagnose
diagnosis_interval

Interval

Optional. Time interval in which diagnosis should be carried out on the cluster.

jobs[]

string

Optional. Specifies a list of jobs on which diagnosis is to be performed. Format: projects/{project}/regions/{region}/jobs/{job}

yarn_application_ids[]

string

Optional. Specifies a list of yarn applications on which diagnosis is to be performed.

TarballAccess

Defines who has access to the diagnostic tarball

Enums
TARBALL_ACCESS_UNSPECIFIED Tarball Access unspecified. Falls back to default access of the bucket
GOOGLE_CLOUD_SUPPORT Google Cloud Support group has read access to the diagnostic tarball
GOOGLE_DATAPROC_DIAGNOSE Google Cloud Dataproc Diagnose service account has read access to the diagnostic tarball

DiagnoseClusterResults

The location of diagnostic output.

Fields
output_uri

string

Output only. The Cloud Storage URI of the diagnostic output. The output report is a plain text file with a summary of collected diagnostics.

DiskConfig

Specifies the config of disk options for a group of VM instances.

Fields
boot_disk_type

string

Optional. Type of the boot disk (default is "pd-standard"). Valid values: "pd-balanced" (Persistent Disk Balanced Solid State Drive), "pd-ssd" (Persistent Disk Solid State Drive), or "pd-standard" (Persistent Disk Hard Disk Drive). See Disk types.

boot_disk_size_gb

int32

Optional. Size in GB of the boot disk (default is 500GB).

num_local_ssds

int32

Optional. Number of attached SSDs, from 0 to 8 (default is 0). If SSDs are not attached, the boot disk is used to store runtime logs and HDFS data. If one or more SSDs are attached, this runtime bulk data is spread across them, and the boot disk contains only basic config and installed binaries.

Note: Local SSD options may vary by machine type and number of vCPUs selected.

local_ssd_interface

string

Optional. Interface type of local SSDs (default is "scsi"). Valid values: "scsi" (Small Computer System Interface), "nvme" (Non-Volatile Memory Express). See local SSD performance.

DriverSchedulingConfig

Driver scheduling configuration.

Fields
memory_mb

int32

Required. The amount of memory in MB the driver is requesting.

vcores

int32

Required. The number of vCPUs the driver is requesting.

EncryptionConfig

Encryption settings for the cluster.

Fields
gce_pd_kms_key_name

string

Optional. The Cloud KMS key resource name to use for persistent disk encryption for all instances in the cluster. See Use CMEK with cluster data for more information.

kms_key

string

Optional. The Cloud KMS key resource name to use for cluster persistent disk and job argument encryption. See Use CMEK with cluster data for more information.

When this key resource name is provided, the following job arguments of the following job types submitted to the cluster are encrypted using CMEK:

EndpointConfig

Endpoint config for this cluster

Fields
http_ports

map<string, string>

Output only. The map of port descriptions to URLs. Will only be populated if enable_http_port_access is true.

enable_http_port_access

bool

Optional. If true, enable http access to specific ports on the cluster from external sources. Defaults to false.

FailureAction

Actions in response to failure of a resource associated with a cluster.

Enums
FAILURE_ACTION_UNSPECIFIED When FailureAction is unspecified, failure action defaults to NO_ACTION.
NO_ACTION Take no action on failure to create a cluster resource. NO_ACTION is the default.
DELETE Delete the failed cluster resource.

FlinkJob

A Dataproc job for running Apache Flink applications on YARN.

Fields
args[]

string

Optional. The arguments to pass to the driver. Do not include arguments, such as --conf, that can be set as job properties, since a collision might occur that causes an incorrect job submission.

jar_file_uris[]

string

Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Flink driver and tasks.

savepoint_uri

string

Optional. HCFS URI of the savepoint, which contains the last saved progress for starting the current job.

properties

map<string, string>

Optional. A mapping of property names to values, used to configure Flink. Properties that conflict with values set by the Dataproc API might be

logging_config

LoggingConfig

Optional. The runtime log config for job execution.

Union field driver. Required. The specification of the main method to call to drive the job. Specify either the jar file that contains the main class or the main class name. To pass both a main jar and a main class in the jar, add the jar to jarFileUris, and then specify the main class name in mainClass. driver can be only one of the following:
main_jar_file_uri

string

The HCFS URI of the jar file that contains the main class.

main_class

string

The name of the driver's main class. The jar file that contains the class must be in the default CLASSPATH or specified in jarFileUris.

GceClusterConfig

Common config settings for resources of Compute Engine cluster instances, applicable to all instances in the cluster.

Fields
zone_uri

string

Optional. The Compute Engine zone where the Dataproc cluster will be located. If omitted, the service will pick a zone in the cluster's Compute Engine region. On a get request, zone will always be present.

A full URL, partial URI, or short name are valid. Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/zones/[zone]
  • projects/[project_id]/zones/[zone]
  • [zone]
network_uri

string

Optional. The Compute Engine network to be used for machine communications. Cannot be specified with subnetwork_uri. If neither network_uri nor subnetwork_uri is specified, the "default" network of the project is used, if it exists. Cannot be a "Custom Subnet Network" (see Using Subnetworks for more information).

A full URL, partial URI, or short name are valid. Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/global/networks/default
  • projects/[project_id]/global/networks/default
  • default
subnetwork_uri

string

Optional. The Compute Engine subnetwork to be used for machine communications. Cannot be specified with network_uri.

A full URL, partial URI, or short name are valid. Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/regions/[region]/subnetworks/sub0
  • projects/[project_id]/regions/[region]/subnetworks/sub0
  • sub0
private_ipv6_google_access

PrivateIpv6GoogleAccess

Optional. The type of IPv6 access for a cluster.

service_account

string

Optional. The Dataproc service account (also see VM Data Plane identity) used by Dataproc cluster VM instances to access Google Cloud Platform services.

If not specified, the Compute Engine default service account is used.

service_account_scopes[]

string

Optional. The URIs of service account scopes to be included in Compute Engine instances. The following base set of scopes is always included:

If no scopes are specified, the following defaults are also provided:

tags[]

string

The Compute Engine tags to add to all instances (see Tagging instances).

metadata

map<string, string>

Optional. The Compute Engine metadata entries to add to all instances (see Project and instance metadata).

reservation_affinity

ReservationAffinity

Optional. Reservation Affinity for consuming Zonal reservation.

node_group_affinity

NodeGroupAffinity

Optional. Node Group Affinity for sole-tenant clusters.

shielded_instance_config

ShieldedInstanceConfig

Optional. Shielded Instance Config for clusters using Compute Engine Shielded VMs.

confidential_instance_config

ConfidentialInstanceConfig

Optional. Confidential Instance Config for clusters using Confidential VMs.

internal_ip_only

bool

Optional. This setting applies to subnetwork-enabled networks. It is set to true by default in clusters created with image versions 2.2.x.

When set to true:

  • All cluster VMs have internal IP addresses.
  • Google Private Access must be enabled to access Dataproc and other Google Cloud APIs.
  • Off-cluster dependencies must be configured to be accessible without external IP addresses.

When set to false:

  • Cluster VMs are not restricted to internal IP addresses.
  • Ephemeral external IP addresses are assigned to each cluster VM.

PrivateIpv6GoogleAccess

PrivateIpv6GoogleAccess controls whether and how Dataproc cluster nodes can communicate with Google Services through gRPC over IPv6. These values are directly mapped to corresponding values in the Compute Engine Instance fields.

Enums
PRIVATE_IPV6_GOOGLE_ACCESS_UNSPECIFIED If unspecified, Compute Engine default behavior will apply, which is the same as INHERIT_FROM_SUBNETWORK.
INHERIT_FROM_SUBNETWORK Private access to and from Google Services configuration inherited from the subnetwork configuration. This is the default Compute Engine behavior.
OUTBOUND Enables outbound private IPv6 access to Google Services from the Dataproc cluster.
BIDIRECTIONAL Enables bidirectional private IPv6 access between Google Services and the Dataproc cluster.

GetAutoscalingPolicyRequest

A request to fetch an autoscaling policy.

Fields
name

string

Required. The "resource name" of the autoscaling policy, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/regions/{region}/autoscalingPolicies/{policy_id}

  • For projects.locations.autoscalingPolicies.get, the resource name of the policy has the following format: projects/{project_id}/locations/{location}/autoscalingPolicies/{policy_id}

Authorization requires the following IAM permission on the specified resource name:

  • dataproc.autoscalingPolicies.get

GetClusterRequest

Request to get the resource representation for a cluster in a project.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the cluster belongs to.

region

string

Required. The Dataproc region in which to handle the request.

cluster_name

string

Required. The cluster name.

Authorization requires the following IAM permission on the specified resource clusterName:

  • dataproc.clusters.get

GetJobRequest

A request to get the resource representation for a job in a project.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the job belongs to.

region

string

Required. The Dataproc region in which to handle the request.

job_id

string

Required. The job ID.

Authorization requires the following IAM permission on the specified resource jobId:

  • dataproc.jobs.get

GetNodeGroupRequest

A request to get a node group .

Fields
name

string

Required. The name of the node group to retrieve. Format: projects/{project}/regions/{region}/clusters/{cluster}/nodeGroups/{nodeGroup}

GetWorkflowTemplateRequest

A request to fetch a workflow template.

Fields
name

string

Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id}

  • For projects.locations.workflowTemplates.get, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

Authorization requires the following IAM permission on the specified resource name:

  • dataproc.workflowTemplates.get
version

int32

Optional. The version of workflow template to retrieve. Only previously instantiated versions can be retrieved.

If unspecified, retrieves the current version.

GkeClusterConfig

The cluster's GKE config.

Fields
namespaced_gke_deployment_target
(deprecated)

NamespacedGkeDeploymentTarget

Optional. Deprecated. Use gkeClusterTarget. Used only for the deprecated beta. A target for the deployment.

gke_cluster_target

string

Optional. A target GKE cluster to deploy to. It must be in the same project and region as the Dataproc cluster (the GKE cluster can be zonal or regional). Format: 'projects/{project}/locations/{location}/clusters/{cluster_id}'

node_pool_target[]

GkeNodePoolTarget

Optional. GKE node pools where workloads will be scheduled. At least one node pool must be assigned the DEFAULT GkeNodePoolTarget.Role. If a GkeNodePoolTarget is not specified, Dataproc constructs a DEFAULT GkeNodePoolTarget. Each role can be given to only one GkeNodePoolTarget. All node pools must have the same location settings.

NamespacedGkeDeploymentTarget

Deprecated. Used only for the deprecated beta. A full, namespace-isolated deployment target for an existing GKE cluster.

Fields
target_gke_cluster

string

Optional. The target GKE cluster to deploy to. Format: 'projects/{project}/locations/{location}/clusters/{cluster_id}'

cluster_namespace

string

Optional. A namespace within the GKE cluster to deploy into.

GkeNodePoolConfig

The configuration of a GKE node pool used by a Dataproc-on-GKE cluster.

Fields
config

GkeNodeConfig

Optional. The node pool configuration.

locations[]

string

Optional. The list of Compute Engine zones where node pool nodes associated with a Dataproc on GKE virtual cluster will be located.

Note: All node pools associated with a virtual cluster must be located in the same region as the virtual cluster, and they must be located in the same zone within that region.

If a location is not specified during node pool creation, Dataproc on GKE will choose the zone.

autoscaling

GkeNodePoolAutoscalingConfig

Optional. The autoscaler configuration for this node pool. The autoscaler is enabled only when a valid configuration is present.

GkeNodeConfig

Parameters that describe cluster nodes.

Fields
machine_type

string

Optional. The name of a Compute Engine machine type.

local_ssd_count

int32

Optional. The number of local SSD disks to attach to the node, which is limited by the maximum number of disks allowable per zone (see Adding Local SSDs).

preemptible

bool

Optional. Whether the nodes are created as legacy preemptible VM instances. Also see Spot VMs, preemptible VM instances without a maximum lifetime. Legacy and Spot preemptible nodes cannot be used in a node pool with the CONTROLLER role or in the DEFAULT node pool if the CONTROLLER role is not assigned (the DEFAULT node pool will assume the CONTROLLER role).

accelerators[]

GkeNodePoolAcceleratorConfig

Optional. A list of hardware accelerators to attach to each node.

min_cpu_platform

string

Optional. Minimum CPU platform to be used by this instance. The instance may be scheduled on the specified or a newer CPU platform. Specify the friendly names of CPU platforms, such as "Intel Haswell"` or Intel Sandy Bridge".

spot

bool

Optional. Whether the nodes are created as Spot VM instances. Spot VMs are the latest update to legacy preemptible VMs. Spot VMs do not have a maximum lifetime. Legacy and Spot preemptible nodes cannot be used in a node pool with the CONTROLLER role or in the DEFAULT node pool if the CONTROLLER role is not assigned (the DEFAULT node pool will assume the CONTROLLER role).

GkeNodePoolAcceleratorConfig

A GkeNodeConfigAcceleratorConfig represents a Hardware Accelerator request for a node pool.

Fields
accelerator_count

int64

The number of accelerator cards exposed to an instance.

accelerator_type

string

The accelerator type resource namename (see GPUs on Compute Engine).

gpu_partition_size

string

Size of partitions to create on the GPU. Valid values are described in the NVIDIA mig user guide.

GkeNodePoolAutoscalingConfig

GkeNodePoolAutoscaling contains information the cluster autoscaler needs to adjust the size of the node pool to the current cluster usage.

Fields
min_node_count

int32

The minimum number of nodes in the node pool. Must be >= 0 and <= max_node_count.

max_node_count

int32

The maximum number of nodes in the node pool. Must be >= min_node_count, and must be > 0. Note: Quota must be sufficient to scale up the cluster.

GkeNodePoolTarget

GKE node pools that Dataproc workloads run on.

Fields
node_pool

string

Required. The target GKE node pool. Format: 'projects/{project}/locations/{location}/clusters/{cluster}/nodePools/{node_pool}'

roles[]

Role

Required. The roles associated with the GKE node pool.

node_pool_config

GkeNodePoolConfig

Input only. The configuration for the GKE node pool.

If specified, Dataproc attempts to create a node pool with the specified shape. If one with the same name already exists, it is verified against all specified fields. If a field differs, the virtual cluster creation will fail.

If omitted, any node pool with the specified name is used. If a node pool with the specified name does not exist, Dataproc create a node pool with default values.

This is an input only field. It will not be returned by the API.

Role

Role specifies the tasks that will run on the node pool. Roles can be specific to workloads. Exactly one GkeNodePoolTarget within the virtual cluster must have the DEFAULT role, which is used to run all workloads that are not associated with a node pool.

Enums
ROLE_UNSPECIFIED Role is unspecified.
DEFAULT At least one node pool must have the DEFAULT role. Work assigned to a role that is not associated with a node pool is assigned to the node pool with the DEFAULT role. For example, work assigned to the CONTROLLER role will be assigned to the node pool with the DEFAULT role if no node pool has the CONTROLLER role.
CONTROLLER Run work associated with the Dataproc control plane (for example, controllers and webhooks). Very low resource requirements.
SPARK_DRIVER Run work associated with a Spark driver of a job.
SPARK_EXECUTOR Run work associated with a Spark executor of a job.

HadoopJob

A Dataproc job for running Apache Hadoop MapReduce jobs on Apache Hadoop YARN.

Fields
args[]

string

Optional. The arguments to pass to the driver. Do not include arguments, such as -libjars or -Dfoo=bar, that can be set as job properties, since a collision might occur that causes an incorrect job submission.

jar_file_uris[]

string

Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.

file_uris[]

string

Optional. HCFS (Hadoop Compatible Filesystem) URIs of files to be copied to the working directory of Hadoop drivers and distributed tasks. Useful for naively parallel tasks.

archive_uris[]

string

Optional. HCFS URIs of archives to be extracted in the working directory of Hadoop drivers and tasks. Supported file types: .jar, .tar, .tar.gz, .tgz, or .zip.

properties

map<string, string>

Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API might be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.

logging_config

LoggingConfig

Optional. The runtime log config for job execution.

Union field driver. Required. Indicates the location of the driver's main class. Specify either the jar file that contains the main class or the main class name. To specify both, add the jar file to jar_file_uris, and then specify the main class name in this property. driver can be only one of the following:
main_jar_file_uri

string

The HCFS URI of the jar file containing the main class. Examples: 'gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar' 'hdfs:/tmp/test-samples/custom-wordcount.jar' 'file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar'

main_class

string

The name of the driver's main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.

HiveJob

A Dataproc job for running Apache Hive queries on YARN.

Fields
continue_on_failure

bool

Optional. Whether to continue executing queries if a query fails. The default value is false. Setting to true can be useful when executing independent parallel queries.

script_variables

map<string, string>

Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name="value";).

properties

map<string, string>

Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API might be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.

jar_file_uris[]

string

Optional. HCFS URIs of jar files to add to the CLASSPATH of the Hive server and Hadoop MapReduce (MR) tasks. Can contain Hive SerDes and UDFs.

Union field queries. Required. The sequence of Hive queries to execute, specified as either an HCFS file URI or a list of queries. queries can be only one of the following:
query_file_uri

string

The HCFS URI of the script that contains Hive queries.

query_list

QueryList

A list of queries.

IdentityConfig

Identity related configuration, including service account based secure multi-tenancy user mappings.

Fields
user_service_account_mapping

map<string, string>

Required. Map of user to service account.

InstanceFlexibilityPolicy

Instance flexibility Policy allowing a mixture of VM shapes and provisioning models.

Fields
instance_selection_list[]

InstanceSelection

Optional. List of instance selection options that the group will use when creating new VMs.

instance_selection_results[]

InstanceSelectionResult

Output only. A list of instance selection results in the group.

InstanceSelection

Defines machines types and a rank to which the machines types belong.

Fields
machine_types[]

string

Optional. Full machine-type names, e.g. "n1-standard-16".

rank

int32

Optional. Preference of this instance selection. Lower number means higher preference. Dataproc will first try to create a VM based on the machine-type with priority rank and fallback to next rank based on availability. Machine types and instance selections with the same priority have the same preference.

InstanceSelectionResult

Defines a mapping from machine types to the number of VMs that are created with each machine type.

Fields
machine_type

string

Output only. Full machine-type names, e.g. "n1-standard-16".

vm_count

int32

Output only. Number of VM provisioned with the machine_type.

InstanceGroupAutoscalingPolicyConfig

Configuration for the size bounds of an instance group, including its proportional size to other groups.

Fields
min_instances

int32

Optional. Minimum number of instances for this group.

Primary workers - Bounds: [2, max_instances]. Default: 2. Secondary workers - Bounds: [0, max_instances]. Default: 0.

max_instances

int32

Required. Maximum number of instances for this group. Required for primary workers. Note that by default, clusters will not use secondary workers. Required for secondary workers if the minimum secondary instances is set.

Primary workers - Bounds: [min_instances, ). Secondary workers - Bounds: [min_instances, ). Default: 0.

weight

int32

Optional. Weight for the instance group, which is used to determine the fraction of total workers in the cluster from this instance group. For example, if primary workers have weight 2, and secondary workers have weight 1, the cluster will have approximately 2 primary workers for each secondary worker.

The cluster may not reach the specified balance if constrained by min/max bounds or other autoscaling settings. For example, if max_instances for secondary workers is 0, then only primary workers will be added. The cluster can also be out of balance when created.

If weight is not set on any instance group, the cluster will default to equal weight for all groups: the cluster will attempt to maintain an equal number of workers in each group within the configured size bounds for each group. If weight is set for one group only, the cluster will default to zero weight on the unset group. For example if weight is set only on primary workers, the cluster will use primary workers only and no secondary workers.

InstanceGroupConfig

The config settings for Compute Engine resources in an instance group, such as a master or worker group.

Fields
num_instances

int32

Optional. The number of VM instances in the instance group. For HA cluster master_config groups, must be set to 3. For standard cluster master_config groups, must be set to 1.

instance_names[]

string

Output only. The list of instance names. Dataproc derives the names from cluster_name, num_instances, and the instance group.

image_uri

string

Optional. The Compute Engine image resource used for cluster instances.

The URI can represent an image or image family.

Image examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/global/images/[image-id]
  • projects/[project_id]/global/images/[image-id]
  • image-id

Image family examples. Dataproc will use the most recent image from the family:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/global/images/family/[custom-image-family-name]
  • projects/[project_id]/global/images/family/[custom-image-family-name]

If the URI is unspecified, it will be inferred from SoftwareConfig.image_version or the system default.

machine_type_uri

string

Optional. The Compute Engine machine type used for cluster instances.

A full URL, partial URI, or short name are valid. Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/zones/[zone]/machineTypes/n1-standard-2
  • projects/[project_id]/zones/[zone]/machineTypes/n1-standard-2
  • n1-standard-2

Auto Zone Exception: If you are using the Dataproc Auto Zone Placement feature, you must use the short name of the machine type resource, for example, n1-standard-2.

disk_config

DiskConfig

Optional. Disk option config settings.

is_preemptible

bool

Output only. Specifies that this instance group contains preemptible instances.

preemptibility

Preemptibility

Optional. Specifies the preemptibility of the instance group.

The default value for master and worker groups is NON_PREEMPTIBLE. This default cannot be changed.

The default value for secondary instances is PREEMPTIBLE.

managed_group_config

ManagedGroupConfig

Output only. The config for Compute Engine Instance Group Manager that manages this group. This is only used for preemptible instance groups.

accelerators[]

AcceleratorConfig

Optional. The Compute Engine accelerator configuration for these instances.

min_cpu_platform

string

Optional. Specifies the minimum cpu platform for the Instance Group. See Dataproc -> Minimum CPU Platform.

min_num_instances

int32

Optional. The minimum number of primary worker instances to create. If min_num_instances is set, cluster creation will succeed if the number of primary workers created is at least equal to the min_num_instances number.

Example: Cluster creation request with num_instances = 5 and min_num_instances = 3:

  • If 4 VMs are created and 1 instance fails, the failed VM is deleted. The cluster is resized to 4 instances and placed in a RUNNING state.
  • If 2 instances are created and 3 instances fail, the cluster in placed in an ERROR state. The failed VMs are not deleted.
instance_flexibility_policy

InstanceFlexibilityPolicy

Optional. Instance flexibility Policy allowing a mixture of VM shapes and provisioning models.

startup_config

StartupConfig

Optional. Configuration to handle the startup of instances during cluster create and update process.

Preemptibility

Controls the use of preemptible instances within the group.

Enums
PREEMPTIBILITY_UNSPECIFIED Preemptibility is unspecified, the system will choose the appropriate setting for each instance group.
NON_PREEMPTIBLE

Instances are non-preemptible.

This option is allowed for all instance groups and is the only valid value for Master and Worker instance groups.

PREEMPTIBLE

Instances are preemptible.

This option is allowed only for secondary worker groups.

SPOT

Instances are Spot VMs.

This option is allowed only for secondary worker groups. Spot VMs are the latest version of preemptible VMs, and provide additional features.

InstantiateInlineWorkflowTemplateRequest

A request to instantiate an inline workflow template.

Fields
parent

string

Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.workflowTemplates,instantiateinline, the resource name of the region has the following format: projects/{project_id}/regions/{region}

  • For projects.locations.workflowTemplates.instantiateinline, the resource name of the location has the following format: projects/{project_id}/locations/{location}

Authorization requires the following IAM permission on the specified resource parent:

  • dataproc.workflowTemplates.instantiateInline
template

WorkflowTemplate

Required. The workflow template to instantiate.

request_id

string

Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.

It is recommended to always set this value to a UUID.

The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

InstantiateWorkflowTemplateRequest

A request to instantiate a workflow template.

Fields
name

string

Required. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id}

  • For projects.locations.workflowTemplates.instantiate, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

Authorization requires the following IAM permission on the specified resource name:

  • dataproc.workflowTemplates.instantiate
version

int32

Optional. The version of workflow template to instantiate. If specified, the workflow will be instantiated only if the current version of the workflow template has the supplied version.

This option cannot be used to instantiate a previous version of workflow template.

request_id

string

Optional. A tag that prevents multiple concurrent workflow instances with the same tag from running. This mitigates risk of concurrent instances started due to retries.

It is recommended to always set this value to a UUID.

The tag must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

parameters

map<string, string>

Optional. Map from parameter names to values that should be used for those parameters. Values may not exceed 1000 characters.

Job

A Dataproc job resource.

Fields
reference

JobReference

Optional. The fully qualified reference to the job, which can be used to obtain the equivalent REST path of the job resource. If this property is not specified when a job is created, the server generates a

job_id

.

placement

JobPlacement

Required. Job information, including how, when, and where to run the job.

status

JobStatus

Output only. The job status. Additional application-specific status information might be contained in the

type_job

and

yarn_applications

fields.

status_history[]

JobStatus

Output only. The previous job status.

yarn_applications[]

YarnApplication

Output only. The collection of YARN applications spun up by this job.

Beta Feature: This report is available for testing purposes only. It might be changed before final release.

driver_output_resource_uri

string

Output only. A URI pointing to the location of the stdout of the job's driver program.

driver_control_files_uri

string

Output only. If present, the location of miscellaneous control files which can be used as part of job setup and handling. If not present, control files might be placed in the same location as driver_output_uri.

labels

map<string, string>

Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035. Label values can be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035. No more than 32 labels can be associated with a job.

scheduling

JobScheduling

Optional. Job scheduling configuration.

job_uuid

string

Output only. A UUID that uniquely identifies a job within the project over time. This is in contrast to a user-settable reference.job_id that might be reused over time.

done

bool

Output only. Indicates whether the job is completed. If the value is false, the job is still in progress. If true, the job is completed, and status.state field will indicate if it was successful, failed, or cancelled.

driver_scheduling_config

DriverSchedulingConfig

Optional. Driver scheduling configuration.

Union field type_job. Required. The application/framework-specific portion of the job. type_job can be only one of the following:
hadoop_job

HadoopJob

Optional. Job is a Hadoop job.

spark_job

SparkJob

Optional. Job is a Spark job.

pyspark_job

PySparkJob

Optional. Job is a PySpark job.

hive_job

HiveJob

Optional. Job is a Hive job.

pig_job

PigJob

Optional. Job is a Pig job.

spark_r_job

SparkRJob

Optional. Job is a SparkR job.

spark_sql_job

SparkSqlJob

Optional. Job is a SparkSql job.

presto_job

PrestoJob

Optional. Job is a Presto job.

JobMetadata

Job Operation metadata.

Fields
job_id

string

Output only. The job id.

status

JobStatus

Output only. Most recent job status.

operation_type

string

Output only. Operation type.

start_time

Timestamp

Output only. Job submission time.

JobPlacement

Dataproc job config.

Fields
cluster_name

string

Required. The name of the cluster where the job will be submitted.

cluster_uuid

string

Output only. A cluster UUID generated by the Dataproc service when the job is submitted.

cluster_labels

map<string, string>

Optional. Cluster labels to identify a cluster where the job will be submitted.

JobReference

Encapsulates the full scoping used to reference a job.

Fields
project_id

string

Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.

job_id

string

Optional. The job ID, which must be unique within the project.

The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), or hyphens (-). The maximum length is 100 characters.

If not specified by the caller, the job ID will be provided by the server.

JobScheduling

Job scheduling options.

Fields
max_failures_per_hour

int32

Optional. Maximum number of times per hour a driver can be restarted as a result of driver exiting with non-zero code before job is reported failed.

A job might be reported as thrashing if the driver exits with a non-zero code four times within a 10-minute window.

Maximum value is 10.

Note: This restartable job option is not supported in Dataproc workflow templates.

max_failures_total

int32

Optional. Maximum total number of times a driver can be restarted as a result of the driver exiting with a non-zero code. After the maximum number is reached, the job will be reported as failed.

Maximum value is 240.

Note: Currently, this restartable job option is not supported in Dataproc workflow templates.

JobStatus

Dataproc job status.

Fields
state

State

Output only. A state message specifying the overall job state.

details

string

Optional. Output only. Job state details, such as an error description if the state is ERROR.

state_start_time

Timestamp

Output only. The time when this state was entered.

substate

Substate

Output only. Additional state information, which includes status reported by the agent.

State

The job state.

Enums
STATE_UNSPECIFIED The job state is unknown.
PENDING The job is pending; it has been submitted, but is not yet running.
SETUP_DONE Job has been received by the service and completed initial setup; it will soon be submitted to the cluster.
RUNNING The job is running on the cluster.
CANCEL_PENDING A CancelJob request has been received, but is pending.
CANCEL_STARTED Transient in-flight resources have been canceled, and the request to cancel the running job has been issued to the cluster.
CANCELLED The job cancellation was successful.
DONE The job has completed successfully.
ERROR The job has completed, but encountered an error.
ATTEMPT_FAILURE

Job attempt has failed. The detail field contains failure details for this attempt.

Applies to restartable jobs only.

Substate

The job substate.

Enums
UNSPECIFIED The job substate is unknown.
SUBMITTED

The Job is submitted to the agent.

Applies to RUNNING state.

QUEUED

The Job has been received and is awaiting execution (it might be waiting for a condition to be met). See the "details" field for the reason for the delay.

Applies to RUNNING state.

STALE_STATUS

The agent-reported status is out of date, which can be caused by a loss of communication between the agent and Dataproc. If the agent does not send a timely update, the job will fail.

Applies to RUNNING state.

KerberosConfig

Specifies Kerberos related configuration.

Fields
enable_kerberos

bool

Optional. Flag to indicate whether to Kerberize the cluster (default: false). Set this field to true to enable Kerberos on a cluster.

root_principal_password_uri

string

Optional. The Cloud Storage URI of a KMS encrypted file containing the root principal password.

kms_key_uri

string

Optional. The URI of the KMS key used to encrypt sensitive files.

keystore_uri

string

Optional. The Cloud Storage URI of the keystore file used for SSL encryption. If not provided, Dataproc will provide a self-signed certificate.

truststore_uri

string

Optional. The Cloud Storage URI of the truststore file used for SSL encryption. If not provided, Dataproc will provide a self-signed certificate.

keystore_password_uri

string

Optional. The Cloud Storage URI of a KMS encrypted file containing the password to the user provided keystore. For the self-signed certificate, this password is generated by Dataproc.

key_password_uri

string

Optional. The Cloud Storage URI of a KMS encrypted file containing the password to the user provided key. For the self-signed certificate, this password is generated by Dataproc.

truststore_password_uri

string

Optional. The Cloud Storage URI of a KMS encrypted file containing the password to the user provided truststore. For the self-signed certificate, this password is generated by Dataproc.

cross_realm_trust_realm

string

Optional. The remote realm the Dataproc on-cluster KDC will trust, should the user enable cross realm trust.

cross_realm_trust_kdc

string

Optional. The KDC (IP or hostname) for the remote trusted realm in a cross realm trust relationship.

cross_realm_trust_admin_server

string

Optional. The admin server (IP or hostname) for the remote trusted realm in a cross realm trust relationship.

cross_realm_trust_shared_password_uri

string

Optional. The Cloud Storage URI of a KMS encrypted file containing the shared password between the on-cluster Kerberos realm and the remote trusted realm, in a cross realm trust relationship.

kdc_db_key_uri

string

Optional. The Cloud Storage URI of a KMS encrypted file containing the master key of the KDC database.

tgt_lifetime_hours

int32

Optional. The lifetime of the ticket granting ticket, in hours. If not specified, or user specifies 0, then default value 10 will be used.

realm

string

Optional. The name of the on-cluster Kerberos realm. If not specified, the uppercased domain of hostnames will be the realm.

KubernetesClusterConfig

The configuration for running the Dataproc cluster on Kubernetes.

Fields
kubernetes_namespace

string

Optional. A namespace within the Kubernetes cluster to deploy into. If this namespace does not exist, it is created. If it exists, Dataproc verifies that another Dataproc VirtualCluster is not installed into it. If not specified, the name of the Dataproc Cluster is used.

kubernetes_software_config

KubernetesSoftwareConfig

Optional. The software configuration for this Dataproc cluster running on Kubernetes.

Union field config.

config can be only one of the following:

gke_cluster_config

GkeClusterConfig

Required. The configuration for running the Dataproc cluster on GKE.

KubernetesSoftwareConfig

The software configuration for this Dataproc cluster running on Kubernetes.

Fields
component_version

map<string, string>

The components that should be installed in this Dataproc cluster. The key must be a string from the KubernetesComponent enumeration. The value is the version of the software to be installed. At least one entry must be specified.

properties

map<string, string>

The properties to set on daemon config files.

Property keys are specified in prefix:property format, for example spark:spark.kubernetes.container.image. The following are supported prefixes and their mappings:

  • spark: spark-defaults.conf

For more information, see Cluster properties.

LifecycleConfig

Specifies the cluster auto-delete schedule configuration.

Fields
idle_delete_ttl

Duration

Optional. The duration to keep the cluster alive while idling (when no jobs are running). Passing this threshold will cause the cluster to be deleted. Minimum value is 5 minutes; maximum value is 14 days (see JSON representation of Duration).

idle_start_time

Timestamp

Output only. The time when cluster became idle (most recent job finished) and became eligible for deletion due to idleness (see JSON representation of Timestamp).

Union field ttl. Either the exact time the cluster should be deleted at or the cluster maximum age. ttl can be only one of the following:
auto_delete_time

Timestamp

Optional. The time when cluster will be auto-deleted (see JSON representation of Timestamp).

auto_delete_ttl

Duration

Optional. The lifetime duration of cluster. The cluster will be auto-deleted at the end of this period. Minimum value is 10 minutes; maximum value is 14 days (see JSON representation of Duration).

ListAutoscalingPoliciesRequest

A request to list autoscaling policies in a project.

Fields
parent

string

Required. The "resource name" of the region or location, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.autoscalingPolicies.list, the resource name of the region has the following format: projects/{project_id}/regions/{region}

  • For projects.locations.autoscalingPolicies.list, the resource name of the location has the following format: projects/{project_id}/locations/{location}

Authorization requires the following IAM permission on the specified resource parent:

  • dataproc.autoscalingPolicies.list
page_size

int32

Optional. The maximum number of results to return in each response. Must be less than or equal to 1000. Defaults to 100.

page_token

string

Optional. The page token, returned by a previous call, to request the next page of results.

ListAutoscalingPoliciesResponse

A response to a request to list autoscaling policies in a project.

Fields
policies[]

AutoscalingPolicy

Output only. Autoscaling policies list.

next_page_token

string

Output only. This token is included in the response if there are more results to fetch.

ListClustersRequest

A request to list the clusters in a project.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the cluster belongs to.

Authorization requires the following IAM permission on the specified resource projectId:

  • dataproc.clusters.list
region

string

Required. The Dataproc region in which to handle the request.

filter

string

Optional. A filter constraining the clusters to list. Filters are case-sensitive and have the following syntax:

field = value [AND [field = value]] ...

where field is one of status.state, clusterName, or labels.[KEY], and [KEY] is a label key. value can be * to match all values. status.state can be one of the following: ACTIVE, INACTIVE, CREATING, RUNNING, ERROR, DELETING, UPDATING, STOPPING, or STOPPED. ACTIVE contains the CREATING, UPDATING, and RUNNING states. INACTIVE contains the DELETING, ERROR, STOPPING, and STOPPED states. clusterName is the name of the cluster provided at creation time. Only the logical AND operator is supported; space-separated items are treated as having an implicit AND operator.

Example filter:

status.state = ACTIVE AND clusterName = mycluster AND labels.env = staging AND labels.starred = *

page_size

int32

Optional. The standard List page size.

page_token

string

Optional. The standard List page token.

ListClustersResponse

The list of all clusters in a project.

Fields
clusters[]

Cluster

Output only. The clusters in the project.

next_page_token

string

Output only. This token is included in the response if there are more results to fetch. To fetch additional results, provide this value as the page_token in a subsequent ListClustersRequest.

ListJobsRequest

A request to list jobs in a project.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the job belongs to.

Authorization requires the following IAM permission on the specified resource projectId:

  • dataproc.jobs.list
region

string

Required. The Dataproc region in which to handle the request.

page_size

int32

Optional. The number of results to return in each response.

page_token

string

Optional. The page token, returned by a previous call, to request the next page of results.

cluster_name

string

Optional. If set, the returned jobs list includes only jobs that were submitted to the named cluster.

job_state_matcher

JobStateMatcher

Optional. Specifies enumerated categories of jobs to list. (default = match ALL jobs).

If filter is provided, jobStateMatcher will be ignored.

filter

string

Optional. A filter constraining the jobs to list. Filters are case-sensitive and have the following syntax:

[field = value] AND [field [= value]] ...

where field is status.state or labels.[KEY], and [KEY] is a label key. value can be * to match all values. status.state can be either ACTIVE or NON_ACTIVE. Only the logical AND operator is supported; space-separated items are treated as having an implicit AND operator.

Example filter:

status.state = ACTIVE AND labels.env = staging AND labels.starred = *

JobStateMatcher

A matcher that specifies categories of job states.

Enums
ALL Match all jobs, regardless of state.
ACTIVE Only match jobs in non-terminal states: PENDING, RUNNING, or CANCEL_PENDING.
NON_ACTIVE Only match jobs in terminal states: CANCELLED, DONE, or ERROR.

ListJobsResponse

A list of jobs in a project.

Fields
jobs[]

Job

Output only. Jobs list.

next_page_token

string

Optional. This token is included in the response if there are more results to fetch. To fetch additional results, provide this value as the page_token in a subsequent

ListJobsRequest

.

unreachable[]

string

Output only. List of jobs with kms_key-encrypted parameters that could not be decrypted. A response to a jobs.get request may indicate the reason for the decryption failure for a specific job.

ListWorkflowTemplatesRequest

A request to list workflow templates in a project.

Fields
parent

string

Required. The resource name of the region or location, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.workflowTemplates,list, the resource name of the region has the following format: projects/{project_id}/regions/{region}

  • For projects.locations.workflowTemplates.list, the resource name of the location has the following format: projects/{project_id}/locations/{location}

Authorization requires the following IAM permission on the specified resource parent:

  • dataproc.workflowTemplates.list
page_size

int32

Optional. The maximum number of results to return in each response.

page_token

string

Optional. The page token, returned by a previous call, to request the next page of results.

ListWorkflowTemplatesResponse

A response to a request to list workflow templates in a project.

Fields
templates[]

WorkflowTemplate

Output only. WorkflowTemplates list.

next_page_token

string

Output only. This token is included in the response if there are more results to fetch. To fetch additional results, provide this value as the page_token in a subsequent

ListWorkflowTemplatesRequest

.

unreachable[]

string

Output only. List of workflow templates that could not be included in the response. Attempting to get one of these resources may indicate why it was not included in the list response.

LoggingConfig

The runtime logging config of the job.

Fields
driver_log_levels

map<string, Level>

The per-package log levels for the driver. This can include "root" package name to configure rootLogger. Examples: - 'com.google = FATAL' - 'root = INFO' - 'org.apache = DEBUG'

Level

The Log4j level for job execution. When running an Apache Hive job, Cloud Dataproc configures the Hive client to an equivalent verbosity level.

Enums
LEVEL_UNSPECIFIED Level is unspecified. Use default level for log4j.
ALL Use ALL level for log4j.
TRACE Use TRACE level for log4j.
DEBUG Use DEBUG level for log4j.
INFO Use INFO level for log4j.
WARN Use WARN level for log4j.
ERROR Use ERROR level for log4j.
FATAL Use FATAL level for log4j.
OFF Turn off log4j.

ManagedCluster

Cluster that is managed by the workflow.

Fields
cluster_name

string

Required. The cluster name prefix. A unique cluster name will be formed by appending a random suffix.

The name must contain only lower-case letters (a-z), numbers (0-9), and hyphens (-). Must begin with a letter. Cannot begin or end with hyphen. Must consist of between 2 and 35 characters.

config

ClusterConfig

Required. The cluster configuration.

labels

map<string, string>

Optional. The labels to associate with this cluster.

Label keys must be between 1 and 63 characters long, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}_-]{0,62}

Label values must be between 1 and 63 characters long, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}

No more than 32 labels can be associated with a given cluster.

ManagedGroupConfig

Specifies the resources used to actively manage an instance group.

Fields
instance_template_name

string

Output only. The name of the Instance Template used for the Managed Instance Group.

instance_group_manager_name

string

Output only. The name of the Instance Group Manager for this group.

instance_group_manager_uri

string

Output only. The partial URI to the instance group manager for this group. E.g. projects/my-project/regions/us-central1/instanceGroupManagers/my-igm.

MetastoreConfig

Specifies a Metastore configuration.

Fields
dataproc_metastore_service

string

Required. Resource name of an existing Dataproc Metastore service.

Example:

  • projects/[project_id]/locations/[dataproc_region]/services/[service-name]

NodeGroup

Dataproc Node Group. The Dataproc NodeGroup resource is not related to the Dataproc NodeGroupAffinity resource.

Fields
name

string

The Node group resource name.

roles[]

Role

Required. Node group roles.

node_group_config

InstanceGroupConfig

Optional. The node group instance group configuration.

labels

map<string, string>

Optional. Node group labels.

  • Label keys must consist of from 1 to 63 characters and conform to RFC 1035.
  • Label values can be empty. If specified, they must consist of from 1 to 63 characters and conform to RFC 1035.
  • The node group must have no more than 32 labelsn.

Role

Node pool roles.

Enums
ROLE_UNSPECIFIED Required unspecified role.
DRIVER Job drivers run on the node pool.

NodeGroupAffinity

Node Group Affinity for clusters using sole-tenant node groups. The Dataproc NodeGroupAffinity resource is not related to the Dataproc NodeGroup resource.

Fields
node_group_uri

string

Required. The URI of a sole-tenant node group resource that the cluster will be created on.

A full URL, partial URI, or node group name are valid. Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/zones/[zone]/nodeGroups/node-group-1
  • projects/[project_id]/zones/[zone]/nodeGroups/node-group-1
  • node-group-1

NodeGroupOperationMetadata

Metadata describing the node group operation.

Fields
node_group_id

string

Output only. Node group ID for the operation.

cluster_uuid

string

Output only. Cluster UUID associated with the node group operation.

status

ClusterOperationStatus

Output only. Current operation status.

status_history[]

ClusterOperationStatus

Output only. The previous operation status.

operation_type

NodeGroupOperationType

The operation type.

description

string

Output only. Short description of operation.

labels

map<string, string>

Output only. Labels associated with the operation.

warnings[]

string

Output only. Errors encountered during operation execution.

NodeGroupOperationType

Operation type for node group resources.

Enums
NODE_GROUP_OPERATION_TYPE_UNSPECIFIED Node group operation type is unknown.
CREATE Create node group operation type.
UPDATE Update node group operation type.
DELETE Delete node group operation type.
RESIZE Resize node group operation type.

NodeInitializationAction

Specifies an executable to run on a fully configured node and a timeout period for executable completion.

Fields
executable_file

string

Required. Cloud Storage URI of executable file.

execution_timeout

Duration

Optional. Amount of time executable has to complete. Default is 10 minutes (see JSON representation of Duration).

Cluster creation fails with an explanatory error message (the name of the executable that caused the error and the exceeded timeout period) if the executable is not completed at end of the timeout period.

OrderedJob

A job executed by the workflow.

Fields
step_id

string

Required. The step id. The id must be unique among all jobs within the template.

The step id is used as prefix for job id, as job goog-dataproc-workflow-step-id label, and in prerequisiteStepIds field from other steps.

The id must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). Cannot begin or end with underscore or hyphen. Must consist of between 3 and 50 characters.

labels

map<string, string>

Optional. The labels to associate with this job.

Label keys must be between 1 and 63 characters long, and must conform to the following regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}_-]{0,62}

Label values must be between 1 and 63 characters long, and must conform to the following regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}

No more than 32 labels can be associated with a given job.

scheduling

JobScheduling

Optional. Job scheduling configuration.

prerequisite_step_ids[]

string

Optional. The optional list of prerequisite job step_ids. If not specified, the job will start at the beginning of workflow.

Union field job_type. Required. The job definition. job_type can be only one of the following:
hadoop_job

HadoopJob

Optional. Job is a Hadoop job.

spark_job

SparkJob

Optional. Job is a Spark job.

pyspark_job

PySparkJob

Optional. Job is a PySpark job.

hive_job

HiveJob

Optional. Job is a Hive job.

pig_job

PigJob

Optional. Job is a Pig job.

spark_r_job

SparkRJob

Optional. Job is a SparkR job.

spark_sql_job

SparkSqlJob

Optional. Job is a SparkSql job.

presto_job

PrestoJob

Optional. Job is a Presto job.

ParameterValidation

Configuration for parameter validation.

Fields
Union field validation_type. Required. The type of validation to be performed. validation_type can be only one of the following:
regex

RegexValidation

Validation based on regular expressions.

values

ValueValidation

Validation based on a list of allowed values.

PigJob

A Dataproc job for running Apache Pig queries on YARN.

Fields
continue_on_failure

bool

Optional. Whether to continue executing queries if a query fails. The default value is false. Setting to true can be useful when executing independent parallel queries.

script_variables

map<string, string>

Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).

properties

map<string, string>

Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API might be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.

jar_file_uris[]

string

Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.

logging_config

LoggingConfig

Optional. The runtime log config for job execution.

Union field queries. Required. The sequence of Pig queries to execute, specified as an HCFS file URI or a list of queries. queries can be only one of the following:
query_file_uri

string

The HCFS URI of the script that contains the Pig queries.

query_list

QueryList

A list of queries.

PrestoJob

A Dataproc job for running Presto queries. IMPORTANT: The Dataproc Presto Optional Component must be enabled when the cluster is created to submit a Presto job to the cluster.

Fields
continue_on_failure

bool

Optional. Whether to continue executing queries if a query fails. The default value is false. Setting to true can be useful when executing independent parallel queries.

output_format

string

Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats

client_tags[]

string

Optional. Presto client tags to attach to this query

properties

map<string, string>

Optional. A mapping of property names to values. Used to set Presto session properties Equivalent to using the --session flag in the Presto CLI

logging_config

LoggingConfig

Optional. The runtime log config for job execution.

Union field queries. Required. The sequence of Presto queries to execute, specified as either an HCFS file URI or as a list of queries. queries can be only one of the following:
query_file_uri

string

The HCFS URI of the script that contains SQL queries.

query_list

QueryList

A list of queries.

PySparkJob

A Dataproc job for running Apache PySpark applications on YARN.

Fields
main_python_file_uri

string

Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.

args[]

string

Optional. The arguments to pass to the driver. Do not include arguments, such as --conf, that can be set as job properties, since a collision may occur that causes an incorrect job submission.

python_file_uris[]

string

Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.

jar_file_uris[]

string

Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.

file_uris[]

string

Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.

archive_uris[]

string

Optional. HCFS URIs of archives to be extracted into the working directory of each executor. Supported file types: .jar, .tar, .tar.gz, .tgz, and .zip.

properties

map<string, string>

Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API might be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.

logging_config

LoggingConfig

Optional. The runtime log config for job execution.

QueryList

A list of queries to run on a cluster.

Fields
queries[]

string

Required. The queries to execute. You do not need to end a query expression with a semicolon. Multiple queries can be specified in one string by separating each with a semicolon. Here is an example of a Dataproc API snippet that uses a QueryList to specify a HiveJob:

"hiveJob": {
  "queryList": {
    "queries": [
      "query1",
      "query2",
      "query3;query4",
    ]
  }
}

RegexValidation

Validation based on regular expressions.

Fields
regexes[]

string

Required. RE2 regular expressions used to validate the parameter's value. The value must match the regex in its entirety (substring matches are not sufficient).

ReservationAffinity

Reservation Affinity for consuming Zonal reservation.

Fields
consume_reservation_type

Type

Optional. Type of reservation to consume

key

string

Optional. Corresponds to the label key of reservation resource.

values[]

string

Optional. Corresponds to the label values of reservation resource.

Type

Indicates whether to consume capacity from an reservation or not.

Enums
TYPE_UNSPECIFIED
NO_RESERVATION Do not consume from any allocated capacity.
ANY_RESERVATION Consume any reservation available.
SPECIFIC_RESERVATION Must consume from a specific reservation. Must specify key value fields for specifying the reservations.

ResizeNodeGroupRequest

A request to resize a node group.

Fields
name

string

Required. The name of the node group to resize. Format: projects/{project}/regions/{region}/clusters/{cluster}/nodeGroups/{nodeGroup}

size

int32

Required. The number of running instances for the node group to maintain. The group adds or removes instances to maintain the number of instances specified by this parameter.

request_id

string

Optional. A unique ID used to identify the request. If the server receives two ResizeNodeGroupRequest with the same ID, the second request is ignored and the first google.longrunning.Operation created and stored in the backend is returned.

Recommendation: Set this value to a UUID.

The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

graceful_decommission_timeout

Duration

Optional. Timeout for graceful YARN decommissioning. Graceful decommissioning allows the removal of nodes from the Compute Engine node group without interrupting jobs in progress. This timeout specifies how long to wait for jobs in progress to finish before forcefully removing nodes (and potentially interrupting jobs). Default timeout is 0 (for forceful decommission), and the maximum allowed timeout is 1 day. (see JSON representation of Duration).

Only supported on Dataproc image versions 1.2 and higher.

parent_operation_id

string

Optional. operation id of the parent operation sending the resize request

SecurityConfig

Security related configuration, including encryption, Kerberos, etc.

Fields
kerberos_config

KerberosConfig

Optional. Kerberos related configuration.

identity_config

IdentityConfig

Optional. Identity related configuration, including service account based secure multi-tenancy user mappings.

ShieldedInstanceConfig

Shielded Instance Config for clusters using Compute Engine Shielded VMs.

Fields
enable_secure_boot

bool

Optional. Defines whether instances have Secure Boot enabled.

enable_vtpm

bool

Optional. Defines whether instances have the vTPM enabled.

enable_integrity_monitoring

bool

Optional. Defines whether instances have integrity monitoring enabled.

SoftwareConfig

Specifies the selection and config of software inside the cluster.

Fields
image_version

string

Optional. The version of software inside the cluster. It must be one of the supported Dataproc Versions, such as "1.2" (including a subminor version, such as "1.2.29"), or the "preview" version. If unspecified, it defaults to the latest Debian version.

properties

map<string, string>

Optional. The properties to set on daemon config files.

Property keys are specified in prefix:property format, for example core:hadoop.tmp.dir. The following are supported prefixes and their mappings:

  • capacity-scheduler: capacity-scheduler.xml
  • core: core-site.xml
  • distcp: distcp-default.xml
  • hdfs: hdfs-site.xml
  • hive: hive-site.xml
  • mapred: mapred-site.xml
  • pig: pig.properties
  • spark: spark-defaults.conf
  • yarn: yarn-site.xml

For more information, see Cluster properties.

optional_components[]

Component

Optional. The set of components to activate on the cluster.

SparkHistoryServerConfig

Spark History Server configuration for the workload.

Fields
dataproc_cluster

string

Optional. Resource name of an existing Dataproc Cluster to act as a Spark History Server for the workload.

Example:

  • projects/[project_id]/regions/[region]/clusters/[cluster_name]

SparkJob

A Dataproc job for running Apache Spark applications on YARN.

Fields
args[]

string

Optional. The arguments to pass to the driver. Do not include arguments, such as --conf, that can be set as job properties, since a collision may occur that causes an incorrect job submission.

jar_file_uris[]

string

Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.

file_uris[]

string

Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.

archive_uris[]

string

Optional. HCFS URIs of archives to be extracted into the working directory of each executor. Supported file types: .jar, .tar, .tar.gz, .tgz, and .zip.

properties

map<string, string>

Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API might be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.

logging_config

LoggingConfig

Optional. The runtime log config for job execution.

Union field driver. Required. The specification of the main method to call to drive the job. Specify either the jar file that contains the main class or the main class name. To pass both a main jar and a main class in that jar, add the jar to jarFileUris, and then specify the main class name in mainClass. driver can be only one of the following:
main_jar_file_uri

string

The HCFS URI of the jar file that contains the main class.

main_class

string

The name of the driver's main class. The jar file that contains the class must be in the default CLASSPATH or specified in SparkJob.jar_file_uris.

SparkRJob

A Dataproc job for running Apache SparkR applications on YARN.

Fields
main_r_file_uri

string

Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.

args[]

string

Optional. The arguments to pass to the driver. Do not include arguments, such as --conf, that can be set as job properties, since a collision may occur that causes an incorrect job submission.

file_uris[]

string

Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.

archive_uris[]

string

Optional. HCFS URIs of archives to be extracted into the working directory of each executor. Supported file types: .jar, .tar, .tar.gz, .tgz, and .zip.

properties

map<string, string>

Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API might be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.

logging_config

LoggingConfig

Optional. The runtime log config for job execution.

SparkSqlJob

A Dataproc job for running Apache Spark SQL queries.

Fields
script_variables

map<string, string>

Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name="value";).

properties

map<string, string>

Optional. A mapping of property names to values, used to configure Spark SQL's SparkConf. Properties that conflict with values set by the Dataproc API might be overwritten.

jar_file_uris[]

string

Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.

logging_config

LoggingConfig

Optional. The runtime log config for job execution.

Union field queries. Required. The sequence of Spark SQL queries to execute, specified as either an HCFS file URI or as a list of queries. queries can be only one of the following:
query_file_uri

string

The HCFS URI of the script that contains SQL queries.

query_list

QueryList

A list of queries.

StartClusterRequest

A request to start a cluster.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project the cluster belongs to.

region

string

Required. The Dataproc region in which to handle the request.

cluster_name

string

Required. The cluster name.

Authorization requires the following IAM permission on the specified resource clusterName:

  • dataproc.clusters.start
cluster_uuid

string

Optional. Specifying the cluster_uuid means the RPC will fail (with error NOT_FOUND) if a cluster with the specified UUID does not exist.

request_id

string

Optional. A unique ID used to identify the request. If the server receives two StartClusterRequests with the same id, then the second request will be ignored and the first google.longrunning.Operation created and stored in the backend is returned.

Recommendation: Set this value to a UUID.

The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

StartupConfig

Configuration to handle the startup of instances during cluster create and update process.

Fields
required_registration_fraction

double

Optional. The config setting to enable cluster creation/ updation to be successful only after required_registration_fraction of instances are up and running. This configuration is applicable to only secondary workers for now. The cluster will fail if required_registration_fraction of instances are not available. This will include instance creation, agent registration, and service registration (if enabled).

StopClusterRequest

A request to stop a cluster.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project the cluster belongs to.

region

string

Required. The Dataproc region in which to handle the request.

cluster_name

string

Required. The cluster name.

Authorization requires the following IAM permission on the specified resource clusterName:

  • dataproc.clusters.stop
cluster_uuid

string

Optional. Specifying the cluster_uuid means the RPC will fail (with error NOT_FOUND) if a cluster with the specified UUID does not exist.

request_id

string

Optional. A unique ID used to identify the request. If the server receives two StopClusterRequests with the same id, then the second request will be ignored and the first google.longrunning.Operation created and stored in the backend is returned.

Recommendation: Set this value to a UUID.

The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

SubmitJobRequest

A request to submit a job.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the job belongs to.

Authorization requires one or more of the following IAM permissions on the specified resource projectId:

  • dataproc.jobs.create
  • dataproc.clusters.use
region

string

Required. The Dataproc region in which to handle the request.

job

Job

Required. The job resource.

request_id

string

Optional. A unique id used to identify the request. If the server receives two SubmitJobRequests with the same id, then the second request will be ignored and the first Job created and stored in the backend is returned.

It is recommended to always set this value to a UUID.

The id must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

TemplateParameter

A configurable parameter that replaces one or more fields in the template. Parameterizable fields: - Labels - File uris - Job properties - Job arguments - Script variables - Main class (in HadoopJob and SparkJob) - Zone (in ClusterSelector)

Fields
name

string

Required. Parameter name. The parameter name is used as the key, and paired with the parameter value, which are passed to the template when the template is instantiated. The name must contain only capital letters (A-Z), numbers (0-9), and underscores (_), and must not start with a number. The maximum length is 40 characters.

fields[]

string

Required. Paths to all fields that the parameter replaces. A field is allowed to appear in at most one parameter's list of field paths.

A field path is similar in syntax to a google.protobuf.FieldMask. For example, a field path that references the zone field of a workflow template's cluster selector would be specified as placement.clusterSelector.zone.

Also, field paths can reference fields using the following syntax:

  • Values in maps can be referenced by key:

    • labels['key']
    • placement.clusterSelector.clusterLabels['key']
    • placement.managedCluster.labels['key']
    • placement.clusterSelector.clusterLabels['key']
    • jobs['step-id'].labels['key']
  • Jobs in the jobs list can be referenced by step-id:

    • jobs['step-id'].hadoopJob.mainJarFileUri
    • jobs['step-id'].hiveJob.queryFileUri
    • jobs['step-id'].pySparkJob.mainPythonFileUri
    • jobs['step-id'].hadoopJob.jarFileUris[0]
    • jobs['step-id'].hadoopJob.archiveUris[0]
    • jobs['step-id'].hadoopJob.fileUris[0]
    • jobs['step-id'].pySparkJob.pythonFileUris[0]
  • Items in repeated fields can be referenced by a zero-based index:

    • jobs['step-id'].sparkJob.args[0]
  • Other examples:

    • jobs['step-id'].hadoopJob.properties['key']
    • jobs['step-id'].hadoopJob.args[0]
    • jobs['step-id'].hiveJob.scriptVariables['key']
    • jobs['step-id'].hadoopJob.mainJarFileUri
    • placement.clusterSelector.zone

It may not be possible to parameterize maps and repeated fields in their entirety since only individual map values and individual items in repeated fields can be referenced. For example, the following field paths are invalid:

  • placement.clusterSelector.clusterLabels
  • jobs['step-id'].sparkJob.args
description

string

Optional. Brief description of the parameter. Must not exceed 1024 characters.

validation

ParameterValidation

Optional. Validation rules to be applied to this parameter's value.

UpdateAutoscalingPolicyRequest

A request to update an autoscaling policy.

Fields
policy

AutoscalingPolicy

Required. The updated autoscaling policy.

Authorization requires the following IAM permission on the specified resource policy:

  • dataproc.autoscalingPolicies.update

UpdateClusterRequest

A request to update a cluster.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project the cluster belongs to.

region

string

Required. The Dataproc region in which to handle the request.

cluster_name

string

Required. The cluster name.

cluster

Cluster

Required. The changes to the cluster.

Authorization requires the following IAM permission on the specified resource cluster:

  • dataproc.clusters.update
graceful_decommission_timeout

Duration

Optional. Timeout for graceful YARN decommissioning. Graceful decommissioning allows removing nodes from the cluster without interrupting jobs in progress. Timeout specifies how long to wait for jobs in progress to finish before forcefully removing nodes (and potentially interrupting jobs). Default timeout is 0 (for forceful decommission), and the maximum allowed timeout is 1 day. (see JSON representation of Duration).

Only supported on Dataproc image versions 1.2 and higher.

update_mask

FieldMask

Required. Specifies the path, relative to Cluster, of the field to update. For example, to change the number of workers in a cluster to 5, the update_mask parameter would be specified as config.worker_config.num_instances, and the PATCH request body would specify the new value, as follows:

{
  "config":{
    "workerConfig":{
      "numInstances":"5"
    }
  }
}

Similarly, to change the number of preemptible workers in a cluster to 5, the update_mask parameter would be config.secondary_worker_config.num_instances, and the PATCH request body would be set as follows:

{
  "config":{
    "secondaryWorkerConfig":{
      "numInstances":"5"
    }
  }
}

Note: Currently, only the following fields can be updated:

Mask Purpose
labels Update labels
config.worker_config.num_instances Resize primary worker group
config.secondary_worker_config.num_instances Resize secondary worker group
config.autoscaling_config.policy_uriUse, stop using, or change autoscaling policies

request_id

string

Optional. A unique ID used to identify the request. If the server receives two UpdateClusterRequests with the same id, then the second request will be ignored and the first google.longrunning.Operation created and stored in the backend is returned.

It is recommended to always set this value to a UUID.

The ID must contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-). The maximum length is 40 characters.

UpdateJobRequest

A request to update a job.

Fields
project_id

string

Required. The ID of the Google Cloud Platform project that the job belongs to.

Authorization requires the following IAM permission on the specified resource projectId:

  • dataproc.jobs.update
region

string

Required. The Dataproc region in which to handle the request.

job_id

string

Required. The job ID.

job

Job

Required. The changes to the job.

update_mask

FieldMask

Required. Specifies the path, relative to

Job

, of the field to update. For example, to update the labels of a Job the

update_mask

parameter would be specified as

labels

, and the PATCH request body would specify the new value. Note: Currently,

labels

is the only field that can be updated.

UpdateWorkflowTemplateRequest

A request to update a workflow template.

Fields
template

WorkflowTemplate

Required. The updated workflow template.

The template.version field must match the current version.

Authorization requires the following IAM permission on the specified resource template:

  • dataproc.workflowTemplates.update

ValueValidation

Validation based on a list of allowed values.

Fields
values[]

string

Required. List of allowed values for the parameter.

VirtualClusterConfig

The Dataproc cluster config for a cluster that does not directly control the underlying compute resources, such as a Dataproc-on-GKE cluster.

Fields
staging_bucket

string

Optional. A Cloud Storage bucket used to stage job dependencies, config files, and job driver console output. If you do not specify a staging bucket, Cloud Dataproc will determine a Cloud Storage location (US, ASIA, or EU) for your cluster's staging bucket according to the Compute Engine zone where your cluster is deployed, and then create and manage this project-level, per-location bucket (see Dataproc staging and temp buckets). This field requires a Cloud Storage bucket name, not a gs://... URI to a Cloud Storage bucket.

auxiliary_services_config

AuxiliaryServicesConfig

Optional. Configuration of auxiliary services used by this cluster.

Union field infrastructure_config.

infrastructure_config can be only one of the following:

kubernetes_cluster_config

KubernetesClusterConfig

Required. The configuration for running the Dataproc cluster on Kubernetes.

WorkflowGraph

The workflow graph.

Fields
nodes[]

WorkflowNode

Output only. The workflow nodes.

WorkflowMetadata

A Dataproc workflow template resource.

Fields
template

string

Output only. The resource name of the workflow template as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id}

  • For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

version

int32

Output only. The version of template at the time of workflow instantiation.

create_cluster

ClusterOperation

Output only. The create cluster operation metadata.

graph

WorkflowGraph

Output only. The workflow graph.

delete_cluster

ClusterOperation

Output only. The delete cluster operation metadata.

state

State

Output only. The workflow state.

cluster_name

string

Output only. The name of the target cluster.

parameters

map<string, string>

Map from parameter names to values that were used for those parameters.

start_time

Timestamp

Output only. Workflow start time.

end_time

Timestamp

Output only. Workflow end time.

cluster_uuid

string

Output only. The UUID of target cluster.

dag_timeout

Duration

Output only. The timeout duration for the DAG of jobs, expressed in seconds (see JSON representation of duration).

dag_start_time

Timestamp

Output only. DAG start time, only set for workflows with dag_timeout when DAG begins.

dag_end_time

Timestamp

Output only. DAG end time, only set for workflows with dag_timeout when DAG ends.

State

The operation state.

Enums
UNKNOWN Unused.
PENDING The operation has been created.
RUNNING The operation is running.
DONE The operation is done; either cancelled or completed.

WorkflowNode

The workflow node.

Fields
step_id

string

Output only. The name of the node.

prerequisite_step_ids[]

string

Output only. Node's prerequisite nodes.

job_id

string

Output only. The job id; populated after the node enters RUNNING state.

state

NodeState

Output only. The node state.

error

string

Output only. The error detail.

NodeState

The workflow node state.

Enums
NODE_STATE_UNSPECIFIED State is unspecified.
BLOCKED The node is awaiting prerequisite node to finish.
RUNNABLE The node is runnable but not running.
RUNNING The node is running.
COMPLETED The node completed successfully.
FAILED The node failed. A node can be marked FAILED because its ancestor or peer failed.

WorkflowTemplate

A Dataproc workflow template resource.

Fields
id

string

name

string

Output only. The resource name of the workflow template, as described in https://cloud.google.com/apis/design/resource_names.

  • For projects.regions.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/regions/{region}/workflowTemplates/{template_id}

  • For projects.locations.workflowTemplates, the resource name of the template has the following format: projects/{project_id}/locations/{location}/workflowTemplates/{template_id}

version

int32

Optional. Used to perform a consistent read-modify-write.

This field should be left blank for a CreateWorkflowTemplate request. It is required for an UpdateWorkflowTemplate request, and must match the current server version. A typical update template flow would fetch the current template with a GetWorkflowTemplate request, which will return the current template with the version field filled in with the current server version. The user updates other fields in the template, then returns it as part of the UpdateWorkflowTemplate request.

create_time

Timestamp

Output only. The time template was created.

update_time

Timestamp

Output only. The time template was last updated.

labels

map<string, string>

Optional. The labels to associate with this template. These labels will be propagated to all jobs and clusters created by the workflow instance.

Label keys must contain 1 to 63 characters, and must conform to RFC 1035.

Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035.

No more than 32 labels can be associated with a template.

placement

WorkflowTemplatePlacement

Required. WorkflowTemplate scheduling information.

jobs[]

OrderedJob

Required. The Directed Acyclic Graph of Jobs to submit.

parameters[]

TemplateParameter

Optional. Template parameters whose values are substituted into the template. Values for parameters must be provided when the template is instantiated.

dag_timeout

Duration

Optional. Timeout duration for the DAG of jobs, expressed in seconds (see JSON representation of duration). The timeout duration must be from 10 minutes ("600s") to 24 hours ("86400s"). The timer begins when the first job is submitted. If the workflow is running at the end of the timeout period, any remaining jobs are cancelled, the workflow is ended, and if the workflow was running on a managed cluster, the cluster is deleted.

encryption_config

EncryptionConfig

Optional. Encryption settings for encrypting workflow template job arguments.

EncryptionConfig

Encryption settings for encrypting workflow template job arguments.

Fields
kms_key

string

Optional. The Cloud KMS key name to use for encrypting workflow template job arguments.

When this this key is provided, the following workflow template job arguments, if present, are CMEK encrypted:

WorkflowTemplatePlacement

Specifies workflow execution target.

Either managed_cluster or cluster_selector is required.

Fields
Union field placement. Required. Specifies where workflow executes; either on a managed cluster or an existing cluster chosen by labels. placement can be only one of the following:
managed_cluster

ManagedCluster

A cluster that is managed by the workflow.

cluster_selector

ClusterSelector

Optional. A selector that chooses target cluster for jobs based on metadata.

The selector is evaluated at the time each job is submitted.

YarnApplication

A YARN application created by a job. Application information is a subset of

org.apache.hadoop.yarn.proto.YarnProtos.ApplicationReportProto

.

Beta Feature: This report is available for testing purposes only. It may be changed before final release.

Fields
name

string

Required. The application name.

state

State

Required. The application state.

progress

float

Required. The numerical progress of the application, from 1 to 100.

tracking_url

string

Optional. The HTTP URL of the ApplicationMaster, HistoryServer, or TimelineServer that provides application-specific information. The URL uses the internal hostname, and requires a proxy server for resolution and, possibly, access.

State

The application state, corresponding to

YarnProtos.YarnApplicationStateProto

.

Enums
STATE_UNSPECIFIED Status is unspecified.
NEW Status is NEW.
NEW_SAVING Status is NEW_SAVING.
SUBMITTED Status is SUBMITTED.
ACCEPTED Status is ACCEPTED.
RUNNING Status is RUNNING.
FINISHED Status is FINISHED.
FAILED Status is FAILED.
KILLED Status is KILLED.