generated/google-apis-dataproc_v1beta2/lib/google/apis/dataproc_v1beta2/service.rb
def patch_project_region_cluster(project_id, region, cluster_name, cluster_object = nil, graceful_decommission_timeout: nil, request_id: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
          command = make_simple_command(:patch, 'v1beta2/projects/{projectId}/regions/{region}/clusters/{clusterName}', options)
          command.request_representation = Google::Apis::DataprocV1beta2::Cluster::Representation
          command.request_object = cluster_object
          command.response_representation = Google::Apis::DataprocV1beta2::Operation::Representation
          command.response_class = Google::Apis::DataprocV1beta2::Operation
          command.params['projectId'] = project_id unless project_id.nil?
          command.params['region'] = region unless region.nil?
          command.params['clusterName'] = cluster_name unless cluster_name.nil?
          command.query['gracefulDecommissionTimeout'] = graceful_decommission_timeout unless graceful_decommission_timeout.nil?
          command.query['requestId'] = request_id unless request_id.nil?
          command.query['updateMask'] = update_mask unless update_mask.nil?
          command.query['fields'] = fields unless fields.nil?
          command.query['quotaUser'] = quota_user unless quota_user.nil?
          execute_or_queue_command(command, &block)
        end
# Updates a cluster in a project. The returned Operation.metadata will be
# ClusterOperationMetadata (https://cloud.google.com/dataproc/docs/reference/rpc/
# google.cloud.dataproc.v1beta2#clusteroperationmetadata). The cluster must be
# in a RUNNING state or an error is returned.
# @param [String] project_id
#   Required. The ID of the Google Cloud Platform project the cluster belongs to.
# @param [String] region
#   Required. The Dataproc region in which to handle the request.
# @param [String] cluster_name
#   Required. The cluster name.
# @param [Google::Apis::DataprocV1beta2::Cluster] cluster_object
# @param [String] graceful_decommission_timeout
#   Optional. Timeout for graceful YARN decomissioning. 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 (https://developers.google.com/protocol-
#   buffers/docs/proto3#json)).Only supported on Dataproc image versions 1.2 and
#   higher.
# @param [String] request_id
#   Optional. A unique id used to identify the request. If the server receives two
#   UpdateClusterRequest (https://cloud.google.com/dataproc/docs/reference/rpc/
#   google.cloud.dataproc.v1beta2#google.cloud.dataproc.v1beta2.
#   UpdateClusterRequest)s 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 (
#   https://en.wikipedia.org/wiki/Universally_unique_identifier).The id must
#   contain only letters (a-z, A-Z), numbers (0-9), underscores (_), and hyphens (-
#   ). The maximum length is 40 characters.
# @param [String] update_mask
#   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 Updates labels config.worker_config.num_instances Resize
#   primary worker group config.secondary_worker_config.num_instances Resize
#   secondary worker group config.lifecycle_config.auto_delete_ttl Reset MAX TTL
#   duration config.lifecycle_config.auto_delete_time Update MAX TTL deletion
#   timestamp config.lifecycle_config.idle_delete_ttl Update Idle TTL duration
#   config.autoscaling_config.policy_uri Use, stop using, or change autoscaling
#   policies
# @param [String] fields
#   Selector specifying which fields to include in a partial response.
# @param [String] quota_user
#   Available to use for quota purposes for server-side applications. Can be any
#   arbitrary string assigned to a user, but should not exceed 40 characters.
# @param [Google::Apis::RequestOptions] options
#   Request-specific options
#
# @yield [result, err] Result & error if block supplied
# @yieldparam result [Google::Apis::DataprocV1beta2::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::DataprocV1beta2::Operation]
#
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
# @raise [Google::Apis::AuthorizationError] Authorization is required
Updates a cluster in a project.
Updates a cluster in a project .
def patch_project_region_cluster(project_id, region, cluster_name, cluster_object = nil, graceful_decommission_timeout: nil, request_id: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
          command = make_simple_command(:patch, 'v1beta2/projects/{projectId}/regions/{region}/clusters/{clusterName}', options)
          command.request_representation = Google::Apis::DataprocV1beta2::Cluster::Representation
          command.request_object = cluster_object
          command.response_representation = Google::Apis::DataprocV1beta2::Operation::Representation
          command.response_class = Google::Apis::DataprocV1beta2::Operation
          command.params['projectId'] = project_id unless project_id.nil?
          command.params['region'] = region unless region.nil?
          command.params['clusterName'] = cluster_name unless cluster_name.nil?
          command.query['gracefulDecommissionTimeout'] = graceful_decommission_timeout unless graceful_decommission_timeout.nil?
          command.query['requestId'] = request_id unless request_id.nil?
          command.query['updateMask'] = update_mask unless update_mask.nil?
          command.query['fields'] = fields unless fields.nil?
          command.query['quotaUser'] = quota_user unless quota_user.nil?
          execute_or_queue_command(command, &block)
        end
def patch_project_region_cluster ( project_id , region , cluster_name , cluster_object = nil , graceful_decommission_timeout : nil , request_id : nil , update_mask : nil , fields : nil , quota_user : nil , options : nil , & block ) command = make_simple_command ( :patch , 'v1beta2/projects/{projectId}/regions/{region}/clusters/{clusterName}' , options ) command . request_representation = Google :: Apis :: DataprocV1beta2 :: Cluster :: Representation command . request_object = cluster_object command . response_representation = Google :: Apis :: DataprocV1beta2 :: Operation :: Representation command . response_class = Google :: Apis :: DataprocV1beta2 :: Operation command . params [ 'projectId' ] = project_id unless project_id . nil? command . params [ 'region' ] = region unless region . nil? command . params [ 'clusterName' ] = cluster_name unless cluster_name . nil? command . query [ 'gracefulDecommissionTimeout' ] = graceful_decommission_timeout unless graceful_decommission_timeout . nil? command . query [ 'requestId' ] = request_id unless request_id . nil? command . query [ 'updateMask' ] = update_mask unless update_mask . nil? command . query [ 'fields' ] = fields unless fields . nil? command . query [ 'quotaUser' ] = quota_user unless quota_user . nil? execute_or_queue_command ( command , & block ) end
Updates a cluster in a project.
Updates a cluster in a project .
None
Google::Apis::DataprocV1beta2::Operation
[Google::Apis::ServerError] An error occurred on the server and the request can be retried
[ Google :: Apis :: ServerError ] An error occurred on the server and the request can be retried
[Google::Apis::ClientError] The request is invalid and should not be retried without modification
[ Google :: Apis :: ClientError ] The request is invalid and should not be retried without modification
[Google::Apis::AuthorizationError] Authorization is required
[ Google :: Apis :: AuthorizationError ] Authorization is required
project_id
region
cluster_name
cluster_object
graceful_decommission_timeout
request_id
update_mask
fields
quota_user
options
block
options Request-specific options
options Request - specific options
]
Result & error if block supplied
Result & error if block supplied
result
parsed result object
parsed result object
err
error object if request failed
error object if request failed