Class: Google::Apis::DataprocV1::PrestoJob

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/dataproc_v1/classes.rb,
lib/google/apis/dataproc_v1/representations.rb,
lib/google/apis/dataproc_v1/representations.rb

Overview

A Dataproc job for running Presto (https://prestosql.io/) queries. IMPORTANT: The Dataproc Presto Optional Component (https://cloud.google.com/dataproc/docs/ concepts/components/presto) must be enabled when the cluster is created to submit a Presto job to the cluster.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ PrestoJob

Returns a new instance of PrestoJob.



4364
4365
4366
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4364

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#client_tagsArray<String>

Optional. Presto client tags to attach to this query Corresponds to the JSON property clientTags

Returns:

  • (Array<String>)


4326
4327
4328
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4326

def client_tags
  @client_tags
end

#continue_on_failureBoolean Also known as: continue_on_failure?

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. Corresponds to the JSON property continueOnFailure

Returns:

  • (Boolean)


4333
4334
4335
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4333

def continue_on_failure
  @continue_on_failure
end

#logging_configGoogle::Apis::DataprocV1::LoggingConfig

The runtime logging config of the job. Corresponds to the JSON property loggingConfig



4339
4340
4341
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4339

def logging_config
  @logging_config
end

#output_formatString

Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats Corresponds to the JSON property outputFormat

Returns:

  • (String)


4345
4346
4347
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4345

def output_format
  @output_format
end

#propertiesHash<String,String>

Optional. A mapping of property names to values. Used to set Presto session properties (https://prestodb.io/docs/current/sql/set-session.html) Equivalent to using the --session flag in the Presto CLI Corresponds to the JSON property properties

Returns:

  • (Hash<String,String>)


4352
4353
4354
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4352

def properties
  @properties
end

#query_file_uriString

The HCFS URI of the script that contains SQL queries. Corresponds to the JSON property queryFileUri

Returns:

  • (String)


4357
4358
4359
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4357

def query_file_uri
  @query_file_uri
end

#query_listGoogle::Apis::DataprocV1::QueryList

A list of queries to run on a cluster. Corresponds to the JSON property queryList



4362
4363
4364
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4362

def query_list
  @query_list
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



4369
4370
4371
4372
4373
4374
4375
4376
4377
# File 'lib/google/apis/dataproc_v1/classes.rb', line 4369

def update!(**args)
  @client_tags = args[:client_tags] if args.key?(:client_tags)
  @continue_on_failure = args[:continue_on_failure] if args.key?(:continue_on_failure)
  @logging_config = args[:logging_config] if args.key?(:logging_config)
  @output_format = args[:output_format] if args.key?(:output_format)
  @properties = args[:properties] if args.key?(:properties)
  @query_file_uri = args[:query_file_uri] if args.key?(:query_file_uri)
  @query_list = args[:query_list] if args.key?(:query_list)
end