blob: 5702e626ed26e5160a0d4241eecf9ca9b898662b [file] [log] [blame]
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070075<h1><a href="dataproc_v1.html">Cloud Dataproc API</a> . <a href="dataproc_v1.projects.html">projects</a> . <a href="dataproc_v1.projects.regions.html">regions</a> . <a href="dataproc_v1.projects.regions.jobs.html">jobs</a></h1>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080076<h2>Instance Methods</h2>
77<p class="toc_element">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070078 <code><a href="#cancel">cancel(projectId, region, jobId, body=None, x__xgafv=None)</a></code></p>
Dan O'Mearadd494642020-05-01 07:42:23 -070079<p class="firstline">Starts a job cancellation request. To access the job resource after cancellation, call regions/{region}/jobs.list (https://cloud.google.com/dataproc/docs/reference/rest/v1/projects.regions.jobs/list) or regions/{region}/jobs.get (https://cloud.google.com/dataproc/docs/reference/rest/v1/projects.regions.jobs/get).</p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080080<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070081 <code><a href="#close">close()</a></code></p>
82<p class="firstline">Close httplib2 connections.</p>
83<p class="toc_element">
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080084 <code><a href="#delete">delete(projectId, region, jobId, x__xgafv=None)</a></code></p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -040085<p class="firstline">Deletes the job from the project. If the job is active, the delete fails, and the response returns FAILED_PRECONDITION.</p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080086<p class="toc_element">
87 <code><a href="#get">get(projectId, region, jobId, x__xgafv=None)</a></code></p>
88<p class="firstline">Gets the resource representation for a job in a project.</p>
89<p class="toc_element">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070090 <code><a href="#getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</a></code></p>
91<p class="firstline">Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.</p>
92<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070093 <code><a href="#list">list(projectId, region, pageSize=None, pageToken=None, clusterName=None, jobStateMatcher=None, filter=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080094<p class="firstline">Lists regions/{region}/jobs in a project.</p>
95<p class="toc_element">
96 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
97<p class="firstline">Retrieves the next page of results.</p>
98<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070099 <code><a href="#patch">patch(projectId, region, jobId, body=None, updateMask=None, x__xgafv=None)</a></code></p>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400100<p class="firstline">Updates a job in a project.</p>
101<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700102 <code><a href="#setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700103<p class="firstline">Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700104<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700105 <code><a href="#submit">submit(projectId, region, body=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800106<p class="firstline">Submits a job to a cluster.</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700107<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700108 <code><a href="#submitAsOperation">submitAsOperation(projectId, region, body=None, x__xgafv=None)</a></code></p>
109<p class="firstline">Submits job to a cluster.</p>
110<p class="toc_element">
111 <code><a href="#testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700112<p class="firstline">Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning.</p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800113<h3>Method Details</h3>
114<div class="method">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700115 <code class="details" id="cancel">cancel(projectId, region, jobId, body=None, x__xgafv=None)</code>
Dan O'Mearadd494642020-05-01 07:42:23 -0700116 <pre>Starts a job cancellation request. To access the job resource after cancellation, call regions/{region}/jobs.list (https://cloud.google.com/dataproc/docs/reference/rest/v1/projects.regions.jobs/list) or regions/{region}/jobs.get (https://cloud.google.com/dataproc/docs/reference/rest/v1/projects.regions.jobs/get).
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800117
118Args:
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400119 projectId: string, Required. The ID of the Google Cloud Platform project that the job belongs to. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700120 region: string, Required. The Dataproc region in which to handle the request. (required)
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400121 jobId: string, Required. The job ID. (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700122 body: object, The request body.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800123 The object takes the form of:
124
125{ # A request to cancel a job.
126 }
127
128 x__xgafv: string, V1 error format.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400129 Allowed values
130 1 - v1 error format
131 2 - v2 error format
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800132
133Returns:
134 An object of the form:
135
Dan O'Mearadd494642020-05-01 07:42:23 -0700136 { # A Dataproc job resource.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700137 &quot;sparkRJob&quot;: { # A Dataproc job for running Apache SparkR (https://spark.apache.org/docs/latest/sparkr.html) applications on YARN. # Optional. Job is a SparkR job.
138 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700139 &quot;a_key&quot;: &quot;A String&quot;,
140 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700141 &quot;archiveUris&quot;: [ # 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.
142 &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700143 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700144 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
145 &quot;A String&quot;,
146 ],
147 &quot;args&quot;: [ # 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.
148 &quot;A String&quot;,
149 ],
150 &quot;mainRFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.
151 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
152 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
153 &quot;a_key&quot;: &quot;A String&quot;,
154 },
155 },
156 },
157 &quot;prestoJob&quot;: { # 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. # Optional. Job is a Presto job.
158 &quot;continueOnFailure&quot;: True or False, # 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.
159 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
160 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
161 &quot;a_key&quot;: &quot;A String&quot;,
162 },
163 },
164 &quot;clientTags&quot;: [ # Optional. Presto client tags to attach to this query
165 &quot;A String&quot;,
166 ],
167 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
168 &quot;properties&quot;: { # 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
169 &quot;a_key&quot;: &quot;A String&quot;,
170 },
171 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
172 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
173 &quot;A String&quot;,
174 ],
175 },
176 &quot;outputFormat&quot;: &quot;A String&quot;, # Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats
177 },
178 &quot;statusHistory&quot;: [ # Output only. The previous job status.
179 { # Dataproc job status.
180 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
181 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
182 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
183 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
184 },
185 ],
186 &quot;pigJob&quot;: { # A Dataproc job for running Apache Pig (https://pig.apache.org/) queries on YARN. # Optional. Job is a Pig job.
187 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).
188 &quot;a_key&quot;: &quot;A String&quot;,
189 },
190 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
191 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
192 &quot;a_key&quot;: &quot;A String&quot;,
193 },
194 },
195 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.
196 &quot;a_key&quot;: &quot;A String&quot;,
197 },
198 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
199 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
200 &quot;A String&quot;,
201 ],
202 },
203 &quot;continueOnFailure&quot;: True or False, # 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.
204 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.
205 &quot;A String&quot;,
206 ],
207 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains the Pig queries.
208 },
209 &quot;status&quot;: { # Dataproc job status. # Output only. The job status. Additional application-specific status information may be contained in the type_job and yarn_applications fields.
210 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
211 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
212 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
213 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
214 },
215 &quot;jobUuid&quot;: &quot;A String&quot;, # 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 may be reused over time.
216 &quot;pysparkJob&quot;: { # A Dataproc job for running Apache PySpark (https://spark.apache.org/docs/0.9.0/python-programming-guide.html) applications on YARN. # Optional. Job is a PySpark job.
217 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
218 &quot;a_key&quot;: &quot;A String&quot;,
219 },
220 &quot;mainPythonFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.
221 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
222 &quot;A String&quot;,
223 ],
224 &quot;archiveUris&quot;: [ # 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.
225 &quot;A String&quot;,
226 ],
227 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.
228 &quot;A String&quot;,
229 ],
230 &quot;args&quot;: [ # 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.
231 &quot;A String&quot;,
232 ],
233 &quot;pythonFileUris&quot;: [ # Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.
234 &quot;A String&quot;,
235 ],
236 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
237 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
238 &quot;a_key&quot;: &quot;A String&quot;,
239 },
240 },
241 },
242 &quot;placement&quot;: { # Dataproc job config. # Required. Job information, including how, when, and where to run the job.
243 &quot;clusterName&quot;: &quot;A String&quot;, # Required. The name of the cluster where the job will be submitted.
244 &quot;clusterUuid&quot;: &quot;A String&quot;, # Output only. A cluster UUID generated by the Dataproc service when the job is submitted.
245 },
246 &quot;hadoopJob&quot;: { # A Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). # Optional. Job is a Hadoop job.
247 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.
248 &quot;a_key&quot;: &quot;A String&quot;,
249 },
250 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file containing the main class. Examples: &#x27;gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar&#x27; &#x27;hdfs:/tmp/test-samples/custom-wordcount.jar&#x27; &#x27;file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar&#x27;
251 &quot;args&quot;: [ # 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 may occur that causes an incorrect job submission.
252 &quot;A String&quot;,
253 ],
254 &quot;jarFileUris&quot;: [ # Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.
255 &quot;A String&quot;,
256 ],
257 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
258 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
259 &quot;a_key&quot;: &quot;A String&quot;,
260 },
261 },
262 &quot;archiveUris&quot;: [ # 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.
263 &quot;A String&quot;,
264 ],
265 &quot;fileUris&quot;: [ # 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.
266 &quot;A String&quot;,
267 ],
268 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.
269 },
270 &quot;sparkSqlJob&quot;: { # A Dataproc job for running Apache Spark SQL (http://spark.apache.org/sql/) queries. # Optional. Job is a SparkSql job.
271 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark SQL&#x27;s SparkConf. Properties that conflict with values set by the Dataproc API may be overwritten.
272 &quot;a_key&quot;: &quot;A String&quot;,
273 },
274 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
275 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
276 &quot;A String&quot;,
277 ],
278 },
279 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
280 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
281 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
282 &quot;a_key&quot;: &quot;A String&quot;,
283 },
284 },
285 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name=&quot;value&quot;;).
286 &quot;a_key&quot;: &quot;A String&quot;,
287 },
288 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.
289 &quot;A String&quot;,
290 ],
291 },
292 &quot;driverControlFilesUri&quot;: &quot;A String&quot;, # Output only. If present, the location of miscellaneous control files which may be used as part of job setup and handling. If not present, control files may be placed in the same location as driver_output_uri.
293 &quot;sparkJob&quot;: { # A Dataproc job for running Apache Spark (http://spark.apache.org/) applications on YARN. # Optional. Job is a Spark job.
294 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
295 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
296 &quot;a_key&quot;: &quot;A String&quot;,
297 },
298 },
299 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file that contains the main class.
300 &quot;args&quot;: [ # 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.
301 &quot;A String&quot;,
302 ],
303 &quot;archiveUris&quot;: [ # 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.
304 &quot;A String&quot;,
305 ],
306 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.
307 &quot;A String&quot;,
308 ],
309 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
310 &quot;a_key&quot;: &quot;A String&quot;,
311 },
312 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
313 &quot;A String&quot;,
314 ],
315 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file that contains the class must be in the default CLASSPATH or specified in jar_file_uris.
316 },
317 &quot;done&quot;: True or False, # 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.
318 &quot;scheduling&quot;: { # Job scheduling options. # Optional. Job scheduling configuration.
319 &quot;maxFailuresPerHour&quot;: 42, # Optional. Maximum number of times per hour a driver may be restarted as a result of driver exiting with non-zero code before job is reported failed.A job may be reported as thrashing if driver exits with non-zero code 4 times within 10 minute window.Maximum value is 10.
320 },
321 &quot;reference&quot;: { # Encapsulates the full scoping used to reference a job. # 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.
322 &quot;jobId&quot;: &quot;A String&quot;, # 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.
323 &quot;projectId&quot;: &quot;A String&quot;, # Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.
324 },
325 &quot;hiveJob&quot;: { # A Dataproc job for running Apache Hive (https://hive.apache.org/) queries on YARN. # Optional. Job is a Hive job.
326 &quot;continueOnFailure&quot;: True or False, # 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.
327 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains Hive queries.
328 &quot;properties&quot;: { # Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.
329 &quot;a_key&quot;: &quot;A String&quot;,
330 },
331 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name=&quot;value&quot;;).
332 &quot;a_key&quot;: &quot;A String&quot;,
333 },
334 &quot;jarFileUris&quot;: [ # 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.
335 &quot;A String&quot;,
336 ],
337 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
338 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
339 &quot;A String&quot;,
340 ],
341 },
342 },
343 &quot;driverOutputResourceUri&quot;: &quot;A String&quot;, # Output only. A URI pointing to the location of the stdout of the job&#x27;s driver program.
344 &quot;yarnApplications&quot;: [ # Output only. The collection of YARN applications spun up by this job.Beta Feature: This report is available for testing purposes only. It may be changed before final release.
345 { # 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.
346 &quot;name&quot;: &quot;A String&quot;, # Required. The application name.
347 &quot;state&quot;: &quot;A String&quot;, # Required. The application state.
348 &quot;trackingUrl&quot;: &quot;A String&quot;, # 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.
349 &quot;progress&quot;: 3.14, # Required. The numerical progress of the application, from 1 to 100.
350 },
351 ],
352 &quot;labels&quot;: { # Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). No more than 32 labels can be associated with a job.
353 &quot;a_key&quot;: &quot;A String&quot;,
354 },
355 }</pre>
356</div>
357
358<div class="method">
359 <code class="details" id="close">close()</code>
360 <pre>Close httplib2 connections.</pre>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800361</div>
362
363<div class="method">
364 <code class="details" id="delete">delete(projectId, region, jobId, x__xgafv=None)</code>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400365 <pre>Deletes the job from the project. If the job is active, the delete fails, and the response returns FAILED_PRECONDITION.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800366
367Args:
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400368 projectId: string, Required. The ID of the Google Cloud Platform project that the job belongs to. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700369 region: string, Required. The Dataproc region in which to handle the request. (required)
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400370 jobId: string, Required. The job ID. (required)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800371 x__xgafv: string, V1 error format.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400372 Allowed values
373 1 - v1 error format
374 2 - v2 error format
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800375
376Returns:
377 An object of the form:
378
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700379 { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for Empty is empty JSON object {}.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800380 }</pre>
381</div>
382
383<div class="method">
384 <code class="details" id="get">get(projectId, region, jobId, x__xgafv=None)</code>
385 <pre>Gets the resource representation for a job in a project.
386
387Args:
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400388 projectId: string, Required. The ID of the Google Cloud Platform project that the job belongs to. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700389 region: string, Required. The Dataproc region in which to handle the request. (required)
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400390 jobId: string, Required. The job ID. (required)
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800391 x__xgafv: string, V1 error format.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400392 Allowed values
393 1 - v1 error format
394 2 - v2 error format
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800395
396Returns:
397 An object of the form:
398
Dan O'Mearadd494642020-05-01 07:42:23 -0700399 { # A Dataproc job resource.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700400 &quot;sparkRJob&quot;: { # A Dataproc job for running Apache SparkR (https://spark.apache.org/docs/latest/sparkr.html) applications on YARN. # Optional. Job is a SparkR job.
401 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700402 &quot;a_key&quot;: &quot;A String&quot;,
403 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700404 &quot;archiveUris&quot;: [ # 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.
405 &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700406 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700407 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
408 &quot;A String&quot;,
409 ],
410 &quot;args&quot;: [ # 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.
411 &quot;A String&quot;,
412 ],
413 &quot;mainRFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.
414 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
415 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
416 &quot;a_key&quot;: &quot;A String&quot;,
417 },
418 },
419 },
420 &quot;prestoJob&quot;: { # 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. # Optional. Job is a Presto job.
421 &quot;continueOnFailure&quot;: True or False, # 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.
422 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
423 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
424 &quot;a_key&quot;: &quot;A String&quot;,
425 },
426 },
427 &quot;clientTags&quot;: [ # Optional. Presto client tags to attach to this query
428 &quot;A String&quot;,
429 ],
430 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
431 &quot;properties&quot;: { # 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
432 &quot;a_key&quot;: &quot;A String&quot;,
433 },
434 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
435 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
436 &quot;A String&quot;,
437 ],
438 },
439 &quot;outputFormat&quot;: &quot;A String&quot;, # Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats
440 },
441 &quot;statusHistory&quot;: [ # Output only. The previous job status.
442 { # Dataproc job status.
443 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
444 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
445 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
446 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
447 },
448 ],
449 &quot;pigJob&quot;: { # A Dataproc job for running Apache Pig (https://pig.apache.org/) queries on YARN. # Optional. Job is a Pig job.
450 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).
451 &quot;a_key&quot;: &quot;A String&quot;,
452 },
453 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
454 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
455 &quot;a_key&quot;: &quot;A String&quot;,
456 },
457 },
458 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.
459 &quot;a_key&quot;: &quot;A String&quot;,
460 },
461 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
462 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
463 &quot;A String&quot;,
464 ],
465 },
466 &quot;continueOnFailure&quot;: True or False, # 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.
467 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.
468 &quot;A String&quot;,
469 ],
470 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains the Pig queries.
471 },
472 &quot;status&quot;: { # Dataproc job status. # Output only. The job status. Additional application-specific status information may be contained in the type_job and yarn_applications fields.
473 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
474 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
475 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
476 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
477 },
478 &quot;jobUuid&quot;: &quot;A String&quot;, # 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 may be reused over time.
479 &quot;pysparkJob&quot;: { # A Dataproc job for running Apache PySpark (https://spark.apache.org/docs/0.9.0/python-programming-guide.html) applications on YARN. # Optional. Job is a PySpark job.
480 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
481 &quot;a_key&quot;: &quot;A String&quot;,
482 },
483 &quot;mainPythonFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.
484 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
485 &quot;A String&quot;,
486 ],
487 &quot;archiveUris&quot;: [ # 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.
488 &quot;A String&quot;,
489 ],
490 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.
491 &quot;A String&quot;,
492 ],
493 &quot;args&quot;: [ # 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.
494 &quot;A String&quot;,
495 ],
496 &quot;pythonFileUris&quot;: [ # Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.
497 &quot;A String&quot;,
498 ],
499 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
500 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
501 &quot;a_key&quot;: &quot;A String&quot;,
502 },
503 },
504 },
505 &quot;placement&quot;: { # Dataproc job config. # Required. Job information, including how, when, and where to run the job.
506 &quot;clusterName&quot;: &quot;A String&quot;, # Required. The name of the cluster where the job will be submitted.
507 &quot;clusterUuid&quot;: &quot;A String&quot;, # Output only. A cluster UUID generated by the Dataproc service when the job is submitted.
508 },
509 &quot;hadoopJob&quot;: { # A Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). # Optional. Job is a Hadoop job.
510 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.
511 &quot;a_key&quot;: &quot;A String&quot;,
512 },
513 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file containing the main class. Examples: &#x27;gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar&#x27; &#x27;hdfs:/tmp/test-samples/custom-wordcount.jar&#x27; &#x27;file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar&#x27;
514 &quot;args&quot;: [ # 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 may occur that causes an incorrect job submission.
515 &quot;A String&quot;,
516 ],
517 &quot;jarFileUris&quot;: [ # Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.
518 &quot;A String&quot;,
519 ],
520 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
521 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
522 &quot;a_key&quot;: &quot;A String&quot;,
523 },
524 },
525 &quot;archiveUris&quot;: [ # 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.
526 &quot;A String&quot;,
527 ],
528 &quot;fileUris&quot;: [ # 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.
529 &quot;A String&quot;,
530 ],
531 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.
532 },
533 &quot;sparkSqlJob&quot;: { # A Dataproc job for running Apache Spark SQL (http://spark.apache.org/sql/) queries. # Optional. Job is a SparkSql job.
534 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark SQL&#x27;s SparkConf. Properties that conflict with values set by the Dataproc API may be overwritten.
535 &quot;a_key&quot;: &quot;A String&quot;,
536 },
537 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
538 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
539 &quot;A String&quot;,
540 ],
541 },
542 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
543 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
544 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
545 &quot;a_key&quot;: &quot;A String&quot;,
546 },
547 },
548 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name=&quot;value&quot;;).
549 &quot;a_key&quot;: &quot;A String&quot;,
550 },
551 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.
552 &quot;A String&quot;,
553 ],
554 },
555 &quot;driverControlFilesUri&quot;: &quot;A String&quot;, # Output only. If present, the location of miscellaneous control files which may be used as part of job setup and handling. If not present, control files may be placed in the same location as driver_output_uri.
556 &quot;sparkJob&quot;: { # A Dataproc job for running Apache Spark (http://spark.apache.org/) applications on YARN. # Optional. Job is a Spark job.
557 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
558 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
559 &quot;a_key&quot;: &quot;A String&quot;,
560 },
561 },
562 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file that contains the main class.
563 &quot;args&quot;: [ # 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.
564 &quot;A String&quot;,
565 ],
566 &quot;archiveUris&quot;: [ # 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.
567 &quot;A String&quot;,
568 ],
569 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.
570 &quot;A String&quot;,
571 ],
572 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
573 &quot;a_key&quot;: &quot;A String&quot;,
574 },
575 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
576 &quot;A String&quot;,
577 ],
578 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file that contains the class must be in the default CLASSPATH or specified in jar_file_uris.
579 },
580 &quot;done&quot;: True or False, # 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.
581 &quot;scheduling&quot;: { # Job scheduling options. # Optional. Job scheduling configuration.
582 &quot;maxFailuresPerHour&quot;: 42, # Optional. Maximum number of times per hour a driver may be restarted as a result of driver exiting with non-zero code before job is reported failed.A job may be reported as thrashing if driver exits with non-zero code 4 times within 10 minute window.Maximum value is 10.
583 },
584 &quot;reference&quot;: { # Encapsulates the full scoping used to reference a job. # 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.
585 &quot;jobId&quot;: &quot;A String&quot;, # 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.
586 &quot;projectId&quot;: &quot;A String&quot;, # Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.
587 },
588 &quot;hiveJob&quot;: { # A Dataproc job for running Apache Hive (https://hive.apache.org/) queries on YARN. # Optional. Job is a Hive job.
589 &quot;continueOnFailure&quot;: True or False, # 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.
590 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains Hive queries.
591 &quot;properties&quot;: { # Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.
592 &quot;a_key&quot;: &quot;A String&quot;,
593 },
594 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name=&quot;value&quot;;).
595 &quot;a_key&quot;: &quot;A String&quot;,
596 },
597 &quot;jarFileUris&quot;: [ # 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.
598 &quot;A String&quot;,
599 ],
600 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
601 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
602 &quot;A String&quot;,
603 ],
604 },
605 },
606 &quot;driverOutputResourceUri&quot;: &quot;A String&quot;, # Output only. A URI pointing to the location of the stdout of the job&#x27;s driver program.
607 &quot;yarnApplications&quot;: [ # Output only. The collection of YARN applications spun up by this job.Beta Feature: This report is available for testing purposes only. It may be changed before final release.
608 { # 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.
609 &quot;name&quot;: &quot;A String&quot;, # Required. The application name.
610 &quot;state&quot;: &quot;A String&quot;, # Required. The application state.
611 &quot;trackingUrl&quot;: &quot;A String&quot;, # 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.
612 &quot;progress&quot;: 3.14, # Required. The numerical progress of the application, from 1 to 100.
613 },
614 ],
615 &quot;labels&quot;: { # Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). No more than 32 labels can be associated with a job.
616 &quot;a_key&quot;: &quot;A String&quot;,
617 },
618 }</pre>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800619</div>
620
621<div class="method">
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700622 <code class="details" id="getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</code>
623 <pre>Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.
624
625Args:
626 resource: string, REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field. (required)
627 body: object, The request body.
628 The object takes the form of:
629
630{ # Request message for GetIamPolicy method.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700631 &quot;options&quot;: { # Encapsulates settings provided to GetIamPolicy. # OPTIONAL: A GetPolicyOptions object for specifying options to GetIamPolicy.
632 &quot;requestedPolicyVersion&quot;: 42, # Optional. The policy format version to be returned.Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected.Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -0700633 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700634 }
635
636 x__xgafv: string, V1 error format.
637 Allowed values
638 1 - v1 error format
639 2 - v2 error format
640
641Returns:
642 An object of the form:
643
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700644 { # An Identity and Access Management (IAM) policy, which specifies access controls for Google Cloud resources.A Policy is a collection of bindings. A binding binds one or more members to a single role. Members can be user accounts, service accounts, Google groups, and domains (such as G Suite). A role is a named list of permissions; each role can be an IAM predefined role or a user-created custom role.For some types of Google Cloud resources, a binding can also specify a condition, which is a logical expression that allows access to a resource only if the expression evaluates to true. A condition can add constraints based on attributes of the request, the resource, or both. To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).JSON example: { &quot;bindings&quot;: [ { &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;, &quot;members&quot;: [ &quot;user:mike@example.com&quot;, &quot;group:admins@example.com&quot;, &quot;domain:google.com&quot;, &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot; ] }, { &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;, &quot;members&quot;: [ &quot;user:eve@example.com&quot; ], &quot;condition&quot;: { &quot;title&quot;: &quot;expirable access&quot;, &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;, &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;, } } ], &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;, &quot;version&quot;: 3 } YAML example: bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/resourcemanager.organizationAdmin - members: - user:eve@example.com role: roles/resourcemanager.organizationViewer condition: title: expirable access description: Does not grant access after Sep 2020 expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;) - etag: BwWWja0YfJA= - version: 3 For a description of IAM and its features, see the IAM documentation (https://cloud.google.com/iam/docs/).
Bu Sun Kim65020912020-05-20 12:08:20 -0700645 &quot;bindings&quot;: [ # Associates a list of members to a role. Optionally, may specify a condition that determines how and when the bindings are applied. Each of the bindings must contain at least one member.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700646 { # Associates members with a role.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700647 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to members. For example, roles/viewer, roles/editor, or roles/owner.
648 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec.Example (Comparison): title: &quot;Summary size limit&quot; description: &quot;Determines if a summary is less than 100 chars&quot; expression: &quot;document.summary.size() &lt; 100&quot; Example (Equality): title: &quot;Requestor is owner&quot; description: &quot;Determines if requestor is the document owner&quot; expression: &quot;document.owner == request.auth.claims.email&quot; Example (Logic): title: &quot;Public documents&quot; description: &quot;Determine whether the document should be publicly visible&quot; expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot; Example (Data Manipulation): title: &quot;Notification string&quot; description: &quot;Create a notification string with a timestamp.&quot; expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot; The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information. # The condition that is associated with this binding.If the condition evaluates to true, then this binding applies to the current request.If the condition evaluates to false, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the members in this binding.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).
Bu Sun Kim65020912020-05-20 12:08:20 -0700649 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language syntax.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700650 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
651 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
652 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700653 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700654 &quot;bindingId&quot;: &quot;A String&quot;, # A client-specified ID for this binding. Expected to be globally unique to support the internal bindings-by-ID API.
655 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource. members can have the following values: allUsers: A special identifier that represents anyone who is on the internet; with or without a Google account. allAuthenticatedUsers: A special identifier that represents anyone who is authenticated with a Google account or a service account. user:{emailid}: An email address that represents a specific Google account. For example, alice@example.com . serviceAccount:{emailid}: An email address that represents a service account. For example, my-other-app@appspot.gserviceaccount.com. group:{emailid}: An email address that represents a Google group. For example, admins@example.com. deleted:user:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a user that has been recently deleted. For example, alice@example.com?uid=123456789012345678901. If the user is recovered, this value reverts to user:{emailid} and the recovered user retains the role in the binding. deleted:serviceAccount:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901. If the service account is undeleted, this value reverts to serviceAccount:{emailid} and the undeleted service account retains the role in the binding. deleted:group:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, admins@example.com?uid=123456789012345678901. If the group is recovered, this value reverts to group:{emailid} and the recovered group retains the role in the binding. domain:{domain}: The G Suite domain (primary) that represents all the users of that domain. For example, google.com or example.com.
Bu Sun Kim65020912020-05-20 12:08:20 -0700656 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700657 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700658 },
659 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700660 &quot;version&quot;: 42, # Specifies the format of the policy.Valid values are 0, 1, and 3. Requests that specify an invalid value are rejected.Any operation that affects conditional role bindings must specify version 3. This requirement applies to the following operations: Getting a policy that includes a conditional role binding Adding a conditional role binding to a policy Changing a conditional role binding in a policy Removing any role binding, with or without a condition, from a policy that includes conditionsImportant: If you use IAM Conditions, you must include the etag field whenever you call setIamPolicy. If you omit this field, then IAM allows you to overwrite a version 3 policy with a version 1 policy, and all of the conditions in the version 3 policy are lost.If a policy does not include any conditions, operations on that policy may specify any valid version or leave the field unset.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).
661 &quot;etag&quot;: &quot;A String&quot;, # etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An etag is returned in the response to getIamPolicy, and systems are expected to put that etag in the request to setIamPolicy to ensure that their change will be applied to the same version of the policy.Important: If you use IAM Conditions, you must include the etag field whenever you call setIamPolicy. If you omit this field, then IAM allows you to overwrite a version 3 policy with a version 1 policy, and all of the conditions in the version 3 policy are lost.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700662 }</pre>
663</div>
664
665<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700666 <code class="details" id="list">list(projectId, region, pageSize=None, pageToken=None, clusterName=None, jobStateMatcher=None, filter=None, x__xgafv=None)</code>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800667 <pre>Lists regions/{region}/jobs in a project.
668
669Args:
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400670 projectId: string, Required. The ID of the Google Cloud Platform project that the job belongs to. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700671 region: string, Required. The Dataproc region in which to handle the request. (required)
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700672 pageSize: integer, Optional. The number of results to return in each response.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700673 pageToken: string, Optional. The page token, returned by a previous call, to request the next page of results.
Bu Sun Kim65020912020-05-20 12:08:20 -0700674 clusterName: string, Optional. If set, the returned jobs list includes only jobs that were submitted to the named cluster.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700675 jobStateMatcher: string, Optional. Specifies enumerated categories of jobs to list. (default = match ALL jobs).If filter is provided, jobStateMatcher will be ignored.
676 Allowed values
677 ALL - Match all jobs, regardless of state.
678 ACTIVE - Only match jobs in non-terminal states: PENDING, RUNNING, or CANCEL_PENDING.
679 NON_ACTIVE - Only match jobs in terminal states: CANCELLED, DONE, or ERROR.
680 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 = *
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800681 x__xgafv: string, V1 error format.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400682 Allowed values
683 1 - v1 error format
684 2 - v2 error format
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800685
686Returns:
687 An object of the form:
688
689 { # A list of jobs in a project.
Bu Sun Kim65020912020-05-20 12:08:20 -0700690 &quot;jobs&quot;: [ # Output only. Jobs list.
Dan O'Mearadd494642020-05-01 07:42:23 -0700691 { # A Dataproc job resource.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700692 &quot;sparkRJob&quot;: { # A Dataproc job for running Apache SparkR (https://spark.apache.org/docs/latest/sparkr.html) applications on YARN. # Optional. Job is a SparkR job.
693 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700694 &quot;a_key&quot;: &quot;A String&quot;,
695 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700696 &quot;archiveUris&quot;: [ # 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.
697 &quot;A String&quot;,
698 ],
699 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
700 &quot;A String&quot;,
701 ],
702 &quot;args&quot;: [ # 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.
703 &quot;A String&quot;,
704 ],
705 &quot;mainRFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.
706 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
707 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700708 &quot;a_key&quot;: &quot;A String&quot;,
709 },
710 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700711 },
712 &quot;prestoJob&quot;: { # 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. # Optional. Job is a Presto job.
713 &quot;continueOnFailure&quot;: True or False, # 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.
714 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
715 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700716 &quot;a_key&quot;: &quot;A String&quot;,
717 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700718 },
719 &quot;clientTags&quot;: [ # Optional. Presto client tags to attach to this query
720 &quot;A String&quot;,
721 ],
722 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
723 &quot;properties&quot;: { # 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
724 &quot;a_key&quot;: &quot;A String&quot;,
725 },
726 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
727 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700728 &quot;A String&quot;,
729 ],
730 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700731 &quot;outputFormat&quot;: &quot;A String&quot;, # Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats
732 },
733 &quot;statusHistory&quot;: [ # Output only. The previous job status.
734 { # Dataproc job status.
735 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
736 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
737 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
738 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700739 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700740 ],
741 &quot;pigJob&quot;: { # A Dataproc job for running Apache Pig (https://pig.apache.org/) queries on YARN. # Optional. Job is a Pig job.
742 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).
743 &quot;a_key&quot;: &quot;A String&quot;,
744 },
745 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
746 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
747 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700748 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700749 },
750 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.
751 &quot;a_key&quot;: &quot;A String&quot;,
752 },
753 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
754 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700755 &quot;A String&quot;,
756 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700757 },
758 &quot;continueOnFailure&quot;: True or False, # 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.
759 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.
760 &quot;A String&quot;,
761 ],
762 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains the Pig queries.
763 },
764 &quot;status&quot;: { # Dataproc job status. # Output only. The job status. Additional application-specific status information may be contained in the type_job and yarn_applications fields.
765 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
766 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
767 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
768 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
769 },
770 &quot;jobUuid&quot;: &quot;A String&quot;, # 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 may be reused over time.
771 &quot;pysparkJob&quot;: { # A Dataproc job for running Apache PySpark (https://spark.apache.org/docs/0.9.0/python-programming-guide.html) applications on YARN. # Optional. Job is a PySpark job.
772 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
773 &quot;a_key&quot;: &quot;A String&quot;,
774 },
775 &quot;mainPythonFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.
776 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
777 &quot;A String&quot;,
778 ],
779 &quot;archiveUris&quot;: [ # 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.
780 &quot;A String&quot;,
781 ],
782 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.
783 &quot;A String&quot;,
784 ],
785 &quot;args&quot;: [ # 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.
786 &quot;A String&quot;,
787 ],
788 &quot;pythonFileUris&quot;: [ # Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.
789 &quot;A String&quot;,
790 ],
791 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
792 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700793 &quot;a_key&quot;: &quot;A String&quot;,
794 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700795 },
796 },
797 &quot;placement&quot;: { # Dataproc job config. # Required. Job information, including how, when, and where to run the job.
798 &quot;clusterName&quot;: &quot;A String&quot;, # Required. The name of the cluster where the job will be submitted.
799 &quot;clusterUuid&quot;: &quot;A String&quot;, # Output only. A cluster UUID generated by the Dataproc service when the job is submitted.
800 },
801 &quot;hadoopJob&quot;: { # A Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). # Optional. Job is a Hadoop job.
802 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.
803 &quot;a_key&quot;: &quot;A String&quot;,
804 },
805 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file containing the main class. Examples: &#x27;gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar&#x27; &#x27;hdfs:/tmp/test-samples/custom-wordcount.jar&#x27; &#x27;file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar&#x27;
806 &quot;args&quot;: [ # 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 may occur that causes an incorrect job submission.
807 &quot;A String&quot;,
808 ],
809 &quot;jarFileUris&quot;: [ # Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.
810 &quot;A String&quot;,
811 ],
812 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
813 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700814 &quot;a_key&quot;: &quot;A String&quot;,
815 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700816 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700817 &quot;archiveUris&quot;: [ # 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.
818 &quot;A String&quot;,
819 ],
820 &quot;fileUris&quot;: [ # 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.
821 &quot;A String&quot;,
822 ],
823 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.
824 },
825 &quot;sparkSqlJob&quot;: { # A Dataproc job for running Apache Spark SQL (http://spark.apache.org/sql/) queries. # Optional. Job is a SparkSql job.
826 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark SQL&#x27;s SparkConf. Properties that conflict with values set by the Dataproc API may be overwritten.
827 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700828 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700829 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
830 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
831 &quot;A String&quot;,
832 ],
833 },
834 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
835 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
836 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
837 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700838 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700839 },
840 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name=&quot;value&quot;;).
841 &quot;a_key&quot;: &quot;A String&quot;,
842 },
843 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.
844 &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700845 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700846 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700847 &quot;driverControlFilesUri&quot;: &quot;A String&quot;, # Output only. If present, the location of miscellaneous control files which may be used as part of job setup and handling. If not present, control files may be placed in the same location as driver_output_uri.
848 &quot;sparkJob&quot;: { # A Dataproc job for running Apache Spark (http://spark.apache.org/) applications on YARN. # Optional. Job is a Spark job.
849 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
850 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
851 &quot;a_key&quot;: &quot;A String&quot;,
852 },
853 },
854 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file that contains the main class.
855 &quot;args&quot;: [ # 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.
856 &quot;A String&quot;,
857 ],
858 &quot;archiveUris&quot;: [ # 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.
859 &quot;A String&quot;,
860 ],
861 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.
862 &quot;A String&quot;,
863 ],
864 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
865 &quot;a_key&quot;: &quot;A String&quot;,
866 },
867 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
868 &quot;A String&quot;,
869 ],
870 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file that contains the class must be in the default CLASSPATH or specified in jar_file_uris.
871 },
872 &quot;done&quot;: True or False, # 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.
873 &quot;scheduling&quot;: { # Job scheduling options. # Optional. Job scheduling configuration.
874 &quot;maxFailuresPerHour&quot;: 42, # Optional. Maximum number of times per hour a driver may be restarted as a result of driver exiting with non-zero code before job is reported failed.A job may be reported as thrashing if driver exits with non-zero code 4 times within 10 minute window.Maximum value is 10.
875 },
876 &quot;reference&quot;: { # Encapsulates the full scoping used to reference a job. # 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.
877 &quot;jobId&quot;: &quot;A String&quot;, # 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.
878 &quot;projectId&quot;: &quot;A String&quot;, # Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.
879 },
880 &quot;hiveJob&quot;: { # A Dataproc job for running Apache Hive (https://hive.apache.org/) queries on YARN. # Optional. Job is a Hive job.
881 &quot;continueOnFailure&quot;: True or False, # 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.
882 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains Hive queries.
883 &quot;properties&quot;: { # Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.
884 &quot;a_key&quot;: &quot;A String&quot;,
885 },
886 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name=&quot;value&quot;;).
887 &quot;a_key&quot;: &quot;A String&quot;,
888 },
889 &quot;jarFileUris&quot;: [ # 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.
890 &quot;A String&quot;,
891 ],
892 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
893 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
894 &quot;A String&quot;,
895 ],
896 },
897 },
898 &quot;driverOutputResourceUri&quot;: &quot;A String&quot;, # Output only. A URI pointing to the location of the stdout of the job&#x27;s driver program.
899 &quot;yarnApplications&quot;: [ # Output only. The collection of YARN applications spun up by this job.Beta Feature: This report is available for testing purposes only. It may be changed before final release.
900 { # 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.
901 &quot;name&quot;: &quot;A String&quot;, # Required. The application name.
902 &quot;state&quot;: &quot;A String&quot;, # Required. The application state.
903 &quot;trackingUrl&quot;: &quot;A String&quot;, # 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.
904 &quot;progress&quot;: 3.14, # Required. The numerical progress of the application, from 1 to 100.
905 },
906 ],
907 &quot;labels&quot;: { # Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). No more than 32 labels can be associated with a job.
908 &quot;a_key&quot;: &quot;A String&quot;,
909 },
910 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800911 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700912 &quot;nextPageToken&quot;: &quot;A String&quot;, # 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.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800913 }</pre>
914</div>
915
916<div class="method">
917 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
918 <pre>Retrieves the next page of results.
919
920Args:
921 previous_request: The request for the previous page. (required)
922 previous_response: The response from the request for the previous page. (required)
923
924Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -0700925 A request object that you can call &#x27;execute()&#x27; on to request the next
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800926 page. Returns None if there are no more items in the collection.
927 </pre>
928</div>
929
930<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700931 <code class="details" id="patch">patch(projectId, region, jobId, body=None, updateMask=None, x__xgafv=None)</code>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400932 <pre>Updates a job in a project.
933
934Args:
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400935 projectId: string, Required. The ID of the Google Cloud Platform project that the job belongs to. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700936 region: string, Required. The Dataproc region in which to handle the request. (required)
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400937 jobId: string, Required. The job ID. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700938 body: object, The request body.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400939 The object takes the form of:
940
Dan O'Mearadd494642020-05-01 07:42:23 -0700941{ # A Dataproc job resource.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700942 &quot;sparkRJob&quot;: { # A Dataproc job for running Apache SparkR (https://spark.apache.org/docs/latest/sparkr.html) applications on YARN. # Optional. Job is a SparkR job.
943 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700944 &quot;a_key&quot;: &quot;A String&quot;,
945 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700946 &quot;archiveUris&quot;: [ # 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.
947 &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700948 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700949 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
950 &quot;A String&quot;,
951 ],
952 &quot;args&quot;: [ # 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.
953 &quot;A String&quot;,
954 ],
955 &quot;mainRFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.
956 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
957 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
958 &quot;a_key&quot;: &quot;A String&quot;,
959 },
960 },
961 },
962 &quot;prestoJob&quot;: { # 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. # Optional. Job is a Presto job.
963 &quot;continueOnFailure&quot;: True or False, # 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.
964 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
965 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
966 &quot;a_key&quot;: &quot;A String&quot;,
967 },
968 },
969 &quot;clientTags&quot;: [ # Optional. Presto client tags to attach to this query
970 &quot;A String&quot;,
971 ],
972 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
973 &quot;properties&quot;: { # 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
974 &quot;a_key&quot;: &quot;A String&quot;,
975 },
976 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
977 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
978 &quot;A String&quot;,
979 ],
980 },
981 &quot;outputFormat&quot;: &quot;A String&quot;, # Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats
982 },
983 &quot;statusHistory&quot;: [ # Output only. The previous job status.
984 { # Dataproc job status.
985 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
986 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
987 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
988 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
989 },
990 ],
991 &quot;pigJob&quot;: { # A Dataproc job for running Apache Pig (https://pig.apache.org/) queries on YARN. # Optional. Job is a Pig job.
992 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).
993 &quot;a_key&quot;: &quot;A String&quot;,
994 },
995 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
996 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
997 &quot;a_key&quot;: &quot;A String&quot;,
998 },
999 },
1000 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.
1001 &quot;a_key&quot;: &quot;A String&quot;,
1002 },
1003 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1004 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1005 &quot;A String&quot;,
1006 ],
1007 },
1008 &quot;continueOnFailure&quot;: True or False, # 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.
1009 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.
1010 &quot;A String&quot;,
1011 ],
1012 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains the Pig queries.
1013 },
1014 &quot;status&quot;: { # Dataproc job status. # Output only. The job status. Additional application-specific status information may be contained in the type_job and yarn_applications fields.
1015 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
1016 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
1017 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
1018 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
1019 },
1020 &quot;jobUuid&quot;: &quot;A String&quot;, # 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 may be reused over time.
1021 &quot;pysparkJob&quot;: { # A Dataproc job for running Apache PySpark (https://spark.apache.org/docs/0.9.0/python-programming-guide.html) applications on YARN. # Optional. Job is a PySpark job.
1022 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
1023 &quot;a_key&quot;: &quot;A String&quot;,
1024 },
1025 &quot;mainPythonFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.
1026 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1027 &quot;A String&quot;,
1028 ],
1029 &quot;archiveUris&quot;: [ # 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.
1030 &quot;A String&quot;,
1031 ],
1032 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.
1033 &quot;A String&quot;,
1034 ],
1035 &quot;args&quot;: [ # 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.
1036 &quot;A String&quot;,
1037 ],
1038 &quot;pythonFileUris&quot;: [ # Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.
1039 &quot;A String&quot;,
1040 ],
1041 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1042 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1043 &quot;a_key&quot;: &quot;A String&quot;,
1044 },
1045 },
1046 },
1047 &quot;placement&quot;: { # Dataproc job config. # Required. Job information, including how, when, and where to run the job.
1048 &quot;clusterName&quot;: &quot;A String&quot;, # Required. The name of the cluster where the job will be submitted.
1049 &quot;clusterUuid&quot;: &quot;A String&quot;, # Output only. A cluster UUID generated by the Dataproc service when the job is submitted.
1050 },
1051 &quot;hadoopJob&quot;: { # A Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). # Optional. Job is a Hadoop job.
1052 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.
1053 &quot;a_key&quot;: &quot;A String&quot;,
1054 },
1055 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file containing the main class. Examples: &#x27;gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar&#x27; &#x27;hdfs:/tmp/test-samples/custom-wordcount.jar&#x27; &#x27;file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar&#x27;
1056 &quot;args&quot;: [ # 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 may occur that causes an incorrect job submission.
1057 &quot;A String&quot;,
1058 ],
1059 &quot;jarFileUris&quot;: [ # Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.
1060 &quot;A String&quot;,
1061 ],
1062 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1063 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1064 &quot;a_key&quot;: &quot;A String&quot;,
1065 },
1066 },
1067 &quot;archiveUris&quot;: [ # 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.
1068 &quot;A String&quot;,
1069 ],
1070 &quot;fileUris&quot;: [ # 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.
1071 &quot;A String&quot;,
1072 ],
1073 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.
1074 },
1075 &quot;sparkSqlJob&quot;: { # A Dataproc job for running Apache Spark SQL (http://spark.apache.org/sql/) queries. # Optional. Job is a SparkSql job.
1076 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark SQL&#x27;s SparkConf. Properties that conflict with values set by the Dataproc API may be overwritten.
1077 &quot;a_key&quot;: &quot;A String&quot;,
1078 },
1079 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1080 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1081 &quot;A String&quot;,
1082 ],
1083 },
1084 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
1085 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1086 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1087 &quot;a_key&quot;: &quot;A String&quot;,
1088 },
1089 },
1090 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name=&quot;value&quot;;).
1091 &quot;a_key&quot;: &quot;A String&quot;,
1092 },
1093 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.
1094 &quot;A String&quot;,
1095 ],
1096 },
1097 &quot;driverControlFilesUri&quot;: &quot;A String&quot;, # Output only. If present, the location of miscellaneous control files which may be used as part of job setup and handling. If not present, control files may be placed in the same location as driver_output_uri.
1098 &quot;sparkJob&quot;: { # A Dataproc job for running Apache Spark (http://spark.apache.org/) applications on YARN. # Optional. Job is a Spark job.
1099 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1100 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1101 &quot;a_key&quot;: &quot;A String&quot;,
1102 },
1103 },
1104 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file that contains the main class.
1105 &quot;args&quot;: [ # 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.
1106 &quot;A String&quot;,
1107 ],
1108 &quot;archiveUris&quot;: [ # 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.
1109 &quot;A String&quot;,
1110 ],
1111 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.
1112 &quot;A String&quot;,
1113 ],
1114 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
1115 &quot;a_key&quot;: &quot;A String&quot;,
1116 },
1117 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1118 &quot;A String&quot;,
1119 ],
1120 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file that contains the class must be in the default CLASSPATH or specified in jar_file_uris.
1121 },
1122 &quot;done&quot;: True or False, # 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.
1123 &quot;scheduling&quot;: { # Job scheduling options. # Optional. Job scheduling configuration.
1124 &quot;maxFailuresPerHour&quot;: 42, # Optional. Maximum number of times per hour a driver may be restarted as a result of driver exiting with non-zero code before job is reported failed.A job may be reported as thrashing if driver exits with non-zero code 4 times within 10 minute window.Maximum value is 10.
1125 },
1126 &quot;reference&quot;: { # Encapsulates the full scoping used to reference a job. # 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.
1127 &quot;jobId&quot;: &quot;A String&quot;, # 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.
1128 &quot;projectId&quot;: &quot;A String&quot;, # Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.
1129 },
1130 &quot;hiveJob&quot;: { # A Dataproc job for running Apache Hive (https://hive.apache.org/) queries on YARN. # Optional. Job is a Hive job.
1131 &quot;continueOnFailure&quot;: True or False, # 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.
1132 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains Hive queries.
1133 &quot;properties&quot;: { # Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.
1134 &quot;a_key&quot;: &quot;A String&quot;,
1135 },
1136 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name=&quot;value&quot;;).
1137 &quot;a_key&quot;: &quot;A String&quot;,
1138 },
1139 &quot;jarFileUris&quot;: [ # 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.
1140 &quot;A String&quot;,
1141 ],
1142 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1143 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1144 &quot;A String&quot;,
1145 ],
1146 },
1147 },
1148 &quot;driverOutputResourceUri&quot;: &quot;A String&quot;, # Output only. A URI pointing to the location of the stdout of the job&#x27;s driver program.
1149 &quot;yarnApplications&quot;: [ # Output only. The collection of YARN applications spun up by this job.Beta Feature: This report is available for testing purposes only. It may be changed before final release.
1150 { # 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.
1151 &quot;name&quot;: &quot;A String&quot;, # Required. The application name.
1152 &quot;state&quot;: &quot;A String&quot;, # Required. The application state.
1153 &quot;trackingUrl&quot;: &quot;A String&quot;, # 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.
1154 &quot;progress&quot;: 3.14, # Required. The numerical progress of the application, from 1 to 100.
1155 },
1156 ],
1157 &quot;labels&quot;: { # Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). No more than 32 labels can be associated with a job.
1158 &quot;a_key&quot;: &quot;A String&quot;,
1159 },
1160}
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001161
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001162 updateMask: string, 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.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001163 x__xgafv: string, V1 error format.
1164 Allowed values
1165 1 - v1 error format
1166 2 - v2 error format
1167
1168Returns:
1169 An object of the form:
1170
Dan O'Mearadd494642020-05-01 07:42:23 -07001171 { # A Dataproc job resource.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001172 &quot;sparkRJob&quot;: { # A Dataproc job for running Apache SparkR (https://spark.apache.org/docs/latest/sparkr.html) applications on YARN. # Optional. Job is a SparkR job.
1173 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001174 &quot;a_key&quot;: &quot;A String&quot;,
1175 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001176 &quot;archiveUris&quot;: [ # 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.
1177 &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001178 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001179 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1180 &quot;A String&quot;,
1181 ],
1182 &quot;args&quot;: [ # 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.
1183 &quot;A String&quot;,
1184 ],
1185 &quot;mainRFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.
1186 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1187 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1188 &quot;a_key&quot;: &quot;A String&quot;,
1189 },
1190 },
1191 },
1192 &quot;prestoJob&quot;: { # 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. # Optional. Job is a Presto job.
1193 &quot;continueOnFailure&quot;: True or False, # 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.
1194 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1195 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1196 &quot;a_key&quot;: &quot;A String&quot;,
1197 },
1198 },
1199 &quot;clientTags&quot;: [ # Optional. Presto client tags to attach to this query
1200 &quot;A String&quot;,
1201 ],
1202 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
1203 &quot;properties&quot;: { # 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
1204 &quot;a_key&quot;: &quot;A String&quot;,
1205 },
1206 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1207 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1208 &quot;A String&quot;,
1209 ],
1210 },
1211 &quot;outputFormat&quot;: &quot;A String&quot;, # Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats
1212 },
1213 &quot;statusHistory&quot;: [ # Output only. The previous job status.
1214 { # Dataproc job status.
1215 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
1216 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
1217 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
1218 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
1219 },
1220 ],
1221 &quot;pigJob&quot;: { # A Dataproc job for running Apache Pig (https://pig.apache.org/) queries on YARN. # Optional. Job is a Pig job.
1222 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).
1223 &quot;a_key&quot;: &quot;A String&quot;,
1224 },
1225 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1226 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1227 &quot;a_key&quot;: &quot;A String&quot;,
1228 },
1229 },
1230 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.
1231 &quot;a_key&quot;: &quot;A String&quot;,
1232 },
1233 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1234 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1235 &quot;A String&quot;,
1236 ],
1237 },
1238 &quot;continueOnFailure&quot;: True or False, # 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.
1239 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.
1240 &quot;A String&quot;,
1241 ],
1242 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains the Pig queries.
1243 },
1244 &quot;status&quot;: { # Dataproc job status. # Output only. The job status. Additional application-specific status information may be contained in the type_job and yarn_applications fields.
1245 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
1246 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
1247 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
1248 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
1249 },
1250 &quot;jobUuid&quot;: &quot;A String&quot;, # 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 may be reused over time.
1251 &quot;pysparkJob&quot;: { # A Dataproc job for running Apache PySpark (https://spark.apache.org/docs/0.9.0/python-programming-guide.html) applications on YARN. # Optional. Job is a PySpark job.
1252 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
1253 &quot;a_key&quot;: &quot;A String&quot;,
1254 },
1255 &quot;mainPythonFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.
1256 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1257 &quot;A String&quot;,
1258 ],
1259 &quot;archiveUris&quot;: [ # 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.
1260 &quot;A String&quot;,
1261 ],
1262 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.
1263 &quot;A String&quot;,
1264 ],
1265 &quot;args&quot;: [ # 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.
1266 &quot;A String&quot;,
1267 ],
1268 &quot;pythonFileUris&quot;: [ # Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.
1269 &quot;A String&quot;,
1270 ],
1271 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1272 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1273 &quot;a_key&quot;: &quot;A String&quot;,
1274 },
1275 },
1276 },
1277 &quot;placement&quot;: { # Dataproc job config. # Required. Job information, including how, when, and where to run the job.
1278 &quot;clusterName&quot;: &quot;A String&quot;, # Required. The name of the cluster where the job will be submitted.
1279 &quot;clusterUuid&quot;: &quot;A String&quot;, # Output only. A cluster UUID generated by the Dataproc service when the job is submitted.
1280 },
1281 &quot;hadoopJob&quot;: { # A Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). # Optional. Job is a Hadoop job.
1282 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.
1283 &quot;a_key&quot;: &quot;A String&quot;,
1284 },
1285 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file containing the main class. Examples: &#x27;gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar&#x27; &#x27;hdfs:/tmp/test-samples/custom-wordcount.jar&#x27; &#x27;file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar&#x27;
1286 &quot;args&quot;: [ # 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 may occur that causes an incorrect job submission.
1287 &quot;A String&quot;,
1288 ],
1289 &quot;jarFileUris&quot;: [ # Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.
1290 &quot;A String&quot;,
1291 ],
1292 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1293 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1294 &quot;a_key&quot;: &quot;A String&quot;,
1295 },
1296 },
1297 &quot;archiveUris&quot;: [ # 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.
1298 &quot;A String&quot;,
1299 ],
1300 &quot;fileUris&quot;: [ # 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.
1301 &quot;A String&quot;,
1302 ],
1303 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.
1304 },
1305 &quot;sparkSqlJob&quot;: { # A Dataproc job for running Apache Spark SQL (http://spark.apache.org/sql/) queries. # Optional. Job is a SparkSql job.
1306 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark SQL&#x27;s SparkConf. Properties that conflict with values set by the Dataproc API may be overwritten.
1307 &quot;a_key&quot;: &quot;A String&quot;,
1308 },
1309 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1310 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1311 &quot;A String&quot;,
1312 ],
1313 },
1314 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
1315 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1316 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1317 &quot;a_key&quot;: &quot;A String&quot;,
1318 },
1319 },
1320 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name=&quot;value&quot;;).
1321 &quot;a_key&quot;: &quot;A String&quot;,
1322 },
1323 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.
1324 &quot;A String&quot;,
1325 ],
1326 },
1327 &quot;driverControlFilesUri&quot;: &quot;A String&quot;, # Output only. If present, the location of miscellaneous control files which may be used as part of job setup and handling. If not present, control files may be placed in the same location as driver_output_uri.
1328 &quot;sparkJob&quot;: { # A Dataproc job for running Apache Spark (http://spark.apache.org/) applications on YARN. # Optional. Job is a Spark job.
1329 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1330 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1331 &quot;a_key&quot;: &quot;A String&quot;,
1332 },
1333 },
1334 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file that contains the main class.
1335 &quot;args&quot;: [ # 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.
1336 &quot;A String&quot;,
1337 ],
1338 &quot;archiveUris&quot;: [ # 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.
1339 &quot;A String&quot;,
1340 ],
1341 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.
1342 &quot;A String&quot;,
1343 ],
1344 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
1345 &quot;a_key&quot;: &quot;A String&quot;,
1346 },
1347 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1348 &quot;A String&quot;,
1349 ],
1350 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file that contains the class must be in the default CLASSPATH or specified in jar_file_uris.
1351 },
1352 &quot;done&quot;: True or False, # 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.
1353 &quot;scheduling&quot;: { # Job scheduling options. # Optional. Job scheduling configuration.
1354 &quot;maxFailuresPerHour&quot;: 42, # Optional. Maximum number of times per hour a driver may be restarted as a result of driver exiting with non-zero code before job is reported failed.A job may be reported as thrashing if driver exits with non-zero code 4 times within 10 minute window.Maximum value is 10.
1355 },
1356 &quot;reference&quot;: { # Encapsulates the full scoping used to reference a job. # 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.
1357 &quot;jobId&quot;: &quot;A String&quot;, # 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.
1358 &quot;projectId&quot;: &quot;A String&quot;, # Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.
1359 },
1360 &quot;hiveJob&quot;: { # A Dataproc job for running Apache Hive (https://hive.apache.org/) queries on YARN. # Optional. Job is a Hive job.
1361 &quot;continueOnFailure&quot;: True or False, # 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.
1362 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains Hive queries.
1363 &quot;properties&quot;: { # Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.
1364 &quot;a_key&quot;: &quot;A String&quot;,
1365 },
1366 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name=&quot;value&quot;;).
1367 &quot;a_key&quot;: &quot;A String&quot;,
1368 },
1369 &quot;jarFileUris&quot;: [ # 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.
1370 &quot;A String&quot;,
1371 ],
1372 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1373 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1374 &quot;A String&quot;,
1375 ],
1376 },
1377 },
1378 &quot;driverOutputResourceUri&quot;: &quot;A String&quot;, # Output only. A URI pointing to the location of the stdout of the job&#x27;s driver program.
1379 &quot;yarnApplications&quot;: [ # Output only. The collection of YARN applications spun up by this job.Beta Feature: This report is available for testing purposes only. It may be changed before final release.
1380 { # 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.
1381 &quot;name&quot;: &quot;A String&quot;, # Required. The application name.
1382 &quot;state&quot;: &quot;A String&quot;, # Required. The application state.
1383 &quot;trackingUrl&quot;: &quot;A String&quot;, # 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.
1384 &quot;progress&quot;: 3.14, # Required. The numerical progress of the application, from 1 to 100.
1385 },
1386 ],
1387 &quot;labels&quot;: { # Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). No more than 32 labels can be associated with a job.
1388 &quot;a_key&quot;: &quot;A String&quot;,
1389 },
1390 }</pre>
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001391</div>
1392
1393<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07001394 <code class="details" id="setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</code>
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001395 <pre>Sets the access control policy on the specified resource. Replaces any existing policy.Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001396
1397Args:
1398 resource: string, REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07001399 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001400 The object takes the form of:
1401
1402{ # Request message for SetIamPolicy method.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001403 &quot;policy&quot;: { # An Identity and Access Management (IAM) policy, which specifies access controls for Google Cloud resources.A Policy is a collection of bindings. A binding binds one or more members to a single role. Members can be user accounts, service accounts, Google groups, and domains (such as G Suite). A role is a named list of permissions; each role can be an IAM predefined role or a user-created custom role.For some types of Google Cloud resources, a binding can also specify a condition, which is a logical expression that allows access to a resource only if the expression evaluates to true. A condition can add constraints based on attributes of the request, the resource, or both. To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).JSON example: { &quot;bindings&quot;: [ { &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;, &quot;members&quot;: [ &quot;user:mike@example.com&quot;, &quot;group:admins@example.com&quot;, &quot;domain:google.com&quot;, &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot; ] }, { &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;, &quot;members&quot;: [ &quot;user:eve@example.com&quot; ], &quot;condition&quot;: { &quot;title&quot;: &quot;expirable access&quot;, &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;, &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;, } } ], &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;, &quot;version&quot;: 3 } YAML example: bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/resourcemanager.organizationAdmin - members: - user:eve@example.com role: roles/resourcemanager.organizationViewer condition: title: expirable access description: Does not grant access after Sep 2020 expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;) - etag: BwWWja0YfJA= - version: 3 For a description of IAM and its features, see the IAM documentation (https://cloud.google.com/iam/docs/). # REQUIRED: The complete policy to be applied to the resource. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud Platform services (such as Projects) might reject them.
Bu Sun Kim65020912020-05-20 12:08:20 -07001404 &quot;bindings&quot;: [ # Associates a list of members to a role. Optionally, may specify a condition that determines how and when the bindings are applied. Each of the bindings must contain at least one member.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001405 { # Associates members with a role.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001406 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to members. For example, roles/viewer, roles/editor, or roles/owner.
1407 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec.Example (Comparison): title: &quot;Summary size limit&quot; description: &quot;Determines if a summary is less than 100 chars&quot; expression: &quot;document.summary.size() &lt; 100&quot; Example (Equality): title: &quot;Requestor is owner&quot; description: &quot;Determines if requestor is the document owner&quot; expression: &quot;document.owner == request.auth.claims.email&quot; Example (Logic): title: &quot;Public documents&quot; description: &quot;Determine whether the document should be publicly visible&quot; expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot; Example (Data Manipulation): title: &quot;Notification string&quot; description: &quot;Create a notification string with a timestamp.&quot; expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot; The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information. # The condition that is associated with this binding.If the condition evaluates to true, then this binding applies to the current request.If the condition evaluates to false, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the members in this binding.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).
Bu Sun Kim65020912020-05-20 12:08:20 -07001408 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language syntax.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001409 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
1410 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
1411 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
Bu Sun Kim65020912020-05-20 12:08:20 -07001412 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001413 &quot;bindingId&quot;: &quot;A String&quot;, # A client-specified ID for this binding. Expected to be globally unique to support the internal bindings-by-ID API.
1414 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource. members can have the following values: allUsers: A special identifier that represents anyone who is on the internet; with or without a Google account. allAuthenticatedUsers: A special identifier that represents anyone who is authenticated with a Google account or a service account. user:{emailid}: An email address that represents a specific Google account. For example, alice@example.com . serviceAccount:{emailid}: An email address that represents a service account. For example, my-other-app@appspot.gserviceaccount.com. group:{emailid}: An email address that represents a Google group. For example, admins@example.com. deleted:user:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a user that has been recently deleted. For example, alice@example.com?uid=123456789012345678901. If the user is recovered, this value reverts to user:{emailid} and the recovered user retains the role in the binding. deleted:serviceAccount:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901. If the service account is undeleted, this value reverts to serviceAccount:{emailid} and the undeleted service account retains the role in the binding. deleted:group:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, admins@example.com?uid=123456789012345678901. If the group is recovered, this value reverts to group:{emailid} and the recovered group retains the role in the binding. domain:{domain}: The G Suite domain (primary) that represents all the users of that domain. For example, google.com or example.com.
Bu Sun Kim65020912020-05-20 12:08:20 -07001415 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001416 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001417 },
1418 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001419 &quot;version&quot;: 42, # Specifies the format of the policy.Valid values are 0, 1, and 3. Requests that specify an invalid value are rejected.Any operation that affects conditional role bindings must specify version 3. This requirement applies to the following operations: Getting a policy that includes a conditional role binding Adding a conditional role binding to a policy Changing a conditional role binding in a policy Removing any role binding, with or without a condition, from a policy that includes conditionsImportant: If you use IAM Conditions, you must include the etag field whenever you call setIamPolicy. If you omit this field, then IAM allows you to overwrite a version 3 policy with a version 1 policy, and all of the conditions in the version 3 policy are lost.If a policy does not include any conditions, operations on that policy may specify any valid version or leave the field unset.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).
1420 &quot;etag&quot;: &quot;A String&quot;, # etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An etag is returned in the response to getIamPolicy, and systems are expected to put that etag in the request to setIamPolicy to ensure that their change will be applied to the same version of the policy.Important: If you use IAM Conditions, you must include the etag field whenever you call setIamPolicy. If you omit this field, then IAM allows you to overwrite a version 3 policy with a version 1 policy, and all of the conditions in the version 3 policy are lost.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001421 },
1422 }
1423
1424 x__xgafv: string, V1 error format.
1425 Allowed values
1426 1 - v1 error format
1427 2 - v2 error format
1428
1429Returns:
1430 An object of the form:
1431
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001432 { # An Identity and Access Management (IAM) policy, which specifies access controls for Google Cloud resources.A Policy is a collection of bindings. A binding binds one or more members to a single role. Members can be user accounts, service accounts, Google groups, and domains (such as G Suite). A role is a named list of permissions; each role can be an IAM predefined role or a user-created custom role.For some types of Google Cloud resources, a binding can also specify a condition, which is a logical expression that allows access to a resource only if the expression evaluates to true. A condition can add constraints based on attributes of the request, the resource, or both. To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).JSON example: { &quot;bindings&quot;: [ { &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;, &quot;members&quot;: [ &quot;user:mike@example.com&quot;, &quot;group:admins@example.com&quot;, &quot;domain:google.com&quot;, &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot; ] }, { &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;, &quot;members&quot;: [ &quot;user:eve@example.com&quot; ], &quot;condition&quot;: { &quot;title&quot;: &quot;expirable access&quot;, &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;, &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;, } } ], &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;, &quot;version&quot;: 3 } YAML example: bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/resourcemanager.organizationAdmin - members: - user:eve@example.com role: roles/resourcemanager.organizationViewer condition: title: expirable access description: Does not grant access after Sep 2020 expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;) - etag: BwWWja0YfJA= - version: 3 For a description of IAM and its features, see the IAM documentation (https://cloud.google.com/iam/docs/).
Bu Sun Kim65020912020-05-20 12:08:20 -07001433 &quot;bindings&quot;: [ # Associates a list of members to a role. Optionally, may specify a condition that determines how and when the bindings are applied. Each of the bindings must contain at least one member.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001434 { # Associates members with a role.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001435 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to members. For example, roles/viewer, roles/editor, or roles/owner.
1436 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec.Example (Comparison): title: &quot;Summary size limit&quot; description: &quot;Determines if a summary is less than 100 chars&quot; expression: &quot;document.summary.size() &lt; 100&quot; Example (Equality): title: &quot;Requestor is owner&quot; description: &quot;Determines if requestor is the document owner&quot; expression: &quot;document.owner == request.auth.claims.email&quot; Example (Logic): title: &quot;Public documents&quot; description: &quot;Determine whether the document should be publicly visible&quot; expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot; Example (Data Manipulation): title: &quot;Notification string&quot; description: &quot;Create a notification string with a timestamp.&quot; expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot; The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information. # The condition that is associated with this binding.If the condition evaluates to true, then this binding applies to the current request.If the condition evaluates to false, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the members in this binding.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).
Bu Sun Kim65020912020-05-20 12:08:20 -07001437 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language syntax.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001438 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
1439 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
1440 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
Bu Sun Kim65020912020-05-20 12:08:20 -07001441 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001442 &quot;bindingId&quot;: &quot;A String&quot;, # A client-specified ID for this binding. Expected to be globally unique to support the internal bindings-by-ID API.
1443 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource. members can have the following values: allUsers: A special identifier that represents anyone who is on the internet; with or without a Google account. allAuthenticatedUsers: A special identifier that represents anyone who is authenticated with a Google account or a service account. user:{emailid}: An email address that represents a specific Google account. For example, alice@example.com . serviceAccount:{emailid}: An email address that represents a service account. For example, my-other-app@appspot.gserviceaccount.com. group:{emailid}: An email address that represents a Google group. For example, admins@example.com. deleted:user:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a user that has been recently deleted. For example, alice@example.com?uid=123456789012345678901. If the user is recovered, this value reverts to user:{emailid} and the recovered user retains the role in the binding. deleted:serviceAccount:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901. If the service account is undeleted, this value reverts to serviceAccount:{emailid} and the undeleted service account retains the role in the binding. deleted:group:{emailid}?uid={uniqueid}: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, admins@example.com?uid=123456789012345678901. If the group is recovered, this value reverts to group:{emailid} and the recovered group retains the role in the binding. domain:{domain}: The G Suite domain (primary) that represents all the users of that domain. For example, google.com or example.com.
Bu Sun Kim65020912020-05-20 12:08:20 -07001444 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001445 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001446 },
1447 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001448 &quot;version&quot;: 42, # Specifies the format of the policy.Valid values are 0, 1, and 3. Requests that specify an invalid value are rejected.Any operation that affects conditional role bindings must specify version 3. This requirement applies to the following operations: Getting a policy that includes a conditional role binding Adding a conditional role binding to a policy Changing a conditional role binding in a policy Removing any role binding, with or without a condition, from a policy that includes conditionsImportant: If you use IAM Conditions, you must include the etag field whenever you call setIamPolicy. If you omit this field, then IAM allows you to overwrite a version 3 policy with a version 1 policy, and all of the conditions in the version 3 policy are lost.If a policy does not include any conditions, operations on that policy may specify any valid version or leave the field unset.To learn which resources support conditions in their IAM policies, see the IAM documentation (https://cloud.google.com/iam/help/conditions/resource-policies).
1449 &quot;etag&quot;: &quot;A String&quot;, # etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An etag is returned in the response to getIamPolicy, and systems are expected to put that etag in the request to setIamPolicy to ensure that their change will be applied to the same version of the policy.Important: If you use IAM Conditions, you must include the etag field whenever you call setIamPolicy. If you omit this field, then IAM allows you to overwrite a version 3 policy with a version 1 policy, and all of the conditions in the version 3 policy are lost.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001450 }</pre>
1451</div>
1452
1453<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07001454 <code class="details" id="submit">submit(projectId, region, body=None, x__xgafv=None)</code>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001455 <pre>Submits a job to a cluster.
1456
1457Args:
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04001458 projectId: string, Required. The ID of the Google Cloud Platform project that the job belongs to. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07001459 region: string, Required. The Dataproc region in which to handle the request. (required)
1460 body: object, The request body.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001461 The object takes the form of:
1462
1463{ # A request to submit a job.
Bu Sun Kim65020912020-05-20 12:08:20 -07001464 &quot;job&quot;: { # A Dataproc job resource. # Required. The job resource.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001465 &quot;sparkRJob&quot;: { # A Dataproc job for running Apache SparkR (https://spark.apache.org/docs/latest/sparkr.html) applications on YARN. # Optional. Job is a SparkR job.
1466 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001467 &quot;a_key&quot;: &quot;A String&quot;,
1468 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001469 &quot;archiveUris&quot;: [ # 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.
1470 &quot;A String&quot;,
1471 ],
1472 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1473 &quot;A String&quot;,
1474 ],
1475 &quot;args&quot;: [ # 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.
1476 &quot;A String&quot;,
1477 ],
1478 &quot;mainRFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.
1479 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1480 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001481 &quot;a_key&quot;: &quot;A String&quot;,
1482 },
1483 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001484 },
1485 &quot;prestoJob&quot;: { # 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. # Optional. Job is a Presto job.
1486 &quot;continueOnFailure&quot;: True or False, # 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.
1487 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1488 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001489 &quot;a_key&quot;: &quot;A String&quot;,
1490 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001491 },
1492 &quot;clientTags&quot;: [ # Optional. Presto client tags to attach to this query
1493 &quot;A String&quot;,
1494 ],
1495 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
1496 &quot;properties&quot;: { # 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
1497 &quot;a_key&quot;: &quot;A String&quot;,
1498 },
1499 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1500 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001501 &quot;A String&quot;,
1502 ],
1503 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001504 &quot;outputFormat&quot;: &quot;A String&quot;, # Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats
1505 },
1506 &quot;statusHistory&quot;: [ # Output only. The previous job status.
1507 { # Dataproc job status.
1508 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
1509 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
1510 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
1511 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001512 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001513 ],
1514 &quot;pigJob&quot;: { # A Dataproc job for running Apache Pig (https://pig.apache.org/) queries on YARN. # Optional. Job is a Pig job.
1515 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).
1516 &quot;a_key&quot;: &quot;A String&quot;,
1517 },
1518 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1519 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1520 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001521 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001522 },
1523 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.
1524 &quot;a_key&quot;: &quot;A String&quot;,
1525 },
1526 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1527 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001528 &quot;A String&quot;,
1529 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001530 },
1531 &quot;continueOnFailure&quot;: True or False, # 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.
1532 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.
1533 &quot;A String&quot;,
1534 ],
1535 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains the Pig queries.
1536 },
1537 &quot;status&quot;: { # Dataproc job status. # Output only. The job status. Additional application-specific status information may be contained in the type_job and yarn_applications fields.
1538 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
1539 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
1540 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
1541 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
1542 },
1543 &quot;jobUuid&quot;: &quot;A String&quot;, # 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 may be reused over time.
1544 &quot;pysparkJob&quot;: { # A Dataproc job for running Apache PySpark (https://spark.apache.org/docs/0.9.0/python-programming-guide.html) applications on YARN. # Optional. Job is a PySpark job.
1545 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
1546 &quot;a_key&quot;: &quot;A String&quot;,
1547 },
1548 &quot;mainPythonFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.
1549 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1550 &quot;A String&quot;,
1551 ],
1552 &quot;archiveUris&quot;: [ # 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.
1553 &quot;A String&quot;,
1554 ],
1555 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.
1556 &quot;A String&quot;,
1557 ],
1558 &quot;args&quot;: [ # 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.
1559 &quot;A String&quot;,
1560 ],
1561 &quot;pythonFileUris&quot;: [ # Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.
1562 &quot;A String&quot;,
1563 ],
1564 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1565 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001566 &quot;a_key&quot;: &quot;A String&quot;,
1567 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001568 },
1569 },
1570 &quot;placement&quot;: { # Dataproc job config. # Required. Job information, including how, when, and where to run the job.
1571 &quot;clusterName&quot;: &quot;A String&quot;, # Required. The name of the cluster where the job will be submitted.
1572 &quot;clusterUuid&quot;: &quot;A String&quot;, # Output only. A cluster UUID generated by the Dataproc service when the job is submitted.
1573 },
1574 &quot;hadoopJob&quot;: { # A Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). # Optional. Job is a Hadoop job.
1575 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.
1576 &quot;a_key&quot;: &quot;A String&quot;,
1577 },
1578 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file containing the main class. Examples: &#x27;gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar&#x27; &#x27;hdfs:/tmp/test-samples/custom-wordcount.jar&#x27; &#x27;file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar&#x27;
1579 &quot;args&quot;: [ # 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 may occur that causes an incorrect job submission.
1580 &quot;A String&quot;,
1581 ],
1582 &quot;jarFileUris&quot;: [ # Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.
1583 &quot;A String&quot;,
1584 ],
1585 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1586 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001587 &quot;a_key&quot;: &quot;A String&quot;,
1588 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001589 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001590 &quot;archiveUris&quot;: [ # 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.
1591 &quot;A String&quot;,
1592 ],
1593 &quot;fileUris&quot;: [ # 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.
1594 &quot;A String&quot;,
1595 ],
1596 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.
1597 },
1598 &quot;sparkSqlJob&quot;: { # A Dataproc job for running Apache Spark SQL (http://spark.apache.org/sql/) queries. # Optional. Job is a SparkSql job.
1599 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark SQL&#x27;s SparkConf. Properties that conflict with values set by the Dataproc API may be overwritten.
1600 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001601 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001602 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1603 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1604 &quot;A String&quot;,
1605 ],
1606 },
1607 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
1608 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1609 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1610 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001611 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001612 },
1613 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name=&quot;value&quot;;).
1614 &quot;a_key&quot;: &quot;A String&quot;,
1615 },
1616 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.
1617 &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001618 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001619 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001620 &quot;driverControlFilesUri&quot;: &quot;A String&quot;, # Output only. If present, the location of miscellaneous control files which may be used as part of job setup and handling. If not present, control files may be placed in the same location as driver_output_uri.
1621 &quot;sparkJob&quot;: { # A Dataproc job for running Apache Spark (http://spark.apache.org/) applications on YARN. # Optional. Job is a Spark job.
1622 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1623 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1624 &quot;a_key&quot;: &quot;A String&quot;,
1625 },
1626 },
1627 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file that contains the main class.
1628 &quot;args&quot;: [ # 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.
1629 &quot;A String&quot;,
1630 ],
1631 &quot;archiveUris&quot;: [ # 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.
1632 &quot;A String&quot;,
1633 ],
1634 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.
1635 &quot;A String&quot;,
1636 ],
1637 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
1638 &quot;a_key&quot;: &quot;A String&quot;,
1639 },
1640 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1641 &quot;A String&quot;,
1642 ],
1643 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file that contains the class must be in the default CLASSPATH or specified in jar_file_uris.
1644 },
1645 &quot;done&quot;: True or False, # 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.
1646 &quot;scheduling&quot;: { # Job scheduling options. # Optional. Job scheduling configuration.
1647 &quot;maxFailuresPerHour&quot;: 42, # Optional. Maximum number of times per hour a driver may be restarted as a result of driver exiting with non-zero code before job is reported failed.A job may be reported as thrashing if driver exits with non-zero code 4 times within 10 minute window.Maximum value is 10.
1648 },
1649 &quot;reference&quot;: { # Encapsulates the full scoping used to reference a job. # 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.
1650 &quot;jobId&quot;: &quot;A String&quot;, # 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.
1651 &quot;projectId&quot;: &quot;A String&quot;, # Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.
1652 },
1653 &quot;hiveJob&quot;: { # A Dataproc job for running Apache Hive (https://hive.apache.org/) queries on YARN. # Optional. Job is a Hive job.
1654 &quot;continueOnFailure&quot;: True or False, # 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.
1655 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains Hive queries.
1656 &quot;properties&quot;: { # Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.
1657 &quot;a_key&quot;: &quot;A String&quot;,
1658 },
1659 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name=&quot;value&quot;;).
1660 &quot;a_key&quot;: &quot;A String&quot;,
1661 },
1662 &quot;jarFileUris&quot;: [ # 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.
1663 &quot;A String&quot;,
1664 ],
1665 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1666 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1667 &quot;A String&quot;,
1668 ],
1669 },
1670 },
1671 &quot;driverOutputResourceUri&quot;: &quot;A String&quot;, # Output only. A URI pointing to the location of the stdout of the job&#x27;s driver program.
1672 &quot;yarnApplications&quot;: [ # Output only. The collection of YARN applications spun up by this job.Beta Feature: This report is available for testing purposes only. It may be changed before final release.
1673 { # 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.
1674 &quot;name&quot;: &quot;A String&quot;, # Required. The application name.
1675 &quot;state&quot;: &quot;A String&quot;, # Required. The application state.
1676 &quot;trackingUrl&quot;: &quot;A String&quot;, # 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.
1677 &quot;progress&quot;: 3.14, # Required. The numerical progress of the application, from 1 to 100.
1678 },
1679 ],
1680 &quot;labels&quot;: { # Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). No more than 32 labels can be associated with a job.
1681 &quot;a_key&quot;: &quot;A String&quot;,
1682 },
1683 },
1684 &quot;requestId&quot;: &quot;A String&quot;, # Optional. A unique id used to identify the request. If the server receives two SubmitJobRequest requests 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 (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.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001685 }
1686
1687 x__xgafv: string, V1 error format.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -04001688 Allowed values
1689 1 - v1 error format
1690 2 - v2 error format
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001691
1692Returns:
1693 An object of the form:
1694
Dan O'Mearadd494642020-05-01 07:42:23 -07001695 { # A Dataproc job resource.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001696 &quot;sparkRJob&quot;: { # A Dataproc job for running Apache SparkR (https://spark.apache.org/docs/latest/sparkr.html) applications on YARN. # Optional. Job is a SparkR job.
1697 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001698 &quot;a_key&quot;: &quot;A String&quot;,
1699 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001700 &quot;archiveUris&quot;: [ # 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.
1701 &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001702 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001703 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1704 &quot;A String&quot;,
1705 ],
1706 &quot;args&quot;: [ # 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.
1707 &quot;A String&quot;,
1708 ],
1709 &quot;mainRFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.
1710 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1711 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1712 &quot;a_key&quot;: &quot;A String&quot;,
1713 },
1714 },
1715 },
1716 &quot;prestoJob&quot;: { # 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. # Optional. Job is a Presto job.
1717 &quot;continueOnFailure&quot;: True or False, # 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.
1718 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1719 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1720 &quot;a_key&quot;: &quot;A String&quot;,
1721 },
1722 },
1723 &quot;clientTags&quot;: [ # Optional. Presto client tags to attach to this query
1724 &quot;A String&quot;,
1725 ],
1726 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
1727 &quot;properties&quot;: { # 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
1728 &quot;a_key&quot;: &quot;A String&quot;,
1729 },
1730 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1731 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1732 &quot;A String&quot;,
1733 ],
1734 },
1735 &quot;outputFormat&quot;: &quot;A String&quot;, # Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats
1736 },
1737 &quot;statusHistory&quot;: [ # Output only. The previous job status.
1738 { # Dataproc job status.
1739 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
1740 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
1741 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
1742 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
1743 },
1744 ],
1745 &quot;pigJob&quot;: { # A Dataproc job for running Apache Pig (https://pig.apache.org/) queries on YARN. # Optional. Job is a Pig job.
1746 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).
1747 &quot;a_key&quot;: &quot;A String&quot;,
1748 },
1749 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1750 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1751 &quot;a_key&quot;: &quot;A String&quot;,
1752 },
1753 },
1754 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.
1755 &quot;a_key&quot;: &quot;A String&quot;,
1756 },
1757 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1758 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1759 &quot;A String&quot;,
1760 ],
1761 },
1762 &quot;continueOnFailure&quot;: True or False, # 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.
1763 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.
1764 &quot;A String&quot;,
1765 ],
1766 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains the Pig queries.
1767 },
1768 &quot;status&quot;: { # Dataproc job status. # Output only. The job status. Additional application-specific status information may be contained in the type_job and yarn_applications fields.
1769 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
1770 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
1771 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
1772 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
1773 },
1774 &quot;jobUuid&quot;: &quot;A String&quot;, # 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 may be reused over time.
1775 &quot;pysparkJob&quot;: { # A Dataproc job for running Apache PySpark (https://spark.apache.org/docs/0.9.0/python-programming-guide.html) applications on YARN. # Optional. Job is a PySpark job.
1776 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
1777 &quot;a_key&quot;: &quot;A String&quot;,
1778 },
1779 &quot;mainPythonFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.
1780 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1781 &quot;A String&quot;,
1782 ],
1783 &quot;archiveUris&quot;: [ # 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.
1784 &quot;A String&quot;,
1785 ],
1786 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.
1787 &quot;A String&quot;,
1788 ],
1789 &quot;args&quot;: [ # 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.
1790 &quot;A String&quot;,
1791 ],
1792 &quot;pythonFileUris&quot;: [ # Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.
1793 &quot;A String&quot;,
1794 ],
1795 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1796 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1797 &quot;a_key&quot;: &quot;A String&quot;,
1798 },
1799 },
1800 },
1801 &quot;placement&quot;: { # Dataproc job config. # Required. Job information, including how, when, and where to run the job.
1802 &quot;clusterName&quot;: &quot;A String&quot;, # Required. The name of the cluster where the job will be submitted.
1803 &quot;clusterUuid&quot;: &quot;A String&quot;, # Output only. A cluster UUID generated by the Dataproc service when the job is submitted.
1804 },
1805 &quot;hadoopJob&quot;: { # A Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). # Optional. Job is a Hadoop job.
1806 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.
1807 &quot;a_key&quot;: &quot;A String&quot;,
1808 },
1809 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file containing the main class. Examples: &#x27;gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar&#x27; &#x27;hdfs:/tmp/test-samples/custom-wordcount.jar&#x27; &#x27;file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar&#x27;
1810 &quot;args&quot;: [ # 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 may occur that causes an incorrect job submission.
1811 &quot;A String&quot;,
1812 ],
1813 &quot;jarFileUris&quot;: [ # Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.
1814 &quot;A String&quot;,
1815 ],
1816 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1817 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1818 &quot;a_key&quot;: &quot;A String&quot;,
1819 },
1820 },
1821 &quot;archiveUris&quot;: [ # 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.
1822 &quot;A String&quot;,
1823 ],
1824 &quot;fileUris&quot;: [ # 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.
1825 &quot;A String&quot;,
1826 ],
1827 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.
1828 },
1829 &quot;sparkSqlJob&quot;: { # A Dataproc job for running Apache Spark SQL (http://spark.apache.org/sql/) queries. # Optional. Job is a SparkSql job.
1830 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark SQL&#x27;s SparkConf. Properties that conflict with values set by the Dataproc API may be overwritten.
1831 &quot;a_key&quot;: &quot;A String&quot;,
1832 },
1833 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1834 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1835 &quot;A String&quot;,
1836 ],
1837 },
1838 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
1839 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1840 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1841 &quot;a_key&quot;: &quot;A String&quot;,
1842 },
1843 },
1844 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name=&quot;value&quot;;).
1845 &quot;a_key&quot;: &quot;A String&quot;,
1846 },
1847 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.
1848 &quot;A String&quot;,
1849 ],
1850 },
1851 &quot;driverControlFilesUri&quot;: &quot;A String&quot;, # Output only. If present, the location of miscellaneous control files which may be used as part of job setup and handling. If not present, control files may be placed in the same location as driver_output_uri.
1852 &quot;sparkJob&quot;: { # A Dataproc job for running Apache Spark (http://spark.apache.org/) applications on YARN. # Optional. Job is a Spark job.
1853 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1854 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1855 &quot;a_key&quot;: &quot;A String&quot;,
1856 },
1857 },
1858 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file that contains the main class.
1859 &quot;args&quot;: [ # 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.
1860 &quot;A String&quot;,
1861 ],
1862 &quot;archiveUris&quot;: [ # 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.
1863 &quot;A String&quot;,
1864 ],
1865 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.
1866 &quot;A String&quot;,
1867 ],
1868 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
1869 &quot;a_key&quot;: &quot;A String&quot;,
1870 },
1871 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1872 &quot;A String&quot;,
1873 ],
1874 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file that contains the class must be in the default CLASSPATH or specified in jar_file_uris.
1875 },
1876 &quot;done&quot;: True or False, # 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.
1877 &quot;scheduling&quot;: { # Job scheduling options. # Optional. Job scheduling configuration.
1878 &quot;maxFailuresPerHour&quot;: 42, # Optional. Maximum number of times per hour a driver may be restarted as a result of driver exiting with non-zero code before job is reported failed.A job may be reported as thrashing if driver exits with non-zero code 4 times within 10 minute window.Maximum value is 10.
1879 },
1880 &quot;reference&quot;: { # Encapsulates the full scoping used to reference a job. # 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.
1881 &quot;jobId&quot;: &quot;A String&quot;, # 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.
1882 &quot;projectId&quot;: &quot;A String&quot;, # Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.
1883 },
1884 &quot;hiveJob&quot;: { # A Dataproc job for running Apache Hive (https://hive.apache.org/) queries on YARN. # Optional. Job is a Hive job.
1885 &quot;continueOnFailure&quot;: True or False, # 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.
1886 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains Hive queries.
1887 &quot;properties&quot;: { # Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.
1888 &quot;a_key&quot;: &quot;A String&quot;,
1889 },
1890 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name=&quot;value&quot;;).
1891 &quot;a_key&quot;: &quot;A String&quot;,
1892 },
1893 &quot;jarFileUris&quot;: [ # 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.
1894 &quot;A String&quot;,
1895 ],
1896 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1897 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
1898 &quot;A String&quot;,
1899 ],
1900 },
1901 },
1902 &quot;driverOutputResourceUri&quot;: &quot;A String&quot;, # Output only. A URI pointing to the location of the stdout of the job&#x27;s driver program.
1903 &quot;yarnApplications&quot;: [ # Output only. The collection of YARN applications spun up by this job.Beta Feature: This report is available for testing purposes only. It may be changed before final release.
1904 { # 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.
1905 &quot;name&quot;: &quot;A String&quot;, # Required. The application name.
1906 &quot;state&quot;: &quot;A String&quot;, # Required. The application state.
1907 &quot;trackingUrl&quot;: &quot;A String&quot;, # 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.
1908 &quot;progress&quot;: 3.14, # Required. The numerical progress of the application, from 1 to 100.
1909 },
1910 ],
1911 &quot;labels&quot;: { # Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). No more than 32 labels can be associated with a job.
1912 &quot;a_key&quot;: &quot;A String&quot;,
1913 },
1914 }</pre>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08001915</div>
1916
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001917<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07001918 <code class="details" id="submitAsOperation">submitAsOperation(projectId, region, body=None, x__xgafv=None)</code>
1919 <pre>Submits job to a cluster.
1920
1921Args:
1922 projectId: string, Required. The ID of the Google Cloud Platform project that the job belongs to. (required)
1923 region: string, Required. The Dataproc region in which to handle the request. (required)
1924 body: object, The request body.
1925 The object takes the form of:
1926
1927{ # A request to submit a job.
Bu Sun Kim65020912020-05-20 12:08:20 -07001928 &quot;job&quot;: { # A Dataproc job resource. # Required. The job resource.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001929 &quot;sparkRJob&quot;: { # A Dataproc job for running Apache SparkR (https://spark.apache.org/docs/latest/sparkr.html) applications on YARN. # Optional. Job is a SparkR job.
1930 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure SparkR. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001931 &quot;a_key&quot;: &quot;A String&quot;,
1932 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001933 &quot;archiveUris&quot;: [ # 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.
1934 &quot;A String&quot;,
1935 ],
1936 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
1937 &quot;A String&quot;,
1938 ],
1939 &quot;args&quot;: [ # 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.
1940 &quot;A String&quot;,
1941 ],
1942 &quot;mainRFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main R file to use as the driver. Must be a .R file.
1943 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1944 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001945 &quot;a_key&quot;: &quot;A String&quot;,
1946 },
1947 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001948 },
1949 &quot;prestoJob&quot;: { # 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. # Optional. Job is a Presto job.
1950 &quot;continueOnFailure&quot;: True or False, # 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.
1951 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1952 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001953 &quot;a_key&quot;: &quot;A String&quot;,
1954 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001955 },
1956 &quot;clientTags&quot;: [ # Optional. Presto client tags to attach to this query
1957 &quot;A String&quot;,
1958 ],
1959 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
1960 &quot;properties&quot;: { # 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
1961 &quot;a_key&quot;: &quot;A String&quot;,
1962 },
1963 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1964 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001965 &quot;A String&quot;,
1966 ],
1967 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001968 &quot;outputFormat&quot;: &quot;A String&quot;, # Optional. The format in which query output will be displayed. See the Presto documentation for supported output formats
1969 },
1970 &quot;statusHistory&quot;: [ # Output only. The previous job status.
1971 { # Dataproc job status.
1972 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
1973 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
1974 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
1975 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001976 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001977 ],
1978 &quot;pigJob&quot;: { # A Dataproc job for running Apache Pig (https://pig.apache.org/) queries on YARN. # Optional. Job is a Pig job.
1979 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Pig command: name=[value]).
1980 &quot;a_key&quot;: &quot;A String&quot;,
1981 },
1982 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
1983 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
1984 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001985 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001986 },
1987 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Pig. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/pig/conf/pig.properties, and classes in user code.
1988 &quot;a_key&quot;: &quot;A String&quot;,
1989 },
1990 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
1991 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001992 &quot;A String&quot;,
1993 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001994 },
1995 &quot;continueOnFailure&quot;: True or False, # 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.
1996 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATH of the Pig Client and Hadoop MapReduce (MR) tasks. Can contain Pig UDFs.
1997 &quot;A String&quot;,
1998 ],
1999 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains the Pig queries.
2000 },
2001 &quot;status&quot;: { # Dataproc job status. # Output only. The job status. Additional application-specific status information may be contained in the type_job and yarn_applications fields.
2002 &quot;state&quot;: &quot;A String&quot;, # Output only. A state message specifying the overall job state.
2003 &quot;details&quot;: &quot;A String&quot;, # Optional. Output only. Job state details, such as an error description if the state is ERROR.
2004 &quot;stateStartTime&quot;: &quot;A String&quot;, # Output only. The time when this state was entered.
2005 &quot;substate&quot;: &quot;A String&quot;, # Output only. Additional state information, which includes status reported by the agent.
2006 },
2007 &quot;jobUuid&quot;: &quot;A String&quot;, # 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 may be reused over time.
2008 &quot;pysparkJob&quot;: { # A Dataproc job for running Apache PySpark (https://spark.apache.org/docs/0.9.0/python-programming-guide.html) applications on YARN. # Optional. Job is a PySpark job.
2009 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure PySpark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
2010 &quot;a_key&quot;: &quot;A String&quot;,
2011 },
2012 &quot;mainPythonFileUri&quot;: &quot;A String&quot;, # Required. The HCFS URI of the main Python file to use as the driver. Must be a .py file.
2013 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
2014 &quot;A String&quot;,
2015 ],
2016 &quot;archiveUris&quot;: [ # 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.
2017 &quot;A String&quot;,
2018 ],
2019 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Python driver and tasks.
2020 &quot;A String&quot;,
2021 ],
2022 &quot;args&quot;: [ # 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.
2023 &quot;A String&quot;,
2024 ],
2025 &quot;pythonFileUris&quot;: [ # Optional. HCFS file URIs of Python files to pass to the PySpark framework. Supported file types: .py, .egg, and .zip.
2026 &quot;A String&quot;,
2027 ],
2028 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
2029 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002030 &quot;a_key&quot;: &quot;A String&quot;,
2031 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002032 },
2033 },
2034 &quot;placement&quot;: { # Dataproc job config. # Required. Job information, including how, when, and where to run the job.
2035 &quot;clusterName&quot;: &quot;A String&quot;, # Required. The name of the cluster where the job will be submitted.
2036 &quot;clusterUuid&quot;: &quot;A String&quot;, # Output only. A cluster UUID generated by the Dataproc service when the job is submitted.
2037 },
2038 &quot;hadoopJob&quot;: { # A Dataproc job for running Apache Hadoop MapReduce (https://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapReduceTutorial.html) jobs on Apache Hadoop YARN (https://hadoop.apache.org/docs/r2.7.1/hadoop-yarn/hadoop-yarn-site/YARN.html). # Optional. Job is a Hadoop job.
2039 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Hadoop. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site and classes in user code.
2040 &quot;a_key&quot;: &quot;A String&quot;,
2041 },
2042 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file containing the main class. Examples: &#x27;gs://foo-bucket/analytics-binaries/extract-useful-metrics-mr.jar&#x27; &#x27;hdfs:/tmp/test-samples/custom-wordcount.jar&#x27; &#x27;file:///home/usr/lib/hadoop-mapreduce/hadoop-mapreduce-examples.jar&#x27;
2043 &quot;args&quot;: [ # 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 may occur that causes an incorrect job submission.
2044 &quot;A String&quot;,
2045 ],
2046 &quot;jarFileUris&quot;: [ # Optional. Jar file URIs to add to the CLASSPATHs of the Hadoop driver and tasks.
2047 &quot;A String&quot;,
2048 ],
2049 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
2050 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002051 &quot;a_key&quot;: &quot;A String&quot;,
2052 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002053 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002054 &quot;archiveUris&quot;: [ # 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.
2055 &quot;A String&quot;,
2056 ],
2057 &quot;fileUris&quot;: [ # 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.
2058 &quot;A String&quot;,
2059 ],
2060 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file containing the class must be in the default CLASSPATH or specified in jar_file_uris.
2061 },
2062 &quot;sparkSqlJob&quot;: { # A Dataproc job for running Apache Spark SQL (http://spark.apache.org/sql/) queries. # Optional. Job is a SparkSql job.
2063 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark SQL&#x27;s SparkConf. Properties that conflict with values set by the Dataproc API may be overwritten.
2064 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002065 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002066 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
2067 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
2068 &quot;A String&quot;,
2069 ],
2070 },
2071 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains SQL queries.
2072 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
2073 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
2074 &quot;a_key&quot;: &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002075 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002076 },
2077 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Spark SQL command: SET name=&quot;value&quot;;).
2078 &quot;a_key&quot;: &quot;A String&quot;,
2079 },
2080 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to be added to the Spark CLASSPATH.
2081 &quot;A String&quot;,
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002082 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002083 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002084 &quot;driverControlFilesUri&quot;: &quot;A String&quot;, # Output only. If present, the location of miscellaneous control files which may be used as part of job setup and handling. If not present, control files may be placed in the same location as driver_output_uri.
2085 &quot;sparkJob&quot;: { # A Dataproc job for running Apache Spark (http://spark.apache.org/) applications on YARN. # Optional. Job is a Spark job.
2086 &quot;loggingConfig&quot;: { # The runtime logging config of the job. # Optional. The runtime log config for job execution.
2087 &quot;driverLogLevels&quot;: { # The per-package log levels for the driver. This may include &quot;root&quot; package name to configure rootLogger. Examples: &#x27;com.google = FATAL&#x27;, &#x27;root = INFO&#x27;, &#x27;org.apache = DEBUG&#x27;
2088 &quot;a_key&quot;: &quot;A String&quot;,
2089 },
2090 },
2091 &quot;mainJarFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the jar file that contains the main class.
2092 &quot;args&quot;: [ # 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.
2093 &quot;A String&quot;,
2094 ],
2095 &quot;archiveUris&quot;: [ # 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.
2096 &quot;A String&quot;,
2097 ],
2098 &quot;jarFileUris&quot;: [ # Optional. HCFS URIs of jar files to add to the CLASSPATHs of the Spark driver and tasks.
2099 &quot;A String&quot;,
2100 ],
2101 &quot;properties&quot;: { # Optional. A mapping of property names to values, used to configure Spark. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/spark/conf/spark-defaults.conf and classes in user code.
2102 &quot;a_key&quot;: &quot;A String&quot;,
2103 },
2104 &quot;fileUris&quot;: [ # Optional. HCFS URIs of files to be placed in the working directory of each executor. Useful for naively parallel tasks.
2105 &quot;A String&quot;,
2106 ],
2107 &quot;mainClass&quot;: &quot;A String&quot;, # The name of the driver&#x27;s main class. The jar file that contains the class must be in the default CLASSPATH or specified in jar_file_uris.
2108 },
2109 &quot;done&quot;: True or False, # 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.
2110 &quot;scheduling&quot;: { # Job scheduling options. # Optional. Job scheduling configuration.
2111 &quot;maxFailuresPerHour&quot;: 42, # Optional. Maximum number of times per hour a driver may be restarted as a result of driver exiting with non-zero code before job is reported failed.A job may be reported as thrashing if driver exits with non-zero code 4 times within 10 minute window.Maximum value is 10.
2112 },
2113 &quot;reference&quot;: { # Encapsulates the full scoping used to reference a job. # 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.
2114 &quot;jobId&quot;: &quot;A String&quot;, # 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.
2115 &quot;projectId&quot;: &quot;A String&quot;, # Optional. The ID of the Google Cloud Platform project that the job belongs to. If specified, must match the request project ID.
2116 },
2117 &quot;hiveJob&quot;: { # A Dataproc job for running Apache Hive (https://hive.apache.org/) queries on YARN. # Optional. Job is a Hive job.
2118 &quot;continueOnFailure&quot;: True or False, # 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.
2119 &quot;queryFileUri&quot;: &quot;A String&quot;, # The HCFS URI of the script that contains Hive queries.
2120 &quot;properties&quot;: { # Optional. A mapping of property names and values, used to configure Hive. Properties that conflict with values set by the Dataproc API may be overwritten. Can include properties set in /etc/hadoop/conf/*-site.xml, /etc/hive/conf/hive-site.xml, and classes in user code.
2121 &quot;a_key&quot;: &quot;A String&quot;,
2122 },
2123 &quot;scriptVariables&quot;: { # Optional. Mapping of query variable names to values (equivalent to the Hive command: SET name=&quot;value&quot;;).
2124 &quot;a_key&quot;: &quot;A String&quot;,
2125 },
2126 &quot;jarFileUris&quot;: [ # 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.
2127 &quot;A String&quot;,
2128 ],
2129 &quot;queryList&quot;: { # A list of queries to run on a cluster. # A list of queries.
2130 &quot;queries&quot;: [ # 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: &quot;hiveJob&quot;: { &quot;queryList&quot;: { &quot;queries&quot;: [ &quot;query1&quot;, &quot;query2&quot;, &quot;query3;query4&quot;, ] } }
2131 &quot;A String&quot;,
2132 ],
2133 },
2134 },
2135 &quot;driverOutputResourceUri&quot;: &quot;A String&quot;, # Output only. A URI pointing to the location of the stdout of the job&#x27;s driver program.
2136 &quot;yarnApplications&quot;: [ # Output only. The collection of YARN applications spun up by this job.Beta Feature: This report is available for testing purposes only. It may be changed before final release.
2137 { # 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.
2138 &quot;name&quot;: &quot;A String&quot;, # Required. The application name.
2139 &quot;state&quot;: &quot;A String&quot;, # Required. The application state.
2140 &quot;trackingUrl&quot;: &quot;A String&quot;, # 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.
2141 &quot;progress&quot;: 3.14, # Required. The numerical progress of the application, from 1 to 100.
2142 },
2143 ],
2144 &quot;labels&quot;: { # Optional. The labels to associate with this job. Label keys must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). Label values may be empty, but, if present, must contain 1 to 63 characters, and must conform to RFC 1035 (https://www.ietf.org/rfc/rfc1035.txt). No more than 32 labels can be associated with a job.
2145 &quot;a_key&quot;: &quot;A String&quot;,
2146 },
2147 },
2148 &quot;requestId&quot;: &quot;A String&quot;, # Optional. A unique id used to identify the request. If the server receives two SubmitJobRequest requests 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 (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.
Dan O'Mearadd494642020-05-01 07:42:23 -07002149 }
2150
2151 x__xgafv: string, V1 error format.
2152 Allowed values
2153 1 - v1 error format
2154 2 - v2 error format
2155
2156Returns:
2157 An object of the form:
2158
2159 { # This resource represents a long-running operation that is the result of a network API call.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002160 &quot;response&quot;: { # The normal response of the operation in case of success. If the original method returns no data on success, such as Delete, the response is google.protobuf.Empty. If the original method is standard Get/Create/Update, the response should be the resource. For other methods, the response should have the type XxxResponse, where Xxx is the original method name. For example, if the original method name is TakeSnapshot(), the inferred response type is TakeSnapshotResponse.
2161 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2162 },
2163 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
2164 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2165 },
2166 &quot;done&quot;: True or False, # If the value is false, it means the operation is still in progress. If true, the operation is completed, and either error or response is available.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002167 &quot;error&quot;: { # The Status type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each Status message contains three pieces of data: error code, error message, and error details.You can find out more about this error model and how to work with it in the API Design Guide (https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
2168 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
2169 {
2170 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2171 },
2172 ],
2173 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
2174 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
2175 },
2176 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the name should be a resource name ending with operations/{unique_id}.
Dan O'Mearadd494642020-05-01 07:42:23 -07002177 }</pre>
2178</div>
2179
2180<div class="method">
2181 <code class="details" id="testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</code>
Bu Sun Kim65020912020-05-20 12:08:20 -07002182 <pre>Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may &quot;fail open&quot; without warning.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002183
2184Args:
2185 resource: string, REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002186 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002187 The object takes the form of:
2188
2189{ # Request message for TestIamPermissions method.
Bu Sun Kim65020912020-05-20 12:08:20 -07002190 &quot;permissions&quot;: [ # The set of permissions to check for the resource. Permissions with wildcards (such as &#x27;*&#x27; or &#x27;storage.*&#x27;) are not allowed. For more information see IAM Overview (https://cloud.google.com/iam/docs/overview#permissions).
2191 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002192 ],
2193 }
2194
2195 x__xgafv: string, V1 error format.
2196 Allowed values
2197 1 - v1 error format
2198 2 - v2 error format
2199
2200Returns:
2201 An object of the form:
2202
2203 { # Response message for TestIamPermissions method.
Bu Sun Kim65020912020-05-20 12:08:20 -07002204 &quot;permissions&quot;: [ # A subset of TestPermissionsRequest.permissions that the caller is allowed.
2205 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002206 ],
2207 }</pre>
2208</div>
2209
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -08002210</body></html>