blob: c5fdd2c193c88ed8076fb32cbf36045f9e926d66 [file] [log] [blame]
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001<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
75<h1><a href="cloudtasks_v2beta2.html">Cloud Tasks API</a> . <a href="cloudtasks_v2beta2.projects.html">projects</a> . <a href="cloudtasks_v2beta2.projects.locations.html">locations</a> . <a href="cloudtasks_v2beta2.projects.locations.queues.html">queues</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="cloudtasks_v2beta2.projects.locations.queues.tasks.html">tasks()</a></code>
79</p>
80<p class="firstline">Returns the tasks Resource.</p>
81
82<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070083 <code><a href="#create">create(parent, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070084<p class="firstline">Creates a queue.</p>
85<p class="toc_element">
86 <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
87<p class="firstline">Deletes a queue.</p>
88<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070089 <code><a href="#get">get(name, readMask=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070090<p class="firstline">Gets a queue.</p>
91<p class="toc_element">
92 <code><a href="#getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</a></code></p>
93<p class="firstline">Gets the access control policy for a Queue.</p>
94<p class="toc_element">
Bu Sun Kim65020912020-05-20 12:08:20 -070095 <code><a href="#list">list(parent, filter=None, pageToken=None, pageSize=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070096<p class="firstline">Lists queues.</p>
97<p class="toc_element">
98 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
99<p class="firstline">Retrieves the next page of results.</p>
100<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700101 <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700102<p class="firstline">Updates a queue.</p>
103<p class="toc_element">
104 <code><a href="#pause">pause(name, body=None, x__xgafv=None)</a></code></p>
105<p class="firstline">Pauses the queue.</p>
106<p class="toc_element">
107 <code><a href="#purge">purge(name, body=None, x__xgafv=None)</a></code></p>
108<p class="firstline">Purges a queue by deleting all of its tasks.</p>
109<p class="toc_element">
110 <code><a href="#resume">resume(name, body=None, x__xgafv=None)</a></code></p>
111<p class="firstline">Resume a queue.</p>
112<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700113 <code><a href="#setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700114<p class="firstline">Sets the access control policy for a Queue. Replaces any existing</p>
115<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700116 <code><a href="#testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700117<p class="firstline">Returns permissions that a caller has on a Queue.</p>
118<h3>Method Details</h3>
119<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700120 <code class="details" id="create">create(parent, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700121 <pre>Creates a queue.
122
123Queues created with this method allow tasks to live for a maximum of 31
124days. After a task is 31 days old, the task will be deleted regardless of whether
125it was dispatched or not.
126
127WARNING: Using this method may have unintended side effects if you are
128using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
129Read
130[Overview of Queue Management and
131queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
132this method.
133
134Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700135 parent: string, Required. The location name in which the queue will be created.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700136For example: `projects/PROJECT_ID/locations/LOCATION_ID`
137
138The list of allowed locations can be obtained by calling Cloud
Bu Sun Kim65020912020-05-20 12:08:20 -0700139Tasks&#x27; implementation of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700140ListLocations. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700141 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700142 The object takes the form of:
143
144{ # A queue is a container of related tasks. Queues are configured to manage
145 # how those tasks are dispatched. Configurable properties include rate limits,
146 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -0700147 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700148 #
149 # An App Engine queue is a queue that has an AppEngineHttpTarget.
150 #
151 # The task will be delivered to the App Engine application hostname
152 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
153 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -0700154 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700155 #
156 # Using AppEngineHttpTarget requires
157 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
158 # Google IAM permission for the project
159 # and the following scope:
160 #
161 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -0700162 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700163 # task-level app_engine_routing.
164 #
165 # If set, `app_engine_routing_override` is used for all tasks in
166 # the queue, no matter what the setting is for the
167 # task-level app_engine_routing.
168 #
169 # Defines routing characteristics specific to App Engine - service, version,
170 # and instance.
171 #
172 # For more information about services, versions, and instances see
173 # [An Overview of App
174 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
175 # [Microservices Architecture on Google App
176 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
177 # [App Engine Standard request
178 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
179 # and [App Engine Flex request
180 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -0700181 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700182 #
183 # By default, the task is sent to an instance which is available when
184 # the task is attempted.
185 #
186 # Requests can only be sent to a specific instance if
187 # [manual scaling is used in App Engine
188 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
189 # App Engine Flex does not support instances. For more information, see
190 # [App Engine Standard request
191 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
192 # and [App Engine Flex request
193 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -0700194 &quot;version&quot;: &quot;A String&quot;, # App version.
195 #
196 # By default, the task is sent to the version which is the default
197 # version when the task is attempted.
198 #
199 # For some queues or tasks which were created using the App Engine
200 # Task Queue API, host is not parsable
201 # into service,
202 # version, and
203 # instance. For example, some tasks
204 # which were created using the App Engine SDK use a custom domain
205 # name; custom domains are not parsed by Cloud Tasks. If
206 # host is not parsable, then
207 # service,
208 # version, and
209 # instance are the empty string.
210 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700211 #
212 # For more information, see
213 # [How Requests are
214 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
215 #
216 # The host is constructed as:
217 #
218 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700219 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -0700220 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
221 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
222 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
223 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
224 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
225 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
226 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700227 #
228 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -0700229 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -0700230 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700231 # SDK use a custom domain name.
232 #
233 # * `service =` service
234 #
235 # * `version =` version
236 #
237 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -0700238 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700239 # service
240 #
241 # * `instance =` instance
242 #
243 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -0700244 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700245 # service
246 #
247 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -0700248 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700249 # version
250 #
251 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -0700252 # instance `+ &#x27;.&#x27; +`
253 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700254 # service
255 #
256 # If service is empty, then the task will be sent
257 # to the service which is the default service when the task is attempted.
258 #
259 # If version is empty, then the task will be sent
260 # to the version which is the default version when the task is attempted.
261 #
262 # If instance is empty, then the task
263 # will be sent to an instance which is available when the task is
264 # attempted.
265 #
266 # If service,
267 # version, or
268 # instance is invalid, then the task
269 # will be sent to the default version of the default service when
270 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -0700271 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700272 #
273 # By default, the task is sent to the service which is the default
274 # service when the task is attempted.
275 #
276 # For some queues or tasks which were created using the App Engine
277 # Task Queue API, host is not parsable
278 # into service,
279 # version, and
280 # instance. For example, some tasks
281 # which were created using the App Engine SDK use a custom domain
282 # name; custom domains are not parsed by Cloud Tasks. If
283 # host is not parsable, then
284 # service,
285 # version, and
286 # instance are the empty string.
287 },
288 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700289 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700290 #
291 # All tasks that were created before this time
292 # were purged.
293 #
294 # A queue can be purged using PurgeQueue, the
295 # [App Engine Task Queue SDK, or the Cloud
296 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
297 #
298 # Purge time will be truncated to the nearest microsecond. Purge
299 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -0700300 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
301 #
302 # `state` can only be changed by called
303 # PauseQueue,
304 # ResumeQueue, or uploading
305 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
306 # UpdateQueue cannot be used to change `state`.
307 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700308 #
309 # * For tasks created using Cloud Tasks: the queue-level retry settings
310 # apply to all tasks in the queue that were created using Cloud Tasks.
311 # Retry settings cannot be set on individual tasks.
312 # * For tasks created using the App Engine SDK: the queue-level retry
313 # settings apply to all tasks in the queue which do not have retry settings
314 # explicitly set on the task and were created by the App Engine SDK. See
315 # [App Engine
316 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
317 #
318 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -0700319 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
320 # min_backoff and
321 # max_backoff duration after it fails,
322 # if the queue&#x27;s RetryConfig specifies that the task should be
323 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700324 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700325 # If unspecified when the queue is created, Cloud Tasks will pick the
326 # default.
327 #
328 # This field is output only for pull queues.
329 #
330 #
331 # `min_backoff` will be truncated to the nearest second.
332 #
333 # This field has the same meaning as
334 # [min_backoff_seconds in
335 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
336 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
337 # min_backoff and
338 # max_backoff duration after it fails,
339 # if the queue&#x27;s RetryConfig specifies that the task should be
340 # retried.
341 #
342 # If unspecified when the queue is created, Cloud Tasks will pick the
343 # default.
344 #
345 # This field is output only for pull queues.
346 #
347 #
348 # `max_backoff` will be truncated to the nearest second.
349 #
350 # This field has the same meaning as
351 # [max_backoff_seconds in
352 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
353 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
354 # retrying a failed task, measured from when the task was first
355 # attempted. Once `max_retry_duration` time has passed *and* the
356 # task has been attempted max_attempts
357 # times, no further attempts will be made and the task will be
358 # deleted.
359 #
360 # If zero, then the task age is unlimited.
361 #
362 # If unspecified when the queue is created, Cloud Tasks will pick the
363 # default.
364 #
365 # This field is output only for pull queues.
366 #
367 #
368 # `max_retry_duration` will be truncated to the nearest second.
369 #
370 # This field has the same meaning as
371 # [task_age_limit in
372 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
373 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
374 #
375 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700376 # min_backoff, then doubles
377 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -0700378 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700379 # max_backoff up to
380 # max_attempts times.
381 #
382 # For example, if min_backoff is 10s,
383 # max_backoff is 300s, and
384 # `max_doublings` is 3, then the a task will first be retried in
385 # 10s. The retry interval will double three times, and then
386 # increase linearly by 2^3 * 10s. Finally, the task will retry at
387 # intervals of max_backoff until the
388 # task has been attempted max_attempts
389 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
390 # 240s, 300s, 300s, ....
391 #
392 # If unspecified when the queue is created, Cloud Tasks will pick the
393 # default.
394 #
395 # This field is output only for pull queues.
396 #
397 #
398 # This field has the same meaning as
399 # [max_doublings in
400 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -0700401 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700402 #
403 # Cloud Tasks will attempt the task `max_attempts` times (that
404 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -0700405 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -0700406 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
407 },
408 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
409 # after which it becomes output only.
410 #
411 # The queue name.
412 #
413 # The queue name must have the following format:
414 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
415 #
416 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
417 # hyphens (-), colons (:), or periods (.).
418 # For more information, see
419 # [Identifying
420 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
421 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
422 # The list of available locations can be obtained by calling
423 # ListLocations.
424 # For more information, see https://cloud.google.com/about/locations/.
425 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
426 # hyphens (-). The maximum length is 100 characters.
427 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
428 #
429 # rate_limits and
430 # retry_config are related because they both
431 # control task attempts however they control how tasks are
432 # attempted in different ways:
433 #
434 # * rate_limits controls the total rate of
435 # dispatches from a queue (i.e. all traffic dispatched from the
436 # queue, regardless of whether the dispatch is from a first
437 # attempt or a retry).
438 # * retry_config controls what happens to
439 # particular a task after its first attempt fails. That is,
440 # retry_config controls task retries (the
441 # second attempt, third attempt, etc).
442 #
443 # This message determines the maximum rate that tasks can be dispatched by a
444 # queue, regardless of whether the dispatch is a first task attempt or a retry.
445 #
446 # Note: The debugging command, RunTask, will run a task
447 # even if the queue has reached its RateLimits.
448 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
449 # to be dispatched for this queue. After this threshold has been
450 # reached, Cloud Tasks stops dispatching tasks until the number of
451 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700452 #
453 # If unspecified when the queue is created, Cloud Tasks will pick the
454 # default.
455 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700456 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700457 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700458 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700459 # This field is output only for
460 # pull queues and always -1, which indicates no limit. No other
461 # queue types can have `max_concurrent_tasks` set to -1.
462 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700463 #
464 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -0700465 # [max_concurrent_requests in
466 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
467 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700468 #
469 # If unspecified when the queue is created, Cloud Tasks will pick the
470 # default.
471 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700472 # * For App Engine queues, the maximum allowed value
473 # is 500.
474 # * This field is output only for pull queues. In addition to the
475 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
476 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700477 #
478 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700479 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -0700480 # [rate in
481 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
482 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700483 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700484 # Max burst size limits how fast tasks in queue are processed when
485 # many tasks are in the queue and the rate is high. This field
486 # allows the queue to have a high rate so processing starts shortly
487 # after a task is enqueued, but still limits resource usage when
488 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700489 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700490 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
491 # algorithm is used to control the rate of task dispatches. Each
492 # queue has a token bucket that holds tokens, up to the maximum
493 # specified by `max_burst_size`. Each time a task is dispatched, a
494 # token is removed from the bucket. Tasks will be dispatched until
495 # the queue&#x27;s bucket runs out of tokens. The bucket will be
496 # continuously refilled with new tokens based on
497 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700498 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700499 # Cloud Tasks will pick the value of `max_burst_size` based on the
500 # value of
501 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700502 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700503 # For App Engine queues that were created or updated using
504 # `queue.yaml/xml`, `max_burst_size` is equal to
505 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
506 # Since `max_burst_size` is output only, if
507 # UpdateQueue is called on a queue
508 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
509 # on the value of
510 # max_tasks_dispatched_per_second,
511 # regardless of whether
512 # max_tasks_dispatched_per_second
513 # is updated.
514 },
515 &quot;pullTarget&quot;: { # Pull target. # Pull target.
516 #
517 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700518 },
519}
520
521 x__xgafv: string, V1 error format.
522 Allowed values
523 1 - v1 error format
524 2 - v2 error format
525
526Returns:
527 An object of the form:
528
529 { # A queue is a container of related tasks. Queues are configured to manage
530 # how those tasks are dispatched. Configurable properties include rate limits,
531 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -0700532 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700533 #
534 # An App Engine queue is a queue that has an AppEngineHttpTarget.
535 #
536 # The task will be delivered to the App Engine application hostname
537 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
538 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -0700539 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700540 #
541 # Using AppEngineHttpTarget requires
542 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
543 # Google IAM permission for the project
544 # and the following scope:
545 #
546 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -0700547 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700548 # task-level app_engine_routing.
549 #
550 # If set, `app_engine_routing_override` is used for all tasks in
551 # the queue, no matter what the setting is for the
552 # task-level app_engine_routing.
553 #
554 # Defines routing characteristics specific to App Engine - service, version,
555 # and instance.
556 #
557 # For more information about services, versions, and instances see
558 # [An Overview of App
559 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
560 # [Microservices Architecture on Google App
561 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
562 # [App Engine Standard request
563 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
564 # and [App Engine Flex request
565 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -0700566 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700567 #
568 # By default, the task is sent to an instance which is available when
569 # the task is attempted.
570 #
571 # Requests can only be sent to a specific instance if
572 # [manual scaling is used in App Engine
573 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
574 # App Engine Flex does not support instances. For more information, see
575 # [App Engine Standard request
576 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
577 # and [App Engine Flex request
578 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -0700579 &quot;version&quot;: &quot;A String&quot;, # App version.
580 #
581 # By default, the task is sent to the version which is the default
582 # version when the task is attempted.
583 #
584 # For some queues or tasks which were created using the App Engine
585 # Task Queue API, host is not parsable
586 # into service,
587 # version, and
588 # instance. For example, some tasks
589 # which were created using the App Engine SDK use a custom domain
590 # name; custom domains are not parsed by Cloud Tasks. If
591 # host is not parsable, then
592 # service,
593 # version, and
594 # instance are the empty string.
595 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700596 #
597 # For more information, see
598 # [How Requests are
599 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
600 #
601 # The host is constructed as:
602 #
603 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700604 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -0700605 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
606 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
607 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
608 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
609 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
610 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
611 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700612 #
613 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -0700614 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -0700615 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700616 # SDK use a custom domain name.
617 #
618 # * `service =` service
619 #
620 # * `version =` version
621 #
622 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -0700623 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700624 # service
625 #
626 # * `instance =` instance
627 #
628 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -0700629 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700630 # service
631 #
632 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -0700633 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700634 # version
635 #
636 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -0700637 # instance `+ &#x27;.&#x27; +`
638 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700639 # service
640 #
641 # If service is empty, then the task will be sent
642 # to the service which is the default service when the task is attempted.
643 #
644 # If version is empty, then the task will be sent
645 # to the version which is the default version when the task is attempted.
646 #
647 # If instance is empty, then the task
648 # will be sent to an instance which is available when the task is
649 # attempted.
650 #
651 # If service,
652 # version, or
653 # instance is invalid, then the task
654 # will be sent to the default version of the default service when
655 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -0700656 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700657 #
658 # By default, the task is sent to the service which is the default
659 # service when the task is attempted.
660 #
661 # For some queues or tasks which were created using the App Engine
662 # Task Queue API, host is not parsable
663 # into service,
664 # version, and
665 # instance. For example, some tasks
666 # which were created using the App Engine SDK use a custom domain
667 # name; custom domains are not parsed by Cloud Tasks. If
668 # host is not parsable, then
669 # service,
670 # version, and
671 # instance are the empty string.
672 },
673 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700674 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700675 #
676 # All tasks that were created before this time
677 # were purged.
678 #
679 # A queue can be purged using PurgeQueue, the
680 # [App Engine Task Queue SDK, or the Cloud
681 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
682 #
683 # Purge time will be truncated to the nearest microsecond. Purge
684 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -0700685 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
686 #
687 # `state` can only be changed by called
688 # PauseQueue,
689 # ResumeQueue, or uploading
690 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
691 # UpdateQueue cannot be used to change `state`.
692 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700693 #
694 # * For tasks created using Cloud Tasks: the queue-level retry settings
695 # apply to all tasks in the queue that were created using Cloud Tasks.
696 # Retry settings cannot be set on individual tasks.
697 # * For tasks created using the App Engine SDK: the queue-level retry
698 # settings apply to all tasks in the queue which do not have retry settings
699 # explicitly set on the task and were created by the App Engine SDK. See
700 # [App Engine
701 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
702 #
703 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -0700704 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
705 # min_backoff and
706 # max_backoff duration after it fails,
707 # if the queue&#x27;s RetryConfig specifies that the task should be
708 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700709 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700710 # If unspecified when the queue is created, Cloud Tasks will pick the
711 # default.
712 #
713 # This field is output only for pull queues.
714 #
715 #
716 # `min_backoff` will be truncated to the nearest second.
717 #
718 # This field has the same meaning as
719 # [min_backoff_seconds in
720 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
721 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
722 # min_backoff and
723 # max_backoff duration after it fails,
724 # if the queue&#x27;s RetryConfig specifies that the task should be
725 # retried.
726 #
727 # If unspecified when the queue is created, Cloud Tasks will pick the
728 # default.
729 #
730 # This field is output only for pull queues.
731 #
732 #
733 # `max_backoff` will be truncated to the nearest second.
734 #
735 # This field has the same meaning as
736 # [max_backoff_seconds in
737 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
738 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
739 # retrying a failed task, measured from when the task was first
740 # attempted. Once `max_retry_duration` time has passed *and* the
741 # task has been attempted max_attempts
742 # times, no further attempts will be made and the task will be
743 # deleted.
744 #
745 # If zero, then the task age is unlimited.
746 #
747 # If unspecified when the queue is created, Cloud Tasks will pick the
748 # default.
749 #
750 # This field is output only for pull queues.
751 #
752 #
753 # `max_retry_duration` will be truncated to the nearest second.
754 #
755 # This field has the same meaning as
756 # [task_age_limit in
757 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
758 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
759 #
760 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700761 # min_backoff, then doubles
762 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -0700763 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700764 # max_backoff up to
765 # max_attempts times.
766 #
767 # For example, if min_backoff is 10s,
768 # max_backoff is 300s, and
769 # `max_doublings` is 3, then the a task will first be retried in
770 # 10s. The retry interval will double three times, and then
771 # increase linearly by 2^3 * 10s. Finally, the task will retry at
772 # intervals of max_backoff until the
773 # task has been attempted max_attempts
774 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
775 # 240s, 300s, 300s, ....
776 #
777 # If unspecified when the queue is created, Cloud Tasks will pick the
778 # default.
779 #
780 # This field is output only for pull queues.
781 #
782 #
783 # This field has the same meaning as
784 # [max_doublings in
785 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -0700786 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700787 #
788 # Cloud Tasks will attempt the task `max_attempts` times (that
789 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -0700790 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -0700791 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
792 },
793 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
794 # after which it becomes output only.
795 #
796 # The queue name.
797 #
798 # The queue name must have the following format:
799 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
800 #
801 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
802 # hyphens (-), colons (:), or periods (.).
803 # For more information, see
804 # [Identifying
805 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
806 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
807 # The list of available locations can be obtained by calling
808 # ListLocations.
809 # For more information, see https://cloud.google.com/about/locations/.
810 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
811 # hyphens (-). The maximum length is 100 characters.
812 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
813 #
814 # rate_limits and
815 # retry_config are related because they both
816 # control task attempts however they control how tasks are
817 # attempted in different ways:
818 #
819 # * rate_limits controls the total rate of
820 # dispatches from a queue (i.e. all traffic dispatched from the
821 # queue, regardless of whether the dispatch is from a first
822 # attempt or a retry).
823 # * retry_config controls what happens to
824 # particular a task after its first attempt fails. That is,
825 # retry_config controls task retries (the
826 # second attempt, third attempt, etc).
827 #
828 # This message determines the maximum rate that tasks can be dispatched by a
829 # queue, regardless of whether the dispatch is a first task attempt or a retry.
830 #
831 # Note: The debugging command, RunTask, will run a task
832 # even if the queue has reached its RateLimits.
833 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
834 # to be dispatched for this queue. After this threshold has been
835 # reached, Cloud Tasks stops dispatching tasks until the number of
836 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700837 #
838 # If unspecified when the queue is created, Cloud Tasks will pick the
839 # default.
840 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700841 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700842 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700843 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700844 # This field is output only for
845 # pull queues and always -1, which indicates no limit. No other
846 # queue types can have `max_concurrent_tasks` set to -1.
847 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700848 #
849 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -0700850 # [max_concurrent_requests in
851 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
852 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700853 #
854 # If unspecified when the queue is created, Cloud Tasks will pick the
855 # default.
856 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700857 # * For App Engine queues, the maximum allowed value
858 # is 500.
859 # * This field is output only for pull queues. In addition to the
860 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
861 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700862 #
863 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700864 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -0700865 # [rate in
866 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
867 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700868 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700869 # Max burst size limits how fast tasks in queue are processed when
870 # many tasks are in the queue and the rate is high. This field
871 # allows the queue to have a high rate so processing starts shortly
872 # after a task is enqueued, but still limits resource usage when
873 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700874 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700875 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
876 # algorithm is used to control the rate of task dispatches. Each
877 # queue has a token bucket that holds tokens, up to the maximum
878 # specified by `max_burst_size`. Each time a task is dispatched, a
879 # token is removed from the bucket. Tasks will be dispatched until
880 # the queue&#x27;s bucket runs out of tokens. The bucket will be
881 # continuously refilled with new tokens based on
882 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700883 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700884 # Cloud Tasks will pick the value of `max_burst_size` based on the
885 # value of
886 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700887 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700888 # For App Engine queues that were created or updated using
889 # `queue.yaml/xml`, `max_burst_size` is equal to
890 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
891 # Since `max_burst_size` is output only, if
892 # UpdateQueue is called on a queue
893 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
894 # on the value of
895 # max_tasks_dispatched_per_second,
896 # regardless of whether
897 # max_tasks_dispatched_per_second
898 # is updated.
899 },
900 &quot;pullTarget&quot;: { # Pull target. # Pull target.
901 #
902 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700903 },
904 }</pre>
905</div>
906
907<div class="method">
908 <code class="details" id="delete">delete(name, x__xgafv=None)</code>
909 <pre>Deletes a queue.
910
911This command will delete the queue even if it has tasks in it.
912
Bu Sun Kim65020912020-05-20 12:08:20 -0700913Note: If you delete a queue, a queue with the same name can&#x27;t be created
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700914for 7 days.
915
916WARNING: Using this method may have unintended side effects if you are
917using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
918Read
919[Overview of Queue Management and
920queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
921this method.
922
923Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700924 name: string, Required. The queue name. For example:
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700925`projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` (required)
926 x__xgafv: string, V1 error format.
927 Allowed values
928 1 - v1 error format
929 2 - v2 error format
930
931Returns:
932 An object of the form:
933
934 { # A generic empty message that you can re-use to avoid defining duplicated
935 # empty messages in your APIs. A typical example is to use it as the request
936 # or the response type of an API method. For instance:
937 #
938 # service Foo {
939 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
940 # }
941 #
942 # The JSON representation for `Empty` is empty JSON object `{}`.
943 }</pre>
944</div>
945
946<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700947 <code class="details" id="get">get(name, readMask=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700948 <pre>Gets a queue.
949
950Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700951 name: string, Required. The resource name of the queue. For example:
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700952`projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700953 readMask: string, Optional. Read mask is used for a more granular control over what the API returns. By
954it includes all fields in Queue except for stats.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700955 x__xgafv: string, V1 error format.
956 Allowed values
957 1 - v1 error format
958 2 - v2 error format
959
960Returns:
961 An object of the form:
962
963 { # A queue is a container of related tasks. Queues are configured to manage
964 # how those tasks are dispatched. Configurable properties include rate limits,
965 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -0700966 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700967 #
968 # An App Engine queue is a queue that has an AppEngineHttpTarget.
969 #
970 # The task will be delivered to the App Engine application hostname
971 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
972 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -0700973 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700974 #
975 # Using AppEngineHttpTarget requires
976 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
977 # Google IAM permission for the project
978 # and the following scope:
979 #
980 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -0700981 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700982 # task-level app_engine_routing.
983 #
984 # If set, `app_engine_routing_override` is used for all tasks in
985 # the queue, no matter what the setting is for the
986 # task-level app_engine_routing.
987 #
988 # Defines routing characteristics specific to App Engine - service, version,
989 # and instance.
990 #
991 # For more information about services, versions, and instances see
992 # [An Overview of App
993 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
994 # [Microservices Architecture on Google App
995 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
996 # [App Engine Standard request
997 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
998 # and [App Engine Flex request
999 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07001000 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001001 #
1002 # By default, the task is sent to an instance which is available when
1003 # the task is attempted.
1004 #
1005 # Requests can only be sent to a specific instance if
1006 # [manual scaling is used in App Engine
1007 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
1008 # App Engine Flex does not support instances. For more information, see
1009 # [App Engine Standard request
1010 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
1011 # and [App Engine Flex request
1012 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07001013 &quot;version&quot;: &quot;A String&quot;, # App version.
1014 #
1015 # By default, the task is sent to the version which is the default
1016 # version when the task is attempted.
1017 #
1018 # For some queues or tasks which were created using the App Engine
1019 # Task Queue API, host is not parsable
1020 # into service,
1021 # version, and
1022 # instance. For example, some tasks
1023 # which were created using the App Engine SDK use a custom domain
1024 # name; custom domains are not parsed by Cloud Tasks. If
1025 # host is not parsable, then
1026 # service,
1027 # version, and
1028 # instance are the empty string.
1029 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001030 #
1031 # For more information, see
1032 # [How Requests are
1033 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
1034 #
1035 # The host is constructed as:
1036 #
1037 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001038 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -07001039 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1040 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1041 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1042 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1043 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1044 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1045 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001046 #
1047 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -07001048 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -07001049 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001050 # SDK use a custom domain name.
1051 #
1052 # * `service =` service
1053 #
1054 # * `version =` version
1055 #
1056 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07001057 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001058 # service
1059 #
1060 # * `instance =` instance
1061 #
1062 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07001063 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001064 # service
1065 #
1066 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -07001067 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001068 # version
1069 #
1070 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07001071 # instance `+ &#x27;.&#x27; +`
1072 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001073 # service
1074 #
1075 # If service is empty, then the task will be sent
1076 # to the service which is the default service when the task is attempted.
1077 #
1078 # If version is empty, then the task will be sent
1079 # to the version which is the default version when the task is attempted.
1080 #
1081 # If instance is empty, then the task
1082 # will be sent to an instance which is available when the task is
1083 # attempted.
1084 #
1085 # If service,
1086 # version, or
1087 # instance is invalid, then the task
1088 # will be sent to the default version of the default service when
1089 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -07001090 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001091 #
1092 # By default, the task is sent to the service which is the default
1093 # service when the task is attempted.
1094 #
1095 # For some queues or tasks which were created using the App Engine
1096 # Task Queue API, host is not parsable
1097 # into service,
1098 # version, and
1099 # instance. For example, some tasks
1100 # which were created using the App Engine SDK use a custom domain
1101 # name; custom domains are not parsed by Cloud Tasks. If
1102 # host is not parsable, then
1103 # service,
1104 # version, and
1105 # instance are the empty string.
1106 },
1107 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001108 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001109 #
1110 # All tasks that were created before this time
1111 # were purged.
1112 #
1113 # A queue can be purged using PurgeQueue, the
1114 # [App Engine Task Queue SDK, or the Cloud
1115 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
1116 #
1117 # Purge time will be truncated to the nearest microsecond. Purge
1118 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -07001119 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
1120 #
1121 # `state` can only be changed by called
1122 # PauseQueue,
1123 # ResumeQueue, or uploading
1124 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
1125 # UpdateQueue cannot be used to change `state`.
1126 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001127 #
1128 # * For tasks created using Cloud Tasks: the queue-level retry settings
1129 # apply to all tasks in the queue that were created using Cloud Tasks.
1130 # Retry settings cannot be set on individual tasks.
1131 # * For tasks created using the App Engine SDK: the queue-level retry
1132 # settings apply to all tasks in the queue which do not have retry settings
1133 # explicitly set on the task and were created by the App Engine SDK. See
1134 # [App Engine
1135 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
1136 #
1137 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -07001138 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
1139 # min_backoff and
1140 # max_backoff duration after it fails,
1141 # if the queue&#x27;s RetryConfig specifies that the task should be
1142 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001143 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001144 # If unspecified when the queue is created, Cloud Tasks will pick the
1145 # default.
1146 #
1147 # This field is output only for pull queues.
1148 #
1149 #
1150 # `min_backoff` will be truncated to the nearest second.
1151 #
1152 # This field has the same meaning as
1153 # [min_backoff_seconds in
1154 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1155 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
1156 # min_backoff and
1157 # max_backoff duration after it fails,
1158 # if the queue&#x27;s RetryConfig specifies that the task should be
1159 # retried.
1160 #
1161 # If unspecified when the queue is created, Cloud Tasks will pick the
1162 # default.
1163 #
1164 # This field is output only for pull queues.
1165 #
1166 #
1167 # `max_backoff` will be truncated to the nearest second.
1168 #
1169 # This field has the same meaning as
1170 # [max_backoff_seconds in
1171 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1172 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
1173 # retrying a failed task, measured from when the task was first
1174 # attempted. Once `max_retry_duration` time has passed *and* the
1175 # task has been attempted max_attempts
1176 # times, no further attempts will be made and the task will be
1177 # deleted.
1178 #
1179 # If zero, then the task age is unlimited.
1180 #
1181 # If unspecified when the queue is created, Cloud Tasks will pick the
1182 # default.
1183 #
1184 # This field is output only for pull queues.
1185 #
1186 #
1187 # `max_retry_duration` will be truncated to the nearest second.
1188 #
1189 # This field has the same meaning as
1190 # [task_age_limit in
1191 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1192 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
1193 #
1194 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001195 # min_backoff, then doubles
1196 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -07001197 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001198 # max_backoff up to
1199 # max_attempts times.
1200 #
1201 # For example, if min_backoff is 10s,
1202 # max_backoff is 300s, and
1203 # `max_doublings` is 3, then the a task will first be retried in
1204 # 10s. The retry interval will double three times, and then
1205 # increase linearly by 2^3 * 10s. Finally, the task will retry at
1206 # intervals of max_backoff until the
1207 # task has been attempted max_attempts
1208 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
1209 # 240s, 300s, 300s, ....
1210 #
1211 # If unspecified when the queue is created, Cloud Tasks will pick the
1212 # default.
1213 #
1214 # This field is output only for pull queues.
1215 #
1216 #
1217 # This field has the same meaning as
1218 # [max_doublings in
1219 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -07001220 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001221 #
1222 # Cloud Tasks will attempt the task `max_attempts` times (that
1223 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -07001224 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -07001225 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
1226 },
1227 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
1228 # after which it becomes output only.
1229 #
1230 # The queue name.
1231 #
1232 # The queue name must have the following format:
1233 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
1234 #
1235 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
1236 # hyphens (-), colons (:), or periods (.).
1237 # For more information, see
1238 # [Identifying
1239 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
1240 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
1241 # The list of available locations can be obtained by calling
1242 # ListLocations.
1243 # For more information, see https://cloud.google.com/about/locations/.
1244 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
1245 # hyphens (-). The maximum length is 100 characters.
1246 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
1247 #
1248 # rate_limits and
1249 # retry_config are related because they both
1250 # control task attempts however they control how tasks are
1251 # attempted in different ways:
1252 #
1253 # * rate_limits controls the total rate of
1254 # dispatches from a queue (i.e. all traffic dispatched from the
1255 # queue, regardless of whether the dispatch is from a first
1256 # attempt or a retry).
1257 # * retry_config controls what happens to
1258 # particular a task after its first attempt fails. That is,
1259 # retry_config controls task retries (the
1260 # second attempt, third attempt, etc).
1261 #
1262 # This message determines the maximum rate that tasks can be dispatched by a
1263 # queue, regardless of whether the dispatch is a first task attempt or a retry.
1264 #
1265 # Note: The debugging command, RunTask, will run a task
1266 # even if the queue has reached its RateLimits.
1267 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
1268 # to be dispatched for this queue. After this threshold has been
1269 # reached, Cloud Tasks stops dispatching tasks until the number of
1270 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001271 #
1272 # If unspecified when the queue is created, Cloud Tasks will pick the
1273 # default.
1274 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001275 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001276 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001277 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001278 # This field is output only for
1279 # pull queues and always -1, which indicates no limit. No other
1280 # queue types can have `max_concurrent_tasks` set to -1.
1281 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001282 #
1283 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07001284 # [max_concurrent_requests in
1285 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
1286 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001287 #
1288 # If unspecified when the queue is created, Cloud Tasks will pick the
1289 # default.
1290 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001291 # * For App Engine queues, the maximum allowed value
1292 # is 500.
1293 # * This field is output only for pull queues. In addition to the
1294 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
1295 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001296 #
1297 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001298 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07001299 # [rate in
1300 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
1301 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001302 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001303 # Max burst size limits how fast tasks in queue are processed when
1304 # many tasks are in the queue and the rate is high. This field
1305 # allows the queue to have a high rate so processing starts shortly
1306 # after a task is enqueued, but still limits resource usage when
1307 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001308 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001309 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
1310 # algorithm is used to control the rate of task dispatches. Each
1311 # queue has a token bucket that holds tokens, up to the maximum
1312 # specified by `max_burst_size`. Each time a task is dispatched, a
1313 # token is removed from the bucket. Tasks will be dispatched until
1314 # the queue&#x27;s bucket runs out of tokens. The bucket will be
1315 # continuously refilled with new tokens based on
1316 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001317 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001318 # Cloud Tasks will pick the value of `max_burst_size` based on the
1319 # value of
1320 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001321 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001322 # For App Engine queues that were created or updated using
1323 # `queue.yaml/xml`, `max_burst_size` is equal to
1324 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
1325 # Since `max_burst_size` is output only, if
1326 # UpdateQueue is called on a queue
1327 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
1328 # on the value of
1329 # max_tasks_dispatched_per_second,
1330 # regardless of whether
1331 # max_tasks_dispatched_per_second
1332 # is updated.
1333 },
1334 &quot;pullTarget&quot;: { # Pull target. # Pull target.
1335 #
1336 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001337 },
1338 }</pre>
1339</div>
1340
1341<div class="method">
1342 <code class="details" id="getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</code>
1343 <pre>Gets the access control policy for a Queue.
1344Returns an empty policy if the resource exists and does not have a policy
1345set.
1346
1347Authorization requires the following
1348[Google IAM](https://cloud.google.com/iam) permission on the specified
1349resource parent:
1350
1351* `cloudtasks.queues.getIamPolicy`
1352
1353Args:
1354 resource: string, REQUIRED: The resource for which the policy is being requested.
1355See the operation documentation for the appropriate value for this field. (required)
1356 body: object, The request body.
1357 The object takes the form of:
1358
1359{ # Request message for `GetIamPolicy` method.
Bu Sun Kim65020912020-05-20 12:08:20 -07001360 &quot;options&quot;: { # Encapsulates settings provided to GetIamPolicy. # OPTIONAL: A `GetPolicyOptions` object for specifying options to
Dan O'Mearadd494642020-05-01 07:42:23 -07001361 # `GetIamPolicy`.
Bu Sun Kim65020912020-05-20 12:08:20 -07001362 &quot;requestedPolicyVersion&quot;: 42, # Optional. The policy format version to be returned.
Dan O'Mearadd494642020-05-01 07:42:23 -07001363 #
1364 # Valid values are 0, 1, and 3. Requests specifying an invalid value will be
1365 # rejected.
1366 #
1367 # Requests for policies with any conditional bindings must specify version 3.
1368 # Policies without any conditional bindings may specify any valid value or
1369 # leave the field unset.
Bu Sun Kim65020912020-05-20 12:08:20 -07001370 #
1371 # To learn which resources support conditions in their IAM policies, see the
1372 # [IAM
1373 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -07001374 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001375 }
1376
1377 x__xgafv: string, V1 error format.
1378 Allowed values
1379 1 - v1 error format
1380 2 - v2 error format
1381
1382Returns:
1383 An object of the form:
1384
Dan O'Mearadd494642020-05-01 07:42:23 -07001385 { # An Identity and Access Management (IAM) policy, which specifies access
1386 # controls for Google Cloud resources.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001387 #
1388 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001389 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
1390 # `members` to a single `role`. Members can be user accounts, service accounts,
1391 # Google groups, and domains (such as G Suite). A `role` is a named list of
1392 # permissions; each `role` can be an IAM predefined role or a user-created
1393 # custom role.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001394 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001395 # For some types of Google Cloud resources, a `binding` can also specify a
1396 # `condition`, which is a logical expression that allows access to a resource
1397 # only if the expression evaluates to `true`. A condition can add constraints
1398 # based on attributes of the request, the resource, or both. To learn which
1399 # resources support conditions in their IAM policies, see the
1400 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -07001401 #
1402 # **JSON example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001403 #
1404 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07001405 # &quot;bindings&quot;: [
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001406 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07001407 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
1408 # &quot;members&quot;: [
1409 # &quot;user:mike@example.com&quot;,
1410 # &quot;group:admins@example.com&quot;,
1411 # &quot;domain:google.com&quot;,
1412 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001413 # ]
1414 # },
1415 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07001416 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
1417 # &quot;members&quot;: [
1418 # &quot;user:eve@example.com&quot;
1419 # ],
1420 # &quot;condition&quot;: {
1421 # &quot;title&quot;: &quot;expirable access&quot;,
1422 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
1423 # &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -07001424 # }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001425 # }
Dan O'Mearadd494642020-05-01 07:42:23 -07001426 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001427 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
1428 # &quot;version&quot;: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001429 # }
1430 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001431 # **YAML example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001432 #
1433 # bindings:
1434 # - members:
1435 # - user:mike@example.com
1436 # - group:admins@example.com
1437 # - domain:google.com
Dan O'Mearadd494642020-05-01 07:42:23 -07001438 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
1439 # role: roles/resourcemanager.organizationAdmin
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001440 # - members:
Dan O'Mearadd494642020-05-01 07:42:23 -07001441 # - user:eve@example.com
1442 # role: roles/resourcemanager.organizationViewer
1443 # condition:
1444 # title: expirable access
1445 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -07001446 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -07001447 # - etag: BwWWja0YfJA=
1448 # - version: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001449 #
1450 # For a description of IAM and its features, see the
Dan O'Mearadd494642020-05-01 07:42:23 -07001451 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim65020912020-05-20 12:08:20 -07001452 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
1453 # prevent simultaneous updates of a policy from overwriting each other.
1454 # It is strongly suggested that systems make use of the `etag` in the
1455 # read-modify-write cycle to perform policy updates in order to avoid race
1456 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
1457 # systems are expected to put that etag in the request to `setIamPolicy` to
1458 # ensure that their change will be applied to the same version of the policy.
1459 #
1460 # **Important:** If you use IAM Conditions, you must include the `etag` field
1461 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
1462 # you to overwrite a version `3` policy with a version `1` policy, and all of
1463 # the conditions in the version `3` policy are lost.
1464 &quot;version&quot;: 42, # Specifies the format of the policy.
1465 #
1466 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
1467 # are rejected.
1468 #
1469 # Any operation that affects conditional role bindings must specify version
1470 # `3`. This requirement applies to the following operations:
1471 #
1472 # * Getting a policy that includes a conditional role binding
1473 # * Adding a conditional role binding to a policy
1474 # * Changing a conditional role binding in a policy
1475 # * Removing any role binding, with or without a condition, from a policy
1476 # that includes conditions
1477 #
1478 # **Important:** If you use IAM Conditions, you must include the `etag` field
1479 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
1480 # you to overwrite a version `3` policy with a version `1` policy, and all of
1481 # the conditions in the version `3` policy are lost.
1482 #
1483 # If a policy does not include any conditions, operations on that policy may
1484 # specify any valid version or leave the field unset.
1485 #
1486 # To learn which resources support conditions in their IAM policies, see the
1487 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
1488 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -07001489 # `condition` that determines how and when the `bindings` are applied. Each
1490 # of the `bindings` must contain at least one member.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001491 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -07001492 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001493 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -07001494 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
1495 #
1496 # If the condition evaluates to `true`, then this binding applies to the
1497 # current request.
1498 #
1499 # If the condition evaluates to `false`, then this binding does not apply to
1500 # the current request. However, a different role binding might grant the same
1501 # role to one or more of the members in this binding.
1502 #
1503 # To learn which resources support conditions in their IAM policies, see the
1504 # [IAM
1505 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -07001506 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
1507 # are documented at https://github.com/google/cel-spec.
1508 #
1509 # Example (Comparison):
1510 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001511 # title: &quot;Summary size limit&quot;
1512 # description: &quot;Determines if a summary is less than 100 chars&quot;
1513 # expression: &quot;document.summary.size() &lt; 100&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07001514 #
1515 # Example (Equality):
1516 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001517 # title: &quot;Requestor is owner&quot;
1518 # description: &quot;Determines if requestor is the document owner&quot;
1519 # expression: &quot;document.owner == request.auth.claims.email&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07001520 #
1521 # Example (Logic):
1522 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001523 # title: &quot;Public documents&quot;
1524 # description: &quot;Determine whether the document should be publicly visible&quot;
1525 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07001526 #
1527 # Example (Data Manipulation):
1528 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001529 # title: &quot;Notification string&quot;
1530 # description: &quot;Create a notification string with a timestamp.&quot;
1531 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07001532 #
1533 # The exact variables and functions that may be referenced within an expression
1534 # are determined by the service that evaluates it. See the service
1535 # documentation for additional information.
Bu Sun Kim65020912020-05-20 12:08:20 -07001536 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
Dan O'Mearadd494642020-05-01 07:42:23 -07001537 # its purpose. This can be used e.g. in UIs which allow to enter the
1538 # expression.
Bu Sun Kim65020912020-05-20 12:08:20 -07001539 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
1540 # reporting, e.g. a file name and a position in the file.
1541 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
1542 # describes the expression, e.g. when hovered over it in a UI.
1543 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
1544 # syntax.
Dan O'Mearadd494642020-05-01 07:42:23 -07001545 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001546 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001547 # `members` can have the following values:
1548 #
1549 # * `allUsers`: A special identifier that represents anyone who is
1550 # on the internet; with or without a Google account.
1551 #
1552 # * `allAuthenticatedUsers`: A special identifier that represents anyone
1553 # who is authenticated with a Google account or a service account.
1554 #
1555 # * `user:{emailid}`: An email address that represents a specific Google
Dan O'Mearadd494642020-05-01 07:42:23 -07001556 # account. For example, `alice@example.com` .
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001557 #
1558 #
1559 # * `serviceAccount:{emailid}`: An email address that represents a service
1560 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
1561 #
1562 # * `group:{emailid}`: An email address that represents a Google group.
1563 # For example, `admins@example.com`.
1564 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001565 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
1566 # identifier) representing a user that has been recently deleted. For
1567 # example, `alice@example.com?uid=123456789012345678901`. If the user is
1568 # recovered, this value reverts to `user:{emailid}` and the recovered user
1569 # retains the role in the binding.
1570 #
1571 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
1572 # unique identifier) representing a service account that has been recently
1573 # deleted. For example,
1574 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
1575 # If the service account is undeleted, this value reverts to
1576 # `serviceAccount:{emailid}` and the undeleted service account retains the
1577 # role in the binding.
1578 #
1579 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
1580 # identifier) representing a Google group that has been recently
1581 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
1582 # the group is recovered, this value reverts to `group:{emailid}` and the
1583 # recovered group retains the role in the binding.
1584 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001585 #
1586 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
1587 # users of that domain. For example, `google.com` or `example.com`.
1588 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001589 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001590 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001591 },
1592 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001593 }</pre>
1594</div>
1595
1596<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -07001597 <code class="details" id="list">list(parent, filter=None, pageToken=None, pageSize=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001598 <pre>Lists queues.
1599
1600Queues are returned in lexicographical order.
1601
1602Args:
Dan O'Mearadd494642020-05-01 07:42:23 -07001603 parent: string, Required. The location name.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001604For example: `projects/PROJECT_ID/locations/LOCATION_ID` (required)
Bu Sun Kim65020912020-05-20 12:08:20 -07001605 filter: string, `filter` can be used to specify a subset of queues. Any Queue
1606field can be used as a filter and several operators as supported.
1607For example: `&lt;=, &lt;, &gt;=, &gt;, !=, =, :`. The filter syntax is the same as
1608described in
1609[Stackdriver&#x27;s Advanced Logs
1610Filters](https://cloud.google.com/logging/docs/view/advanced_filters).
1611
1612Sample filter &quot;app_engine_http_target: *&quot;.
1613
1614Note that using filters might cause fewer queues than the
1615requested_page size to be returned.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001616 pageToken: string, A token identifying the page of results to return.
1617
1618To request the first page results, page_token must be empty. To
1619request the next page of results, page_token must be the value of
1620next_page_token returned
1621from the previous call to ListQueues
1622method. It is an error to switch the value of the
1623filter while iterating through pages.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001624 pageSize: integer, Requested page size.
1625
1626The maximum page size is 9800. If unspecified, the page size will
1627be the maximum. Fewer queues than requested might be returned,
1628even if more queues exist; use the
1629next_page_token in the
1630response to determine if more queues exist.
Bu Sun Kim65020912020-05-20 12:08:20 -07001631 x__xgafv: string, V1 error format.
1632 Allowed values
1633 1 - v1 error format
1634 2 - v2 error format
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001635
1636Returns:
1637 An object of the form:
1638
1639 { # Response message for ListQueues.
Bu Sun Kim65020912020-05-20 12:08:20 -07001640 &quot;queues&quot;: [ # The list of queues.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001641 { # A queue is a container of related tasks. Queues are configured to manage
1642 # how those tasks are dispatched. Configurable properties include rate limits,
1643 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -07001644 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001645 #
1646 # An App Engine queue is a queue that has an AppEngineHttpTarget.
1647 #
1648 # The task will be delivered to the App Engine application hostname
1649 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
1650 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -07001651 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001652 #
1653 # Using AppEngineHttpTarget requires
1654 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
1655 # Google IAM permission for the project
1656 # and the following scope:
1657 #
1658 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -07001659 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001660 # task-level app_engine_routing.
1661 #
1662 # If set, `app_engine_routing_override` is used for all tasks in
1663 # the queue, no matter what the setting is for the
1664 # task-level app_engine_routing.
1665 #
1666 # Defines routing characteristics specific to App Engine - service, version,
1667 # and instance.
1668 #
1669 # For more information about services, versions, and instances see
1670 # [An Overview of App
1671 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
1672 # [Microservices Architecture on Google App
1673 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
1674 # [App Engine Standard request
1675 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
1676 # and [App Engine Flex request
1677 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07001678 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001679 #
1680 # By default, the task is sent to an instance which is available when
1681 # the task is attempted.
1682 #
1683 # Requests can only be sent to a specific instance if
1684 # [manual scaling is used in App Engine
1685 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
1686 # App Engine Flex does not support instances. For more information, see
1687 # [App Engine Standard request
1688 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
1689 # and [App Engine Flex request
1690 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07001691 &quot;version&quot;: &quot;A String&quot;, # App version.
1692 #
1693 # By default, the task is sent to the version which is the default
1694 # version when the task is attempted.
1695 #
1696 # For some queues or tasks which were created using the App Engine
1697 # Task Queue API, host is not parsable
1698 # into service,
1699 # version, and
1700 # instance. For example, some tasks
1701 # which were created using the App Engine SDK use a custom domain
1702 # name; custom domains are not parsed by Cloud Tasks. If
1703 # host is not parsable, then
1704 # service,
1705 # version, and
1706 # instance are the empty string.
1707 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001708 #
1709 # For more information, see
1710 # [How Requests are
1711 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
1712 #
1713 # The host is constructed as:
1714 #
1715 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001716 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -07001717 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1718 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1719 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1720 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1721 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1722 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
1723 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001724 #
1725 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -07001726 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -07001727 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001728 # SDK use a custom domain name.
1729 #
1730 # * `service =` service
1731 #
1732 # * `version =` version
1733 #
1734 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07001735 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001736 # service
1737 #
1738 # * `instance =` instance
1739 #
1740 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07001741 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001742 # service
1743 #
1744 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -07001745 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001746 # version
1747 #
1748 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07001749 # instance `+ &#x27;.&#x27; +`
1750 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001751 # service
1752 #
1753 # If service is empty, then the task will be sent
1754 # to the service which is the default service when the task is attempted.
1755 #
1756 # If version is empty, then the task will be sent
1757 # to the version which is the default version when the task is attempted.
1758 #
1759 # If instance is empty, then the task
1760 # will be sent to an instance which is available when the task is
1761 # attempted.
1762 #
1763 # If service,
1764 # version, or
1765 # instance is invalid, then the task
1766 # will be sent to the default version of the default service when
1767 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -07001768 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001769 #
1770 # By default, the task is sent to the service which is the default
1771 # service when the task is attempted.
1772 #
1773 # For some queues or tasks which were created using the App Engine
1774 # Task Queue API, host is not parsable
1775 # into service,
1776 # version, and
1777 # instance. For example, some tasks
1778 # which were created using the App Engine SDK use a custom domain
1779 # name; custom domains are not parsed by Cloud Tasks. If
1780 # host is not parsable, then
1781 # service,
1782 # version, and
1783 # instance are the empty string.
1784 },
1785 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001786 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001787 #
1788 # All tasks that were created before this time
1789 # were purged.
1790 #
1791 # A queue can be purged using PurgeQueue, the
1792 # [App Engine Task Queue SDK, or the Cloud
1793 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
1794 #
1795 # Purge time will be truncated to the nearest microsecond. Purge
1796 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -07001797 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
1798 #
1799 # `state` can only be changed by called
1800 # PauseQueue,
1801 # ResumeQueue, or uploading
1802 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
1803 # UpdateQueue cannot be used to change `state`.
1804 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001805 #
1806 # * For tasks created using Cloud Tasks: the queue-level retry settings
1807 # apply to all tasks in the queue that were created using Cloud Tasks.
1808 # Retry settings cannot be set on individual tasks.
1809 # * For tasks created using the App Engine SDK: the queue-level retry
1810 # settings apply to all tasks in the queue which do not have retry settings
1811 # explicitly set on the task and were created by the App Engine SDK. See
1812 # [App Engine
1813 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
1814 #
1815 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -07001816 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
1817 # min_backoff and
1818 # max_backoff duration after it fails,
1819 # if the queue&#x27;s RetryConfig specifies that the task should be
1820 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001821 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001822 # If unspecified when the queue is created, Cloud Tasks will pick the
1823 # default.
1824 #
1825 # This field is output only for pull queues.
1826 #
1827 #
1828 # `min_backoff` will be truncated to the nearest second.
1829 #
1830 # This field has the same meaning as
1831 # [min_backoff_seconds in
1832 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1833 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
1834 # min_backoff and
1835 # max_backoff duration after it fails,
1836 # if the queue&#x27;s RetryConfig specifies that the task should be
1837 # retried.
1838 #
1839 # If unspecified when the queue is created, Cloud Tasks will pick the
1840 # default.
1841 #
1842 # This field is output only for pull queues.
1843 #
1844 #
1845 # `max_backoff` will be truncated to the nearest second.
1846 #
1847 # This field has the same meaning as
1848 # [max_backoff_seconds in
1849 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1850 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
1851 # retrying a failed task, measured from when the task was first
1852 # attempted. Once `max_retry_duration` time has passed *and* the
1853 # task has been attempted max_attempts
1854 # times, no further attempts will be made and the task will be
1855 # deleted.
1856 #
1857 # If zero, then the task age is unlimited.
1858 #
1859 # If unspecified when the queue is created, Cloud Tasks will pick the
1860 # default.
1861 #
1862 # This field is output only for pull queues.
1863 #
1864 #
1865 # `max_retry_duration` will be truncated to the nearest second.
1866 #
1867 # This field has the same meaning as
1868 # [task_age_limit in
1869 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1870 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
1871 #
1872 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001873 # min_backoff, then doubles
1874 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -07001875 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001876 # max_backoff up to
1877 # max_attempts times.
1878 #
1879 # For example, if min_backoff is 10s,
1880 # max_backoff is 300s, and
1881 # `max_doublings` is 3, then the a task will first be retried in
1882 # 10s. The retry interval will double three times, and then
1883 # increase linearly by 2^3 * 10s. Finally, the task will retry at
1884 # intervals of max_backoff until the
1885 # task has been attempted max_attempts
1886 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
1887 # 240s, 300s, 300s, ....
1888 #
1889 # If unspecified when the queue is created, Cloud Tasks will pick the
1890 # default.
1891 #
1892 # This field is output only for pull queues.
1893 #
1894 #
1895 # This field has the same meaning as
1896 # [max_doublings in
1897 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -07001898 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001899 #
1900 # Cloud Tasks will attempt the task `max_attempts` times (that
1901 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -07001902 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -07001903 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
1904 },
1905 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
1906 # after which it becomes output only.
1907 #
1908 # The queue name.
1909 #
1910 # The queue name must have the following format:
1911 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
1912 #
1913 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
1914 # hyphens (-), colons (:), or periods (.).
1915 # For more information, see
1916 # [Identifying
1917 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
1918 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
1919 # The list of available locations can be obtained by calling
1920 # ListLocations.
1921 # For more information, see https://cloud.google.com/about/locations/.
1922 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
1923 # hyphens (-). The maximum length is 100 characters.
1924 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
1925 #
1926 # rate_limits and
1927 # retry_config are related because they both
1928 # control task attempts however they control how tasks are
1929 # attempted in different ways:
1930 #
1931 # * rate_limits controls the total rate of
1932 # dispatches from a queue (i.e. all traffic dispatched from the
1933 # queue, regardless of whether the dispatch is from a first
1934 # attempt or a retry).
1935 # * retry_config controls what happens to
1936 # particular a task after its first attempt fails. That is,
1937 # retry_config controls task retries (the
1938 # second attempt, third attempt, etc).
1939 #
1940 # This message determines the maximum rate that tasks can be dispatched by a
1941 # queue, regardless of whether the dispatch is a first task attempt or a retry.
1942 #
1943 # Note: The debugging command, RunTask, will run a task
1944 # even if the queue has reached its RateLimits.
1945 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
1946 # to be dispatched for this queue. After this threshold has been
1947 # reached, Cloud Tasks stops dispatching tasks until the number of
1948 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001949 #
1950 # If unspecified when the queue is created, Cloud Tasks will pick the
1951 # default.
1952 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001953 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001954 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001955 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001956 # This field is output only for
1957 # pull queues and always -1, which indicates no limit. No other
1958 # queue types can have `max_concurrent_tasks` set to -1.
1959 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001960 #
1961 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07001962 # [max_concurrent_requests in
1963 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
1964 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001965 #
1966 # If unspecified when the queue is created, Cloud Tasks will pick the
1967 # default.
1968 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001969 # * For App Engine queues, the maximum allowed value
1970 # is 500.
1971 # * This field is output only for pull queues. In addition to the
1972 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
1973 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001974 #
1975 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001976 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07001977 # [rate in
1978 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
1979 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001980 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001981 # Max burst size limits how fast tasks in queue are processed when
1982 # many tasks are in the queue and the rate is high. This field
1983 # allows the queue to have a high rate so processing starts shortly
1984 # after a task is enqueued, but still limits resource usage when
1985 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001986 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001987 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
1988 # algorithm is used to control the rate of task dispatches. Each
1989 # queue has a token bucket that holds tokens, up to the maximum
1990 # specified by `max_burst_size`. Each time a task is dispatched, a
1991 # token is removed from the bucket. Tasks will be dispatched until
1992 # the queue&#x27;s bucket runs out of tokens. The bucket will be
1993 # continuously refilled with new tokens based on
1994 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001995 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001996 # Cloud Tasks will pick the value of `max_burst_size` based on the
1997 # value of
1998 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001999 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002000 # For App Engine queues that were created or updated using
2001 # `queue.yaml/xml`, `max_burst_size` is equal to
2002 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
2003 # Since `max_burst_size` is output only, if
2004 # UpdateQueue is called on a queue
2005 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
2006 # on the value of
2007 # max_tasks_dispatched_per_second,
2008 # regardless of whether
2009 # max_tasks_dispatched_per_second
2010 # is updated.
2011 },
2012 &quot;pullTarget&quot;: { # Pull target. # Pull target.
2013 #
2014 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002015 },
2016 },
2017 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002018 &quot;nextPageToken&quot;: &quot;A String&quot;, # A token to retrieve next page of results.
2019 #
2020 # To return the next page of results, call
2021 # ListQueues with this value as the
2022 # page_token.
2023 #
2024 # If the next_page_token is empty, there are no more results.
2025 #
2026 # The page token is valid for only 2 hours.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002027 }</pre>
2028</div>
2029
2030<div class="method">
2031 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
2032 <pre>Retrieves the next page of results.
2033
2034Args:
2035 previous_request: The request for the previous page. (required)
2036 previous_response: The response from the request for the previous page. (required)
2037
2038Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -07002039 A request object that you can call &#x27;execute()&#x27; on to request the next
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002040 page. Returns None if there are no more items in the collection.
2041 </pre>
2042</div>
2043
2044<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07002045 <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002046 <pre>Updates a queue.
2047
2048This method creates the queue if it does not exist and updates
2049the queue if it does exist.
2050
2051Queues created with this method allow tasks to live for a maximum of 31
2052days. After a task is 31 days old, the task will be deleted regardless of whether
2053it was dispatched or not.
2054
2055WARNING: Using this method may have unintended side effects if you are
2056using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
2057Read
2058[Overview of Queue Management and
2059queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
2060this method.
2061
2062Args:
2063 name: string, Caller-specified and required in CreateQueue,
2064after which it becomes output only.
2065
2066The queue name.
2067
2068The queue name must have the following format:
2069`projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
2070
2071* `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
2072 hyphens (-), colons (:), or periods (.).
2073 For more information, see
2074 [Identifying
2075 projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
Bu Sun Kim65020912020-05-20 12:08:20 -07002076* `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002077 The list of available locations can be obtained by calling
2078 ListLocations.
2079 For more information, see https://cloud.google.com/about/locations/.
2080* `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
2081 hyphens (-). The maximum length is 100 characters. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002082 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002083 The object takes the form of:
2084
2085{ # A queue is a container of related tasks. Queues are configured to manage
2086 # how those tasks are dispatched. Configurable properties include rate limits,
2087 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -07002088 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002089 #
2090 # An App Engine queue is a queue that has an AppEngineHttpTarget.
2091 #
2092 # The task will be delivered to the App Engine application hostname
2093 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
2094 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -07002095 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002096 #
2097 # Using AppEngineHttpTarget requires
2098 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
2099 # Google IAM permission for the project
2100 # and the following scope:
2101 #
2102 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -07002103 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002104 # task-level app_engine_routing.
2105 #
2106 # If set, `app_engine_routing_override` is used for all tasks in
2107 # the queue, no matter what the setting is for the
2108 # task-level app_engine_routing.
2109 #
2110 # Defines routing characteristics specific to App Engine - service, version,
2111 # and instance.
2112 #
2113 # For more information about services, versions, and instances see
2114 # [An Overview of App
2115 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
2116 # [Microservices Architecture on Google App
2117 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
2118 # [App Engine Standard request
2119 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
2120 # and [App Engine Flex request
2121 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07002122 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002123 #
2124 # By default, the task is sent to an instance which is available when
2125 # the task is attempted.
2126 #
2127 # Requests can only be sent to a specific instance if
2128 # [manual scaling is used in App Engine
2129 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
2130 # App Engine Flex does not support instances. For more information, see
2131 # [App Engine Standard request
2132 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
2133 # and [App Engine Flex request
2134 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07002135 &quot;version&quot;: &quot;A String&quot;, # App version.
2136 #
2137 # By default, the task is sent to the version which is the default
2138 # version when the task is attempted.
2139 #
2140 # For some queues or tasks which were created using the App Engine
2141 # Task Queue API, host is not parsable
2142 # into service,
2143 # version, and
2144 # instance. For example, some tasks
2145 # which were created using the App Engine SDK use a custom domain
2146 # name; custom domains are not parsed by Cloud Tasks. If
2147 # host is not parsable, then
2148 # service,
2149 # version, and
2150 # instance are the empty string.
2151 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002152 #
2153 # For more information, see
2154 # [How Requests are
2155 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
2156 #
2157 # The host is constructed as:
2158 #
2159 #
Dan O'Mearadd494642020-05-01 07:42:23 -07002160 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -07002161 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2162 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2163 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2164 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2165 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2166 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2167 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002168 #
2169 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -07002170 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -07002171 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002172 # SDK use a custom domain name.
2173 #
2174 # * `service =` service
2175 #
2176 # * `version =` version
2177 #
2178 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002179 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002180 # service
2181 #
2182 # * `instance =` instance
2183 #
2184 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002185 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002186 # service
2187 #
2188 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002189 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002190 # version
2191 #
2192 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002193 # instance `+ &#x27;.&#x27; +`
2194 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002195 # service
2196 #
2197 # If service is empty, then the task will be sent
2198 # to the service which is the default service when the task is attempted.
2199 #
2200 # If version is empty, then the task will be sent
2201 # to the version which is the default version when the task is attempted.
2202 #
2203 # If instance is empty, then the task
2204 # will be sent to an instance which is available when the task is
2205 # attempted.
2206 #
2207 # If service,
2208 # version, or
2209 # instance is invalid, then the task
2210 # will be sent to the default version of the default service when
2211 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -07002212 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002213 #
2214 # By default, the task is sent to the service which is the default
2215 # service when the task is attempted.
2216 #
2217 # For some queues or tasks which were created using the App Engine
2218 # Task Queue API, host is not parsable
2219 # into service,
2220 # version, and
2221 # instance. For example, some tasks
2222 # which were created using the App Engine SDK use a custom domain
2223 # name; custom domains are not parsed by Cloud Tasks. If
2224 # host is not parsable, then
2225 # service,
2226 # version, and
2227 # instance are the empty string.
2228 },
2229 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002230 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002231 #
2232 # All tasks that were created before this time
2233 # were purged.
2234 #
2235 # A queue can be purged using PurgeQueue, the
2236 # [App Engine Task Queue SDK, or the Cloud
2237 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
2238 #
2239 # Purge time will be truncated to the nearest microsecond. Purge
2240 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -07002241 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
2242 #
2243 # `state` can only be changed by called
2244 # PauseQueue,
2245 # ResumeQueue, or uploading
2246 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
2247 # UpdateQueue cannot be used to change `state`.
2248 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002249 #
2250 # * For tasks created using Cloud Tasks: the queue-level retry settings
2251 # apply to all tasks in the queue that were created using Cloud Tasks.
2252 # Retry settings cannot be set on individual tasks.
2253 # * For tasks created using the App Engine SDK: the queue-level retry
2254 # settings apply to all tasks in the queue which do not have retry settings
2255 # explicitly set on the task and were created by the App Engine SDK. See
2256 # [App Engine
2257 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
2258 #
2259 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -07002260 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
2261 # min_backoff and
2262 # max_backoff duration after it fails,
2263 # if the queue&#x27;s RetryConfig specifies that the task should be
2264 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002265 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002266 # If unspecified when the queue is created, Cloud Tasks will pick the
2267 # default.
2268 #
2269 # This field is output only for pull queues.
2270 #
2271 #
2272 # `min_backoff` will be truncated to the nearest second.
2273 #
2274 # This field has the same meaning as
2275 # [min_backoff_seconds in
2276 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2277 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
2278 # min_backoff and
2279 # max_backoff duration after it fails,
2280 # if the queue&#x27;s RetryConfig specifies that the task should be
2281 # retried.
2282 #
2283 # If unspecified when the queue is created, Cloud Tasks will pick the
2284 # default.
2285 #
2286 # This field is output only for pull queues.
2287 #
2288 #
2289 # `max_backoff` will be truncated to the nearest second.
2290 #
2291 # This field has the same meaning as
2292 # [max_backoff_seconds in
2293 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2294 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
2295 # retrying a failed task, measured from when the task was first
2296 # attempted. Once `max_retry_duration` time has passed *and* the
2297 # task has been attempted max_attempts
2298 # times, no further attempts will be made and the task will be
2299 # deleted.
2300 #
2301 # If zero, then the task age is unlimited.
2302 #
2303 # If unspecified when the queue is created, Cloud Tasks will pick the
2304 # default.
2305 #
2306 # This field is output only for pull queues.
2307 #
2308 #
2309 # `max_retry_duration` will be truncated to the nearest second.
2310 #
2311 # This field has the same meaning as
2312 # [task_age_limit in
2313 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2314 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
2315 #
2316 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002317 # min_backoff, then doubles
2318 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -07002319 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002320 # max_backoff up to
2321 # max_attempts times.
2322 #
2323 # For example, if min_backoff is 10s,
2324 # max_backoff is 300s, and
2325 # `max_doublings` is 3, then the a task will first be retried in
2326 # 10s. The retry interval will double three times, and then
2327 # increase linearly by 2^3 * 10s. Finally, the task will retry at
2328 # intervals of max_backoff until the
2329 # task has been attempted max_attempts
2330 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
2331 # 240s, 300s, 300s, ....
2332 #
2333 # If unspecified when the queue is created, Cloud Tasks will pick the
2334 # default.
2335 #
2336 # This field is output only for pull queues.
2337 #
2338 #
2339 # This field has the same meaning as
2340 # [max_doublings in
2341 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -07002342 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002343 #
2344 # Cloud Tasks will attempt the task `max_attempts` times (that
2345 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -07002346 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -07002347 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
2348 },
2349 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
2350 # after which it becomes output only.
2351 #
2352 # The queue name.
2353 #
2354 # The queue name must have the following format:
2355 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
2356 #
2357 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
2358 # hyphens (-), colons (:), or periods (.).
2359 # For more information, see
2360 # [Identifying
2361 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
2362 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
2363 # The list of available locations can be obtained by calling
2364 # ListLocations.
2365 # For more information, see https://cloud.google.com/about/locations/.
2366 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
2367 # hyphens (-). The maximum length is 100 characters.
2368 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
2369 #
2370 # rate_limits and
2371 # retry_config are related because they both
2372 # control task attempts however they control how tasks are
2373 # attempted in different ways:
2374 #
2375 # * rate_limits controls the total rate of
2376 # dispatches from a queue (i.e. all traffic dispatched from the
2377 # queue, regardless of whether the dispatch is from a first
2378 # attempt or a retry).
2379 # * retry_config controls what happens to
2380 # particular a task after its first attempt fails. That is,
2381 # retry_config controls task retries (the
2382 # second attempt, third attempt, etc).
2383 #
2384 # This message determines the maximum rate that tasks can be dispatched by a
2385 # queue, regardless of whether the dispatch is a first task attempt or a retry.
2386 #
2387 # Note: The debugging command, RunTask, will run a task
2388 # even if the queue has reached its RateLimits.
2389 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
2390 # to be dispatched for this queue. After this threshold has been
2391 # reached, Cloud Tasks stops dispatching tasks until the number of
2392 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002393 #
2394 # If unspecified when the queue is created, Cloud Tasks will pick the
2395 # default.
2396 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002397 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002398 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002399 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002400 # This field is output only for
2401 # pull queues and always -1, which indicates no limit. No other
2402 # queue types can have `max_concurrent_tasks` set to -1.
2403 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002404 #
2405 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07002406 # [max_concurrent_requests in
2407 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
2408 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002409 #
2410 # If unspecified when the queue is created, Cloud Tasks will pick the
2411 # default.
2412 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002413 # * For App Engine queues, the maximum allowed value
2414 # is 500.
2415 # * This field is output only for pull queues. In addition to the
2416 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
2417 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002418 #
2419 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002420 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07002421 # [rate in
2422 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
2423 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002424 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002425 # Max burst size limits how fast tasks in queue are processed when
2426 # many tasks are in the queue and the rate is high. This field
2427 # allows the queue to have a high rate so processing starts shortly
2428 # after a task is enqueued, but still limits resource usage when
2429 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002430 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002431 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
2432 # algorithm is used to control the rate of task dispatches. Each
2433 # queue has a token bucket that holds tokens, up to the maximum
2434 # specified by `max_burst_size`. Each time a task is dispatched, a
2435 # token is removed from the bucket. Tasks will be dispatched until
2436 # the queue&#x27;s bucket runs out of tokens. The bucket will be
2437 # continuously refilled with new tokens based on
2438 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002439 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002440 # Cloud Tasks will pick the value of `max_burst_size` based on the
2441 # value of
2442 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002443 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002444 # For App Engine queues that were created or updated using
2445 # `queue.yaml/xml`, `max_burst_size` is equal to
2446 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
2447 # Since `max_burst_size` is output only, if
2448 # UpdateQueue is called on a queue
2449 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
2450 # on the value of
2451 # max_tasks_dispatched_per_second,
2452 # regardless of whether
2453 # max_tasks_dispatched_per_second
2454 # is updated.
2455 },
2456 &quot;pullTarget&quot;: { # Pull target. # Pull target.
2457 #
2458 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002459 },
2460}
2461
2462 updateMask: string, A mask used to specify which fields of the queue are being updated.
2463
2464If empty, then all fields will be updated.
2465 x__xgafv: string, V1 error format.
2466 Allowed values
2467 1 - v1 error format
2468 2 - v2 error format
2469
2470Returns:
2471 An object of the form:
2472
2473 { # A queue is a container of related tasks. Queues are configured to manage
2474 # how those tasks are dispatched. Configurable properties include rate limits,
2475 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -07002476 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002477 #
2478 # An App Engine queue is a queue that has an AppEngineHttpTarget.
2479 #
2480 # The task will be delivered to the App Engine application hostname
2481 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
2482 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -07002483 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002484 #
2485 # Using AppEngineHttpTarget requires
2486 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
2487 # Google IAM permission for the project
2488 # and the following scope:
2489 #
2490 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -07002491 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002492 # task-level app_engine_routing.
2493 #
2494 # If set, `app_engine_routing_override` is used for all tasks in
2495 # the queue, no matter what the setting is for the
2496 # task-level app_engine_routing.
2497 #
2498 # Defines routing characteristics specific to App Engine - service, version,
2499 # and instance.
2500 #
2501 # For more information about services, versions, and instances see
2502 # [An Overview of App
2503 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
2504 # [Microservices Architecture on Google App
2505 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
2506 # [App Engine Standard request
2507 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
2508 # and [App Engine Flex request
2509 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07002510 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002511 #
2512 # By default, the task is sent to an instance which is available when
2513 # the task is attempted.
2514 #
2515 # Requests can only be sent to a specific instance if
2516 # [manual scaling is used in App Engine
2517 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
2518 # App Engine Flex does not support instances. For more information, see
2519 # [App Engine Standard request
2520 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
2521 # and [App Engine Flex request
2522 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07002523 &quot;version&quot;: &quot;A String&quot;, # App version.
2524 #
2525 # By default, the task is sent to the version which is the default
2526 # version when the task is attempted.
2527 #
2528 # For some queues or tasks which were created using the App Engine
2529 # Task Queue API, host is not parsable
2530 # into service,
2531 # version, and
2532 # instance. For example, some tasks
2533 # which were created using the App Engine SDK use a custom domain
2534 # name; custom domains are not parsed by Cloud Tasks. If
2535 # host is not parsable, then
2536 # service,
2537 # version, and
2538 # instance are the empty string.
2539 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002540 #
2541 # For more information, see
2542 # [How Requests are
2543 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
2544 #
2545 # The host is constructed as:
2546 #
2547 #
Dan O'Mearadd494642020-05-01 07:42:23 -07002548 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -07002549 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2550 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2551 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2552 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2553 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2554 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2555 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002556 #
2557 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -07002558 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -07002559 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002560 # SDK use a custom domain name.
2561 #
2562 # * `service =` service
2563 #
2564 # * `version =` version
2565 #
2566 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002567 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002568 # service
2569 #
2570 # * `instance =` instance
2571 #
2572 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002573 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002574 # service
2575 #
2576 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002577 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002578 # version
2579 #
2580 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002581 # instance `+ &#x27;.&#x27; +`
2582 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002583 # service
2584 #
2585 # If service is empty, then the task will be sent
2586 # to the service which is the default service when the task is attempted.
2587 #
2588 # If version is empty, then the task will be sent
2589 # to the version which is the default version when the task is attempted.
2590 #
2591 # If instance is empty, then the task
2592 # will be sent to an instance which is available when the task is
2593 # attempted.
2594 #
2595 # If service,
2596 # version, or
2597 # instance is invalid, then the task
2598 # will be sent to the default version of the default service when
2599 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -07002600 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002601 #
2602 # By default, the task is sent to the service which is the default
2603 # service when the task is attempted.
2604 #
2605 # For some queues or tasks which were created using the App Engine
2606 # Task Queue API, host is not parsable
2607 # into service,
2608 # version, and
2609 # instance. For example, some tasks
2610 # which were created using the App Engine SDK use a custom domain
2611 # name; custom domains are not parsed by Cloud Tasks. If
2612 # host is not parsable, then
2613 # service,
2614 # version, and
2615 # instance are the empty string.
2616 },
2617 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002618 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002619 #
2620 # All tasks that were created before this time
2621 # were purged.
2622 #
2623 # A queue can be purged using PurgeQueue, the
2624 # [App Engine Task Queue SDK, or the Cloud
2625 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
2626 #
2627 # Purge time will be truncated to the nearest microsecond. Purge
2628 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -07002629 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
2630 #
2631 # `state` can only be changed by called
2632 # PauseQueue,
2633 # ResumeQueue, or uploading
2634 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
2635 # UpdateQueue cannot be used to change `state`.
2636 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002637 #
2638 # * For tasks created using Cloud Tasks: the queue-level retry settings
2639 # apply to all tasks in the queue that were created using Cloud Tasks.
2640 # Retry settings cannot be set on individual tasks.
2641 # * For tasks created using the App Engine SDK: the queue-level retry
2642 # settings apply to all tasks in the queue which do not have retry settings
2643 # explicitly set on the task and were created by the App Engine SDK. See
2644 # [App Engine
2645 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
2646 #
2647 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -07002648 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
2649 # min_backoff and
2650 # max_backoff duration after it fails,
2651 # if the queue&#x27;s RetryConfig specifies that the task should be
2652 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002653 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002654 # If unspecified when the queue is created, Cloud Tasks will pick the
2655 # default.
2656 #
2657 # This field is output only for pull queues.
2658 #
2659 #
2660 # `min_backoff` will be truncated to the nearest second.
2661 #
2662 # This field has the same meaning as
2663 # [min_backoff_seconds in
2664 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2665 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
2666 # min_backoff and
2667 # max_backoff duration after it fails,
2668 # if the queue&#x27;s RetryConfig specifies that the task should be
2669 # retried.
2670 #
2671 # If unspecified when the queue is created, Cloud Tasks will pick the
2672 # default.
2673 #
2674 # This field is output only for pull queues.
2675 #
2676 #
2677 # `max_backoff` will be truncated to the nearest second.
2678 #
2679 # This field has the same meaning as
2680 # [max_backoff_seconds in
2681 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2682 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
2683 # retrying a failed task, measured from when the task was first
2684 # attempted. Once `max_retry_duration` time has passed *and* the
2685 # task has been attempted max_attempts
2686 # times, no further attempts will be made and the task will be
2687 # deleted.
2688 #
2689 # If zero, then the task age is unlimited.
2690 #
2691 # If unspecified when the queue is created, Cloud Tasks will pick the
2692 # default.
2693 #
2694 # This field is output only for pull queues.
2695 #
2696 #
2697 # `max_retry_duration` will be truncated to the nearest second.
2698 #
2699 # This field has the same meaning as
2700 # [task_age_limit in
2701 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2702 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
2703 #
2704 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002705 # min_backoff, then doubles
2706 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -07002707 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002708 # max_backoff up to
2709 # max_attempts times.
2710 #
2711 # For example, if min_backoff is 10s,
2712 # max_backoff is 300s, and
2713 # `max_doublings` is 3, then the a task will first be retried in
2714 # 10s. The retry interval will double three times, and then
2715 # increase linearly by 2^3 * 10s. Finally, the task will retry at
2716 # intervals of max_backoff until the
2717 # task has been attempted max_attempts
2718 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
2719 # 240s, 300s, 300s, ....
2720 #
2721 # If unspecified when the queue is created, Cloud Tasks will pick the
2722 # default.
2723 #
2724 # This field is output only for pull queues.
2725 #
2726 #
2727 # This field has the same meaning as
2728 # [max_doublings in
2729 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -07002730 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002731 #
2732 # Cloud Tasks will attempt the task `max_attempts` times (that
2733 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -07002734 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -07002735 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
2736 },
2737 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
2738 # after which it becomes output only.
2739 #
2740 # The queue name.
2741 #
2742 # The queue name must have the following format:
2743 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
2744 #
2745 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
2746 # hyphens (-), colons (:), or periods (.).
2747 # For more information, see
2748 # [Identifying
2749 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
2750 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
2751 # The list of available locations can be obtained by calling
2752 # ListLocations.
2753 # For more information, see https://cloud.google.com/about/locations/.
2754 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
2755 # hyphens (-). The maximum length is 100 characters.
2756 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
2757 #
2758 # rate_limits and
2759 # retry_config are related because they both
2760 # control task attempts however they control how tasks are
2761 # attempted in different ways:
2762 #
2763 # * rate_limits controls the total rate of
2764 # dispatches from a queue (i.e. all traffic dispatched from the
2765 # queue, regardless of whether the dispatch is from a first
2766 # attempt or a retry).
2767 # * retry_config controls what happens to
2768 # particular a task after its first attempt fails. That is,
2769 # retry_config controls task retries (the
2770 # second attempt, third attempt, etc).
2771 #
2772 # This message determines the maximum rate that tasks can be dispatched by a
2773 # queue, regardless of whether the dispatch is a first task attempt or a retry.
2774 #
2775 # Note: The debugging command, RunTask, will run a task
2776 # even if the queue has reached its RateLimits.
2777 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
2778 # to be dispatched for this queue. After this threshold has been
2779 # reached, Cloud Tasks stops dispatching tasks until the number of
2780 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002781 #
2782 # If unspecified when the queue is created, Cloud Tasks will pick the
2783 # default.
2784 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002785 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002786 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002787 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002788 # This field is output only for
2789 # pull queues and always -1, which indicates no limit. No other
2790 # queue types can have `max_concurrent_tasks` set to -1.
2791 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002792 #
2793 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07002794 # [max_concurrent_requests in
2795 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
2796 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002797 #
2798 # If unspecified when the queue is created, Cloud Tasks will pick the
2799 # default.
2800 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002801 # * For App Engine queues, the maximum allowed value
2802 # is 500.
2803 # * This field is output only for pull queues. In addition to the
2804 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
2805 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002806 #
2807 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002808 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07002809 # [rate in
2810 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
2811 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002812 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002813 # Max burst size limits how fast tasks in queue are processed when
2814 # many tasks are in the queue and the rate is high. This field
2815 # allows the queue to have a high rate so processing starts shortly
2816 # after a task is enqueued, but still limits resource usage when
2817 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002818 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002819 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
2820 # algorithm is used to control the rate of task dispatches. Each
2821 # queue has a token bucket that holds tokens, up to the maximum
2822 # specified by `max_burst_size`. Each time a task is dispatched, a
2823 # token is removed from the bucket. Tasks will be dispatched until
2824 # the queue&#x27;s bucket runs out of tokens. The bucket will be
2825 # continuously refilled with new tokens based on
2826 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002827 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002828 # Cloud Tasks will pick the value of `max_burst_size` based on the
2829 # value of
2830 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002831 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002832 # For App Engine queues that were created or updated using
2833 # `queue.yaml/xml`, `max_burst_size` is equal to
2834 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
2835 # Since `max_burst_size` is output only, if
2836 # UpdateQueue is called on a queue
2837 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
2838 # on the value of
2839 # max_tasks_dispatched_per_second,
2840 # regardless of whether
2841 # max_tasks_dispatched_per_second
2842 # is updated.
2843 },
2844 &quot;pullTarget&quot;: { # Pull target. # Pull target.
2845 #
2846 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002847 },
2848 }</pre>
2849</div>
2850
2851<div class="method">
2852 <code class="details" id="pause">pause(name, body=None, x__xgafv=None)</code>
2853 <pre>Pauses the queue.
2854
2855If a queue is paused then the system will stop dispatching tasks
2856until the queue is resumed via
2857ResumeQueue. Tasks can still be added
2858when the queue is paused. A queue is paused if its
2859state is PAUSED.
2860
2861Args:
Dan O'Mearadd494642020-05-01 07:42:23 -07002862 name: string, Required. The queue name. For example:
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002863`projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` (required)
2864 body: object, The request body.
2865 The object takes the form of:
2866
2867{ # Request message for PauseQueue.
2868 }
2869
2870 x__xgafv: string, V1 error format.
2871 Allowed values
2872 1 - v1 error format
2873 2 - v2 error format
2874
2875Returns:
2876 An object of the form:
2877
2878 { # A queue is a container of related tasks. Queues are configured to manage
2879 # how those tasks are dispatched. Configurable properties include rate limits,
2880 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -07002881 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002882 #
2883 # An App Engine queue is a queue that has an AppEngineHttpTarget.
2884 #
2885 # The task will be delivered to the App Engine application hostname
2886 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
2887 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -07002888 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002889 #
2890 # Using AppEngineHttpTarget requires
2891 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
2892 # Google IAM permission for the project
2893 # and the following scope:
2894 #
2895 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -07002896 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002897 # task-level app_engine_routing.
2898 #
2899 # If set, `app_engine_routing_override` is used for all tasks in
2900 # the queue, no matter what the setting is for the
2901 # task-level app_engine_routing.
2902 #
2903 # Defines routing characteristics specific to App Engine - service, version,
2904 # and instance.
2905 #
2906 # For more information about services, versions, and instances see
2907 # [An Overview of App
2908 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
2909 # [Microservices Architecture on Google App
2910 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
2911 # [App Engine Standard request
2912 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
2913 # and [App Engine Flex request
2914 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07002915 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002916 #
2917 # By default, the task is sent to an instance which is available when
2918 # the task is attempted.
2919 #
2920 # Requests can only be sent to a specific instance if
2921 # [manual scaling is used in App Engine
2922 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
2923 # App Engine Flex does not support instances. For more information, see
2924 # [App Engine Standard request
2925 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
2926 # and [App Engine Flex request
2927 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07002928 &quot;version&quot;: &quot;A String&quot;, # App version.
2929 #
2930 # By default, the task is sent to the version which is the default
2931 # version when the task is attempted.
2932 #
2933 # For some queues or tasks which were created using the App Engine
2934 # Task Queue API, host is not parsable
2935 # into service,
2936 # version, and
2937 # instance. For example, some tasks
2938 # which were created using the App Engine SDK use a custom domain
2939 # name; custom domains are not parsed by Cloud Tasks. If
2940 # host is not parsable, then
2941 # service,
2942 # version, and
2943 # instance are the empty string.
2944 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002945 #
2946 # For more information, see
2947 # [How Requests are
2948 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
2949 #
2950 # The host is constructed as:
2951 #
2952 #
Dan O'Mearadd494642020-05-01 07:42:23 -07002953 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -07002954 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2955 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2956 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2957 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2958 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2959 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
2960 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002961 #
2962 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -07002963 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -07002964 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002965 # SDK use a custom domain name.
2966 #
2967 # * `service =` service
2968 #
2969 # * `version =` version
2970 #
2971 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002972 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002973 # service
2974 #
2975 # * `instance =` instance
2976 #
2977 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002978 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002979 # service
2980 #
2981 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002982 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002983 # version
2984 #
2985 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07002986 # instance `+ &#x27;.&#x27; +`
2987 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002988 # service
2989 #
2990 # If service is empty, then the task will be sent
2991 # to the service which is the default service when the task is attempted.
2992 #
2993 # If version is empty, then the task will be sent
2994 # to the version which is the default version when the task is attempted.
2995 #
2996 # If instance is empty, then the task
2997 # will be sent to an instance which is available when the task is
2998 # attempted.
2999 #
3000 # If service,
3001 # version, or
3002 # instance is invalid, then the task
3003 # will be sent to the default version of the default service when
3004 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -07003005 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003006 #
3007 # By default, the task is sent to the service which is the default
3008 # service when the task is attempted.
3009 #
3010 # For some queues or tasks which were created using the App Engine
3011 # Task Queue API, host is not parsable
3012 # into service,
3013 # version, and
3014 # instance. For example, some tasks
3015 # which were created using the App Engine SDK use a custom domain
3016 # name; custom domains are not parsed by Cloud Tasks. If
3017 # host is not parsable, then
3018 # service,
3019 # version, and
3020 # instance are the empty string.
3021 },
3022 },
Bu Sun Kim65020912020-05-20 12:08:20 -07003023 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003024 #
3025 # All tasks that were created before this time
3026 # were purged.
3027 #
3028 # A queue can be purged using PurgeQueue, the
3029 # [App Engine Task Queue SDK, or the Cloud
3030 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
3031 #
3032 # Purge time will be truncated to the nearest microsecond. Purge
3033 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -07003034 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
3035 #
3036 # `state` can only be changed by called
3037 # PauseQueue,
3038 # ResumeQueue, or uploading
3039 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
3040 # UpdateQueue cannot be used to change `state`.
3041 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003042 #
3043 # * For tasks created using Cloud Tasks: the queue-level retry settings
3044 # apply to all tasks in the queue that were created using Cloud Tasks.
3045 # Retry settings cannot be set on individual tasks.
3046 # * For tasks created using the App Engine SDK: the queue-level retry
3047 # settings apply to all tasks in the queue which do not have retry settings
3048 # explicitly set on the task and were created by the App Engine SDK. See
3049 # [App Engine
3050 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
3051 #
3052 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -07003053 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
3054 # min_backoff and
3055 # max_backoff duration after it fails,
3056 # if the queue&#x27;s RetryConfig specifies that the task should be
3057 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003058 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003059 # If unspecified when the queue is created, Cloud Tasks will pick the
3060 # default.
3061 #
3062 # This field is output only for pull queues.
3063 #
3064 #
3065 # `min_backoff` will be truncated to the nearest second.
3066 #
3067 # This field has the same meaning as
3068 # [min_backoff_seconds in
3069 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3070 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
3071 # min_backoff and
3072 # max_backoff duration after it fails,
3073 # if the queue&#x27;s RetryConfig specifies that the task should be
3074 # retried.
3075 #
3076 # If unspecified when the queue is created, Cloud Tasks will pick the
3077 # default.
3078 #
3079 # This field is output only for pull queues.
3080 #
3081 #
3082 # `max_backoff` will be truncated to the nearest second.
3083 #
3084 # This field has the same meaning as
3085 # [max_backoff_seconds in
3086 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3087 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
3088 # retrying a failed task, measured from when the task was first
3089 # attempted. Once `max_retry_duration` time has passed *and* the
3090 # task has been attempted max_attempts
3091 # times, no further attempts will be made and the task will be
3092 # deleted.
3093 #
3094 # If zero, then the task age is unlimited.
3095 #
3096 # If unspecified when the queue is created, Cloud Tasks will pick the
3097 # default.
3098 #
3099 # This field is output only for pull queues.
3100 #
3101 #
3102 # `max_retry_duration` will be truncated to the nearest second.
3103 #
3104 # This field has the same meaning as
3105 # [task_age_limit in
3106 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3107 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
3108 #
3109 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003110 # min_backoff, then doubles
3111 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -07003112 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003113 # max_backoff up to
3114 # max_attempts times.
3115 #
3116 # For example, if min_backoff is 10s,
3117 # max_backoff is 300s, and
3118 # `max_doublings` is 3, then the a task will first be retried in
3119 # 10s. The retry interval will double three times, and then
3120 # increase linearly by 2^3 * 10s. Finally, the task will retry at
3121 # intervals of max_backoff until the
3122 # task has been attempted max_attempts
3123 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
3124 # 240s, 300s, 300s, ....
3125 #
3126 # If unspecified when the queue is created, Cloud Tasks will pick the
3127 # default.
3128 #
3129 # This field is output only for pull queues.
3130 #
3131 #
3132 # This field has the same meaning as
3133 # [max_doublings in
3134 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -07003135 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003136 #
3137 # Cloud Tasks will attempt the task `max_attempts` times (that
3138 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -07003139 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -07003140 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
3141 },
3142 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
3143 # after which it becomes output only.
3144 #
3145 # The queue name.
3146 #
3147 # The queue name must have the following format:
3148 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
3149 #
3150 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
3151 # hyphens (-), colons (:), or periods (.).
3152 # For more information, see
3153 # [Identifying
3154 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
3155 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
3156 # The list of available locations can be obtained by calling
3157 # ListLocations.
3158 # For more information, see https://cloud.google.com/about/locations/.
3159 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
3160 # hyphens (-). The maximum length is 100 characters.
3161 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
3162 #
3163 # rate_limits and
3164 # retry_config are related because they both
3165 # control task attempts however they control how tasks are
3166 # attempted in different ways:
3167 #
3168 # * rate_limits controls the total rate of
3169 # dispatches from a queue (i.e. all traffic dispatched from the
3170 # queue, regardless of whether the dispatch is from a first
3171 # attempt or a retry).
3172 # * retry_config controls what happens to
3173 # particular a task after its first attempt fails. That is,
3174 # retry_config controls task retries (the
3175 # second attempt, third attempt, etc).
3176 #
3177 # This message determines the maximum rate that tasks can be dispatched by a
3178 # queue, regardless of whether the dispatch is a first task attempt or a retry.
3179 #
3180 # Note: The debugging command, RunTask, will run a task
3181 # even if the queue has reached its RateLimits.
3182 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
3183 # to be dispatched for this queue. After this threshold has been
3184 # reached, Cloud Tasks stops dispatching tasks until the number of
3185 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003186 #
3187 # If unspecified when the queue is created, Cloud Tasks will pick the
3188 # default.
3189 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003190 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003191 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003192 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003193 # This field is output only for
3194 # pull queues and always -1, which indicates no limit. No other
3195 # queue types can have `max_concurrent_tasks` set to -1.
3196 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003197 #
3198 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07003199 # [max_concurrent_requests in
3200 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
3201 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003202 #
3203 # If unspecified when the queue is created, Cloud Tasks will pick the
3204 # default.
3205 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003206 # * For App Engine queues, the maximum allowed value
3207 # is 500.
3208 # * This field is output only for pull queues. In addition to the
3209 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
3210 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003211 #
3212 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003213 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07003214 # [rate in
3215 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
3216 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003217 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003218 # Max burst size limits how fast tasks in queue are processed when
3219 # many tasks are in the queue and the rate is high. This field
3220 # allows the queue to have a high rate so processing starts shortly
3221 # after a task is enqueued, but still limits resource usage when
3222 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003223 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003224 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
3225 # algorithm is used to control the rate of task dispatches. Each
3226 # queue has a token bucket that holds tokens, up to the maximum
3227 # specified by `max_burst_size`. Each time a task is dispatched, a
3228 # token is removed from the bucket. Tasks will be dispatched until
3229 # the queue&#x27;s bucket runs out of tokens. The bucket will be
3230 # continuously refilled with new tokens based on
3231 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003232 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003233 # Cloud Tasks will pick the value of `max_burst_size` based on the
3234 # value of
3235 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003236 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003237 # For App Engine queues that were created or updated using
3238 # `queue.yaml/xml`, `max_burst_size` is equal to
3239 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
3240 # Since `max_burst_size` is output only, if
3241 # UpdateQueue is called on a queue
3242 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
3243 # on the value of
3244 # max_tasks_dispatched_per_second,
3245 # regardless of whether
3246 # max_tasks_dispatched_per_second
3247 # is updated.
3248 },
3249 &quot;pullTarget&quot;: { # Pull target. # Pull target.
3250 #
3251 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003252 },
3253 }</pre>
3254</div>
3255
3256<div class="method">
3257 <code class="details" id="purge">purge(name, body=None, x__xgafv=None)</code>
3258 <pre>Purges a queue by deleting all of its tasks.
3259
3260All tasks created before this method is called are permanently deleted.
3261
3262Purge operations can take up to one minute to take effect. Tasks
3263might be dispatched before the purge takes effect. A purge is irreversible.
3264
3265Args:
Dan O'Mearadd494642020-05-01 07:42:23 -07003266 name: string, Required. The queue name. For example:
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003267`projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` (required)
3268 body: object, The request body.
3269 The object takes the form of:
3270
3271{ # Request message for PurgeQueue.
3272 }
3273
3274 x__xgafv: string, V1 error format.
3275 Allowed values
3276 1 - v1 error format
3277 2 - v2 error format
3278
3279Returns:
3280 An object of the form:
3281
3282 { # A queue is a container of related tasks. Queues are configured to manage
3283 # how those tasks are dispatched. Configurable properties include rate limits,
3284 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -07003285 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003286 #
3287 # An App Engine queue is a queue that has an AppEngineHttpTarget.
3288 #
3289 # The task will be delivered to the App Engine application hostname
3290 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
3291 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -07003292 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003293 #
3294 # Using AppEngineHttpTarget requires
3295 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
3296 # Google IAM permission for the project
3297 # and the following scope:
3298 #
3299 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -07003300 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003301 # task-level app_engine_routing.
3302 #
3303 # If set, `app_engine_routing_override` is used for all tasks in
3304 # the queue, no matter what the setting is for the
3305 # task-level app_engine_routing.
3306 #
3307 # Defines routing characteristics specific to App Engine - service, version,
3308 # and instance.
3309 #
3310 # For more information about services, versions, and instances see
3311 # [An Overview of App
3312 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
3313 # [Microservices Architecture on Google App
3314 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
3315 # [App Engine Standard request
3316 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
3317 # and [App Engine Flex request
3318 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07003319 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003320 #
3321 # By default, the task is sent to an instance which is available when
3322 # the task is attempted.
3323 #
3324 # Requests can only be sent to a specific instance if
3325 # [manual scaling is used in App Engine
3326 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
3327 # App Engine Flex does not support instances. For more information, see
3328 # [App Engine Standard request
3329 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
3330 # and [App Engine Flex request
3331 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07003332 &quot;version&quot;: &quot;A String&quot;, # App version.
3333 #
3334 # By default, the task is sent to the version which is the default
3335 # version when the task is attempted.
3336 #
3337 # For some queues or tasks which were created using the App Engine
3338 # Task Queue API, host is not parsable
3339 # into service,
3340 # version, and
3341 # instance. For example, some tasks
3342 # which were created using the App Engine SDK use a custom domain
3343 # name; custom domains are not parsed by Cloud Tasks. If
3344 # host is not parsable, then
3345 # service,
3346 # version, and
3347 # instance are the empty string.
3348 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003349 #
3350 # For more information, see
3351 # [How Requests are
3352 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
3353 #
3354 # The host is constructed as:
3355 #
3356 #
Dan O'Mearadd494642020-05-01 07:42:23 -07003357 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -07003358 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3359 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3360 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3361 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3362 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3363 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3364 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003365 #
3366 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -07003367 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -07003368 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003369 # SDK use a custom domain name.
3370 #
3371 # * `service =` service
3372 #
3373 # * `version =` version
3374 #
3375 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07003376 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003377 # service
3378 #
3379 # * `instance =` instance
3380 #
3381 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07003382 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003383 # service
3384 #
3385 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -07003386 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003387 # version
3388 #
3389 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07003390 # instance `+ &#x27;.&#x27; +`
3391 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003392 # service
3393 #
3394 # If service is empty, then the task will be sent
3395 # to the service which is the default service when the task is attempted.
3396 #
3397 # If version is empty, then the task will be sent
3398 # to the version which is the default version when the task is attempted.
3399 #
3400 # If instance is empty, then the task
3401 # will be sent to an instance which is available when the task is
3402 # attempted.
3403 #
3404 # If service,
3405 # version, or
3406 # instance is invalid, then the task
3407 # will be sent to the default version of the default service when
3408 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -07003409 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003410 #
3411 # By default, the task is sent to the service which is the default
3412 # service when the task is attempted.
3413 #
3414 # For some queues or tasks which were created using the App Engine
3415 # Task Queue API, host is not parsable
3416 # into service,
3417 # version, and
3418 # instance. For example, some tasks
3419 # which were created using the App Engine SDK use a custom domain
3420 # name; custom domains are not parsed by Cloud Tasks. If
3421 # host is not parsable, then
3422 # service,
3423 # version, and
3424 # instance are the empty string.
3425 },
3426 },
Bu Sun Kim65020912020-05-20 12:08:20 -07003427 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003428 #
3429 # All tasks that were created before this time
3430 # were purged.
3431 #
3432 # A queue can be purged using PurgeQueue, the
3433 # [App Engine Task Queue SDK, or the Cloud
3434 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
3435 #
3436 # Purge time will be truncated to the nearest microsecond. Purge
3437 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -07003438 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
3439 #
3440 # `state` can only be changed by called
3441 # PauseQueue,
3442 # ResumeQueue, or uploading
3443 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
3444 # UpdateQueue cannot be used to change `state`.
3445 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003446 #
3447 # * For tasks created using Cloud Tasks: the queue-level retry settings
3448 # apply to all tasks in the queue that were created using Cloud Tasks.
3449 # Retry settings cannot be set on individual tasks.
3450 # * For tasks created using the App Engine SDK: the queue-level retry
3451 # settings apply to all tasks in the queue which do not have retry settings
3452 # explicitly set on the task and were created by the App Engine SDK. See
3453 # [App Engine
3454 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
3455 #
3456 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -07003457 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
3458 # min_backoff and
3459 # max_backoff duration after it fails,
3460 # if the queue&#x27;s RetryConfig specifies that the task should be
3461 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003462 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003463 # If unspecified when the queue is created, Cloud Tasks will pick the
3464 # default.
3465 #
3466 # This field is output only for pull queues.
3467 #
3468 #
3469 # `min_backoff` will be truncated to the nearest second.
3470 #
3471 # This field has the same meaning as
3472 # [min_backoff_seconds in
3473 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3474 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
3475 # min_backoff and
3476 # max_backoff duration after it fails,
3477 # if the queue&#x27;s RetryConfig specifies that the task should be
3478 # retried.
3479 #
3480 # If unspecified when the queue is created, Cloud Tasks will pick the
3481 # default.
3482 #
3483 # This field is output only for pull queues.
3484 #
3485 #
3486 # `max_backoff` will be truncated to the nearest second.
3487 #
3488 # This field has the same meaning as
3489 # [max_backoff_seconds in
3490 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3491 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
3492 # retrying a failed task, measured from when the task was first
3493 # attempted. Once `max_retry_duration` time has passed *and* the
3494 # task has been attempted max_attempts
3495 # times, no further attempts will be made and the task will be
3496 # deleted.
3497 #
3498 # If zero, then the task age is unlimited.
3499 #
3500 # If unspecified when the queue is created, Cloud Tasks will pick the
3501 # default.
3502 #
3503 # This field is output only for pull queues.
3504 #
3505 #
3506 # `max_retry_duration` will be truncated to the nearest second.
3507 #
3508 # This field has the same meaning as
3509 # [task_age_limit in
3510 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3511 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
3512 #
3513 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003514 # min_backoff, then doubles
3515 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -07003516 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003517 # max_backoff up to
3518 # max_attempts times.
3519 #
3520 # For example, if min_backoff is 10s,
3521 # max_backoff is 300s, and
3522 # `max_doublings` is 3, then the a task will first be retried in
3523 # 10s. The retry interval will double three times, and then
3524 # increase linearly by 2^3 * 10s. Finally, the task will retry at
3525 # intervals of max_backoff until the
3526 # task has been attempted max_attempts
3527 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
3528 # 240s, 300s, 300s, ....
3529 #
3530 # If unspecified when the queue is created, Cloud Tasks will pick the
3531 # default.
3532 #
3533 # This field is output only for pull queues.
3534 #
3535 #
3536 # This field has the same meaning as
3537 # [max_doublings in
3538 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -07003539 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003540 #
3541 # Cloud Tasks will attempt the task `max_attempts` times (that
3542 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -07003543 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -07003544 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
3545 },
3546 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
3547 # after which it becomes output only.
3548 #
3549 # The queue name.
3550 #
3551 # The queue name must have the following format:
3552 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
3553 #
3554 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
3555 # hyphens (-), colons (:), or periods (.).
3556 # For more information, see
3557 # [Identifying
3558 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
3559 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
3560 # The list of available locations can be obtained by calling
3561 # ListLocations.
3562 # For more information, see https://cloud.google.com/about/locations/.
3563 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
3564 # hyphens (-). The maximum length is 100 characters.
3565 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
3566 #
3567 # rate_limits and
3568 # retry_config are related because they both
3569 # control task attempts however they control how tasks are
3570 # attempted in different ways:
3571 #
3572 # * rate_limits controls the total rate of
3573 # dispatches from a queue (i.e. all traffic dispatched from the
3574 # queue, regardless of whether the dispatch is from a first
3575 # attempt or a retry).
3576 # * retry_config controls what happens to
3577 # particular a task after its first attempt fails. That is,
3578 # retry_config controls task retries (the
3579 # second attempt, third attempt, etc).
3580 #
3581 # This message determines the maximum rate that tasks can be dispatched by a
3582 # queue, regardless of whether the dispatch is a first task attempt or a retry.
3583 #
3584 # Note: The debugging command, RunTask, will run a task
3585 # even if the queue has reached its RateLimits.
3586 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
3587 # to be dispatched for this queue. After this threshold has been
3588 # reached, Cloud Tasks stops dispatching tasks until the number of
3589 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003590 #
3591 # If unspecified when the queue is created, Cloud Tasks will pick the
3592 # default.
3593 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003594 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003595 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003596 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003597 # This field is output only for
3598 # pull queues and always -1, which indicates no limit. No other
3599 # queue types can have `max_concurrent_tasks` set to -1.
3600 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003601 #
3602 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07003603 # [max_concurrent_requests in
3604 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
3605 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003606 #
3607 # If unspecified when the queue is created, Cloud Tasks will pick the
3608 # default.
3609 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003610 # * For App Engine queues, the maximum allowed value
3611 # is 500.
3612 # * This field is output only for pull queues. In addition to the
3613 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
3614 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003615 #
3616 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003617 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07003618 # [rate in
3619 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
3620 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003621 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003622 # Max burst size limits how fast tasks in queue are processed when
3623 # many tasks are in the queue and the rate is high. This field
3624 # allows the queue to have a high rate so processing starts shortly
3625 # after a task is enqueued, but still limits resource usage when
3626 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003627 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003628 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
3629 # algorithm is used to control the rate of task dispatches. Each
3630 # queue has a token bucket that holds tokens, up to the maximum
3631 # specified by `max_burst_size`. Each time a task is dispatched, a
3632 # token is removed from the bucket. Tasks will be dispatched until
3633 # the queue&#x27;s bucket runs out of tokens. The bucket will be
3634 # continuously refilled with new tokens based on
3635 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003636 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003637 # Cloud Tasks will pick the value of `max_burst_size` based on the
3638 # value of
3639 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003640 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003641 # For App Engine queues that were created or updated using
3642 # `queue.yaml/xml`, `max_burst_size` is equal to
3643 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
3644 # Since `max_burst_size` is output only, if
3645 # UpdateQueue is called on a queue
3646 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
3647 # on the value of
3648 # max_tasks_dispatched_per_second,
3649 # regardless of whether
3650 # max_tasks_dispatched_per_second
3651 # is updated.
3652 },
3653 &quot;pullTarget&quot;: { # Pull target. # Pull target.
3654 #
3655 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003656 },
3657 }</pre>
3658</div>
3659
3660<div class="method">
3661 <code class="details" id="resume">resume(name, body=None, x__xgafv=None)</code>
3662 <pre>Resume a queue.
3663
3664This method resumes a queue after it has been
3665PAUSED or
3666DISABLED. The state of a queue is stored
Bu Sun Kim65020912020-05-20 12:08:20 -07003667in the queue&#x27;s state; after calling this method it
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003668will be set to RUNNING.
3669
3670WARNING: Resuming many high-QPS queues at the same time can
3671lead to target overloading. If you are resuming high-QPS
3672queues, follow the 500/50/5 pattern described in
3673[Managing Cloud Tasks Scaling
3674Risks](https://cloud.google.com/tasks/docs/manage-cloud-task-scaling).
3675
3676Args:
Dan O'Mearadd494642020-05-01 07:42:23 -07003677 name: string, Required. The queue name. For example:
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003678`projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` (required)
3679 body: object, The request body.
3680 The object takes the form of:
3681
3682{ # Request message for ResumeQueue.
3683 }
3684
3685 x__xgafv: string, V1 error format.
3686 Allowed values
3687 1 - v1 error format
3688 2 - v2 error format
3689
3690Returns:
3691 An object of the form:
3692
3693 { # A queue is a container of related tasks. Queues are configured to manage
3694 # how those tasks are dispatched. Configurable properties include rate limits,
3695 # retry options, target types, and others.
Bu Sun Kim65020912020-05-20 12:08:20 -07003696 &quot;appEngineHttpTarget&quot;: { # App Engine HTTP target. # App Engine HTTP target.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003697 #
3698 # An App Engine queue is a queue that has an AppEngineHttpTarget.
3699 #
3700 # The task will be delivered to the App Engine application hostname
3701 # specified by its AppEngineHttpTarget and AppEngineHttpRequest.
3702 # The documentation for AppEngineHttpRequest explains how the
Bu Sun Kim65020912020-05-20 12:08:20 -07003703 # task&#x27;s host URL is constructed.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003704 #
3705 # Using AppEngineHttpTarget requires
3706 # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
3707 # Google IAM permission for the project
3708 # and the following scope:
3709 #
3710 # `https://www.googleapis.com/auth/cloud-platform`
Bu Sun Kim65020912020-05-20 12:08:20 -07003711 &quot;appEngineRoutingOverride&quot;: { # App Engine Routing. # Overrides for the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003712 # task-level app_engine_routing.
3713 #
3714 # If set, `app_engine_routing_override` is used for all tasks in
3715 # the queue, no matter what the setting is for the
3716 # task-level app_engine_routing.
3717 #
3718 # Defines routing characteristics specific to App Engine - service, version,
3719 # and instance.
3720 #
3721 # For more information about services, versions, and instances see
3722 # [An Overview of App
3723 # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
3724 # [Microservices Architecture on Google App
3725 # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
3726 # [App Engine Standard request
3727 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
3728 # and [App Engine Flex request
3729 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07003730 &quot;instance&quot;: &quot;A String&quot;, # App instance.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003731 #
3732 # By default, the task is sent to an instance which is available when
3733 # the task is attempted.
3734 #
3735 # Requests can only be sent to a specific instance if
3736 # [manual scaling is used in App Engine
3737 # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
3738 # App Engine Flex does not support instances. For more information, see
3739 # [App Engine Standard request
3740 # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
3741 # and [App Engine Flex request
3742 # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
Bu Sun Kim65020912020-05-20 12:08:20 -07003743 &quot;version&quot;: &quot;A String&quot;, # App version.
3744 #
3745 # By default, the task is sent to the version which is the default
3746 # version when the task is attempted.
3747 #
3748 # For some queues or tasks which were created using the App Engine
3749 # Task Queue API, host is not parsable
3750 # into service,
3751 # version, and
3752 # instance. For example, some tasks
3753 # which were created using the App Engine SDK use a custom domain
3754 # name; custom domains are not parsed by Cloud Tasks. If
3755 # host is not parsable, then
3756 # service,
3757 # version, and
3758 # instance are the empty string.
3759 &quot;host&quot;: &quot;A String&quot;, # Output only. The host that the task is sent to.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003760 #
3761 # For more information, see
3762 # [How Requests are
3763 # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
3764 #
3765 # The host is constructed as:
3766 #
3767 #
Dan O'Mearadd494642020-05-01 07:42:23 -07003768 # * `host = [application_domain_name]`&lt;/br&gt;
Bu Sun Kim65020912020-05-20 12:08:20 -07003769 # `| [service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3770 # `| [version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3771 # `| [version_dot_service]+ &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3772 # `| [instance] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3773 # `| [instance_dot_service] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3774 # `| [instance_dot_version] + &#x27;.&#x27; + [application_domain_name]`&lt;/br&gt;
3775 # `| [instance_dot_version_dot_service] + &#x27;.&#x27; + [application_domain_name]`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003776 #
3777 # * `application_domain_name` = The domain name of the app, for
Dan O'Mearadd494642020-05-01 07:42:23 -07003778 # example &lt;app-id&gt;.appspot.com, which is associated with the
Bu Sun Kim65020912020-05-20 12:08:20 -07003779 # queue&#x27;s project ID. Some tasks which were created using the App Engine
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003780 # SDK use a custom domain name.
3781 #
3782 # * `service =` service
3783 #
3784 # * `version =` version
3785 #
3786 # * `version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07003787 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003788 # service
3789 #
3790 # * `instance =` instance
3791 #
3792 # * `instance_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07003793 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003794 # service
3795 #
3796 # * `instance_dot_version =`
Bu Sun Kim65020912020-05-20 12:08:20 -07003797 # instance `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003798 # version
3799 #
3800 # * `instance_dot_version_dot_service =`
Bu Sun Kim65020912020-05-20 12:08:20 -07003801 # instance `+ &#x27;.&#x27; +`
3802 # version `+ &#x27;.&#x27; +`
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003803 # service
3804 #
3805 # If service is empty, then the task will be sent
3806 # to the service which is the default service when the task is attempted.
3807 #
3808 # If version is empty, then the task will be sent
3809 # to the version which is the default version when the task is attempted.
3810 #
3811 # If instance is empty, then the task
3812 # will be sent to an instance which is available when the task is
3813 # attempted.
3814 #
3815 # If service,
3816 # version, or
3817 # instance is invalid, then the task
3818 # will be sent to the default version of the default service when
3819 # the task is attempted.
Bu Sun Kim65020912020-05-20 12:08:20 -07003820 &quot;service&quot;: &quot;A String&quot;, # App service.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003821 #
3822 # By default, the task is sent to the service which is the default
3823 # service when the task is attempted.
3824 #
3825 # For some queues or tasks which were created using the App Engine
3826 # Task Queue API, host is not parsable
3827 # into service,
3828 # version, and
3829 # instance. For example, some tasks
3830 # which were created using the App Engine SDK use a custom domain
3831 # name; custom domains are not parsed by Cloud Tasks. If
3832 # host is not parsable, then
3833 # service,
3834 # version, and
3835 # instance are the empty string.
3836 },
3837 },
Bu Sun Kim65020912020-05-20 12:08:20 -07003838 &quot;purgeTime&quot;: &quot;A String&quot;, # Output only. The last time this queue was purged.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003839 #
3840 # All tasks that were created before this time
3841 # were purged.
3842 #
3843 # A queue can be purged using PurgeQueue, the
3844 # [App Engine Task Queue SDK, or the Cloud
3845 # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
3846 #
3847 # Purge time will be truncated to the nearest microsecond. Purge
3848 # time will be unset if the queue has never been purged.
Bu Sun Kim65020912020-05-20 12:08:20 -07003849 &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the queue.
3850 #
3851 # `state` can only be changed by called
3852 # PauseQueue,
3853 # ResumeQueue, or uploading
3854 # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
3855 # UpdateQueue cannot be used to change `state`.
3856 &quot;retryConfig&quot;: { # Retry config. # Settings that determine the retry behavior.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003857 #
3858 # * For tasks created using Cloud Tasks: the queue-level retry settings
3859 # apply to all tasks in the queue that were created using Cloud Tasks.
3860 # Retry settings cannot be set on individual tasks.
3861 # * For tasks created using the App Engine SDK: the queue-level retry
3862 # settings apply to all tasks in the queue which do not have retry settings
3863 # explicitly set on the task and were created by the App Engine SDK. See
3864 # [App Engine
3865 # documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
3866 #
3867 # These settings determine how a failed task attempt is retried.
Bu Sun Kim65020912020-05-20 12:08:20 -07003868 &quot;minBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
3869 # min_backoff and
3870 # max_backoff duration after it fails,
3871 # if the queue&#x27;s RetryConfig specifies that the task should be
3872 # retried.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003873 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003874 # If unspecified when the queue is created, Cloud Tasks will pick the
3875 # default.
3876 #
3877 # This field is output only for pull queues.
3878 #
3879 #
3880 # `min_backoff` will be truncated to the nearest second.
3881 #
3882 # This field has the same meaning as
3883 # [min_backoff_seconds in
3884 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3885 &quot;maxBackoff&quot;: &quot;A String&quot;, # A task will be scheduled for retry between
3886 # min_backoff and
3887 # max_backoff duration after it fails,
3888 # if the queue&#x27;s RetryConfig specifies that the task should be
3889 # retried.
3890 #
3891 # If unspecified when the queue is created, Cloud Tasks will pick the
3892 # default.
3893 #
3894 # This field is output only for pull queues.
3895 #
3896 #
3897 # `max_backoff` will be truncated to the nearest second.
3898 #
3899 # This field has the same meaning as
3900 # [max_backoff_seconds in
3901 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3902 &quot;maxRetryDuration&quot;: &quot;A String&quot;, # If positive, `max_retry_duration` specifies the time limit for
3903 # retrying a failed task, measured from when the task was first
3904 # attempted. Once `max_retry_duration` time has passed *and* the
3905 # task has been attempted max_attempts
3906 # times, no further attempts will be made and the task will be
3907 # deleted.
3908 #
3909 # If zero, then the task age is unlimited.
3910 #
3911 # If unspecified when the queue is created, Cloud Tasks will pick the
3912 # default.
3913 #
3914 # This field is output only for pull queues.
3915 #
3916 #
3917 # `max_retry_duration` will be truncated to the nearest second.
3918 #
3919 # This field has the same meaning as
3920 # [task_age_limit in
3921 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3922 &quot;maxDoublings&quot;: 42, # The time between retries will double `max_doublings` times.
3923 #
3924 # A task&#x27;s retry interval starts at
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003925 # min_backoff, then doubles
3926 # `max_doublings` times, then increases linearly, and finally
Dan O'Mearadd494642020-05-01 07:42:23 -07003927 # retries at intervals of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003928 # max_backoff up to
3929 # max_attempts times.
3930 #
3931 # For example, if min_backoff is 10s,
3932 # max_backoff is 300s, and
3933 # `max_doublings` is 3, then the a task will first be retried in
3934 # 10s. The retry interval will double three times, and then
3935 # increase linearly by 2^3 * 10s. Finally, the task will retry at
3936 # intervals of max_backoff until the
3937 # task has been attempted max_attempts
3938 # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
3939 # 240s, 300s, 300s, ....
3940 #
3941 # If unspecified when the queue is created, Cloud Tasks will pick the
3942 # default.
3943 #
3944 # This field is output only for pull queues.
3945 #
3946 #
3947 # This field has the same meaning as
3948 # [max_doublings in
3949 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
Bu Sun Kim65020912020-05-20 12:08:20 -07003950 &quot;maxAttempts&quot;: 42, # The maximum number of attempts for a task.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07003951 #
3952 # Cloud Tasks will attempt the task `max_attempts` times (that
3953 # is, if the first attempt fails, then there will be
Dan O'Mearadd494642020-05-01 07:42:23 -07003954 # `max_attempts - 1` retries). Must be &gt; 0.
Bu Sun Kim65020912020-05-20 12:08:20 -07003955 &quot;unlimitedAttempts&quot;: True or False, # If true, then the number of attempts is unlimited.
3956 },
3957 &quot;name&quot;: &quot;A String&quot;, # Caller-specified and required in CreateQueue,
3958 # after which it becomes output only.
3959 #
3960 # The queue name.
3961 #
3962 # The queue name must have the following format:
3963 # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
3964 #
3965 # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
3966 # hyphens (-), colons (:), or periods (.).
3967 # For more information, see
3968 # [Identifying
3969 # projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
3970 # * `LOCATION_ID` is the canonical ID for the queue&#x27;s location.
3971 # The list of available locations can be obtained by calling
3972 # ListLocations.
3973 # For more information, see https://cloud.google.com/about/locations/.
3974 # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
3975 # hyphens (-). The maximum length is 100 characters.
3976 &quot;rateLimits&quot;: { # Rate limits. # Rate limits for task dispatches.
3977 #
3978 # rate_limits and
3979 # retry_config are related because they both
3980 # control task attempts however they control how tasks are
3981 # attempted in different ways:
3982 #
3983 # * rate_limits controls the total rate of
3984 # dispatches from a queue (i.e. all traffic dispatched from the
3985 # queue, regardless of whether the dispatch is from a first
3986 # attempt or a retry).
3987 # * retry_config controls what happens to
3988 # particular a task after its first attempt fails. That is,
3989 # retry_config controls task retries (the
3990 # second attempt, third attempt, etc).
3991 #
3992 # This message determines the maximum rate that tasks can be dispatched by a
3993 # queue, regardless of whether the dispatch is a first task attempt or a retry.
3994 #
3995 # Note: The debugging command, RunTask, will run a task
3996 # even if the queue has reached its RateLimits.
3997 &quot;maxConcurrentTasks&quot;: 42, # The maximum number of concurrent tasks that Cloud Tasks allows
3998 # to be dispatched for this queue. After this threshold has been
3999 # reached, Cloud Tasks stops dispatching tasks until the number of
4000 # concurrent requests decreases.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004001 #
4002 # If unspecified when the queue is created, Cloud Tasks will pick the
4003 # default.
4004 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004005 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004006 # The maximum allowed value is 5,000.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004007 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004008 # This field is output only for
4009 # pull queues and always -1, which indicates no limit. No other
4010 # queue types can have `max_concurrent_tasks` set to -1.
4011 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004012 #
4013 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07004014 # [max_concurrent_requests in
4015 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
4016 &quot;maxTasksDispatchedPerSecond&quot;: 3.14, # The maximum rate at which tasks are dispatched from this queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004017 #
4018 # If unspecified when the queue is created, Cloud Tasks will pick the
4019 # default.
4020 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004021 # * For App Engine queues, the maximum allowed value
4022 # is 500.
4023 # * This field is output only for pull queues. In addition to the
4024 # `max_tasks_dispatched_per_second` limit, a maximum of 10 QPS of
4025 # LeaseTasks requests are allowed per pull queue.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004026 #
4027 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004028 # This field has the same meaning as
Bu Sun Kim65020912020-05-20 12:08:20 -07004029 # [rate in
4030 # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
4031 &quot;maxBurstSize&quot;: 42, # Output only. The max burst size.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004032 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004033 # Max burst size limits how fast tasks in queue are processed when
4034 # many tasks are in the queue and the rate is high. This field
4035 # allows the queue to have a high rate so processing starts shortly
4036 # after a task is enqueued, but still limits resource usage when
4037 # many tasks are enqueued in a short period of time.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004038 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004039 # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
4040 # algorithm is used to control the rate of task dispatches. Each
4041 # queue has a token bucket that holds tokens, up to the maximum
4042 # specified by `max_burst_size`. Each time a task is dispatched, a
4043 # token is removed from the bucket. Tasks will be dispatched until
4044 # the queue&#x27;s bucket runs out of tokens. The bucket will be
4045 # continuously refilled with new tokens based on
4046 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004047 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004048 # Cloud Tasks will pick the value of `max_burst_size` based on the
4049 # value of
4050 # max_tasks_dispatched_per_second.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004051 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004052 # For App Engine queues that were created or updated using
4053 # `queue.yaml/xml`, `max_burst_size` is equal to
4054 # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
4055 # Since `max_burst_size` is output only, if
4056 # UpdateQueue is called on a queue
4057 # created by `queue.yaml/xml`, `max_burst_size` will be reset based
4058 # on the value of
4059 # max_tasks_dispatched_per_second,
4060 # regardless of whether
4061 # max_tasks_dispatched_per_second
4062 # is updated.
4063 },
4064 &quot;pullTarget&quot;: { # Pull target. # Pull target.
4065 #
4066 # A pull queue is a queue that has a PullTarget.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004067 },
4068 }</pre>
4069</div>
4070
4071<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07004072 <code class="details" id="setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004073 <pre>Sets the access control policy for a Queue. Replaces any existing
4074policy.
4075
4076Note: The Cloud Console does not check queue-level IAM permissions yet.
4077Project-level permissions are required to use the Cloud Console.
4078
4079Authorization requires the following
4080[Google IAM](https://cloud.google.com/iam) permission on the specified
4081resource parent:
4082
4083* `cloudtasks.queues.setIamPolicy`
4084
4085Args:
4086 resource: string, REQUIRED: The resource for which the policy is being specified.
4087See the operation documentation for the appropriate value for this field. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07004088 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004089 The object takes the form of:
4090
4091{ # Request message for `SetIamPolicy` method.
Bu Sun Kim65020912020-05-20 12:08:20 -07004092 &quot;policy&quot;: { # An Identity and Access Management (IAM) policy, which specifies access # REQUIRED: The complete policy to be applied to the `resource`. The size of
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004093 # the policy is limited to a few 10s of KB. An empty policy is a
4094 # valid policy but certain Cloud Platform services (such as Projects)
4095 # might reject them.
Dan O'Mearadd494642020-05-01 07:42:23 -07004096 # controls for Google Cloud resources.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004097 #
4098 #
Dan O'Mearadd494642020-05-01 07:42:23 -07004099 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
4100 # `members` to a single `role`. Members can be user accounts, service accounts,
4101 # Google groups, and domains (such as G Suite). A `role` is a named list of
4102 # permissions; each `role` can be an IAM predefined role or a user-created
4103 # custom role.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004104 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004105 # For some types of Google Cloud resources, a `binding` can also specify a
4106 # `condition`, which is a logical expression that allows access to a resource
4107 # only if the expression evaluates to `true`. A condition can add constraints
4108 # based on attributes of the request, the resource, or both. To learn which
4109 # resources support conditions in their IAM policies, see the
4110 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -07004111 #
4112 # **JSON example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004113 #
4114 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07004115 # &quot;bindings&quot;: [
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004116 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07004117 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
4118 # &quot;members&quot;: [
4119 # &quot;user:mike@example.com&quot;,
4120 # &quot;group:admins@example.com&quot;,
4121 # &quot;domain:google.com&quot;,
4122 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004123 # ]
4124 # },
4125 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07004126 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
4127 # &quot;members&quot;: [
4128 # &quot;user:eve@example.com&quot;
4129 # ],
4130 # &quot;condition&quot;: {
4131 # &quot;title&quot;: &quot;expirable access&quot;,
4132 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
4133 # &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -07004134 # }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004135 # }
Dan O'Mearadd494642020-05-01 07:42:23 -07004136 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004137 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
4138 # &quot;version&quot;: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004139 # }
4140 #
Dan O'Mearadd494642020-05-01 07:42:23 -07004141 # **YAML example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004142 #
4143 # bindings:
4144 # - members:
4145 # - user:mike@example.com
4146 # - group:admins@example.com
4147 # - domain:google.com
Dan O'Mearadd494642020-05-01 07:42:23 -07004148 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
4149 # role: roles/resourcemanager.organizationAdmin
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004150 # - members:
Dan O'Mearadd494642020-05-01 07:42:23 -07004151 # - user:eve@example.com
4152 # role: roles/resourcemanager.organizationViewer
4153 # condition:
4154 # title: expirable access
4155 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -07004156 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -07004157 # - etag: BwWWja0YfJA=
4158 # - version: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004159 #
4160 # For a description of IAM and its features, see the
Dan O'Mearadd494642020-05-01 07:42:23 -07004161 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim65020912020-05-20 12:08:20 -07004162 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
4163 # prevent simultaneous updates of a policy from overwriting each other.
4164 # It is strongly suggested that systems make use of the `etag` in the
4165 # read-modify-write cycle to perform policy updates in order to avoid race
4166 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
4167 # systems are expected to put that etag in the request to `setIamPolicy` to
4168 # ensure that their change will be applied to the same version of the policy.
4169 #
4170 # **Important:** If you use IAM Conditions, you must include the `etag` field
4171 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
4172 # you to overwrite a version `3` policy with a version `1` policy, and all of
4173 # the conditions in the version `3` policy are lost.
4174 &quot;version&quot;: 42, # Specifies the format of the policy.
4175 #
4176 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
4177 # are rejected.
4178 #
4179 # Any operation that affects conditional role bindings must specify version
4180 # `3`. This requirement applies to the following operations:
4181 #
4182 # * Getting a policy that includes a conditional role binding
4183 # * Adding a conditional role binding to a policy
4184 # * Changing a conditional role binding in a policy
4185 # * Removing any role binding, with or without a condition, from a policy
4186 # that includes conditions
4187 #
4188 # **Important:** If you use IAM Conditions, you must include the `etag` field
4189 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
4190 # you to overwrite a version `3` policy with a version `1` policy, and all of
4191 # the conditions in the version `3` policy are lost.
4192 #
4193 # If a policy does not include any conditions, operations on that policy may
4194 # specify any valid version or leave the field unset.
4195 #
4196 # To learn which resources support conditions in their IAM policies, see the
4197 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
4198 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -07004199 # `condition` that determines how and when the `bindings` are applied. Each
4200 # of the `bindings` must contain at least one member.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004201 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -07004202 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004203 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -07004204 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
4205 #
4206 # If the condition evaluates to `true`, then this binding applies to the
4207 # current request.
4208 #
4209 # If the condition evaluates to `false`, then this binding does not apply to
4210 # the current request. However, a different role binding might grant the same
4211 # role to one or more of the members in this binding.
4212 #
4213 # To learn which resources support conditions in their IAM policies, see the
4214 # [IAM
4215 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -07004216 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
4217 # are documented at https://github.com/google/cel-spec.
4218 #
4219 # Example (Comparison):
4220 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004221 # title: &quot;Summary size limit&quot;
4222 # description: &quot;Determines if a summary is less than 100 chars&quot;
4223 # expression: &quot;document.summary.size() &lt; 100&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07004224 #
4225 # Example (Equality):
4226 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004227 # title: &quot;Requestor is owner&quot;
4228 # description: &quot;Determines if requestor is the document owner&quot;
4229 # expression: &quot;document.owner == request.auth.claims.email&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07004230 #
4231 # Example (Logic):
4232 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004233 # title: &quot;Public documents&quot;
4234 # description: &quot;Determine whether the document should be publicly visible&quot;
4235 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07004236 #
4237 # Example (Data Manipulation):
4238 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004239 # title: &quot;Notification string&quot;
4240 # description: &quot;Create a notification string with a timestamp.&quot;
4241 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07004242 #
4243 # The exact variables and functions that may be referenced within an expression
4244 # are determined by the service that evaluates it. See the service
4245 # documentation for additional information.
Bu Sun Kim65020912020-05-20 12:08:20 -07004246 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
Dan O'Mearadd494642020-05-01 07:42:23 -07004247 # its purpose. This can be used e.g. in UIs which allow to enter the
4248 # expression.
Bu Sun Kim65020912020-05-20 12:08:20 -07004249 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
4250 # reporting, e.g. a file name and a position in the file.
4251 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
4252 # describes the expression, e.g. when hovered over it in a UI.
4253 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
4254 # syntax.
Dan O'Mearadd494642020-05-01 07:42:23 -07004255 },
Bu Sun Kim65020912020-05-20 12:08:20 -07004256 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004257 # `members` can have the following values:
4258 #
4259 # * `allUsers`: A special identifier that represents anyone who is
4260 # on the internet; with or without a Google account.
4261 #
4262 # * `allAuthenticatedUsers`: A special identifier that represents anyone
4263 # who is authenticated with a Google account or a service account.
4264 #
4265 # * `user:{emailid}`: An email address that represents a specific Google
Dan O'Mearadd494642020-05-01 07:42:23 -07004266 # account. For example, `alice@example.com` .
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004267 #
4268 #
4269 # * `serviceAccount:{emailid}`: An email address that represents a service
4270 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
4271 #
4272 # * `group:{emailid}`: An email address that represents a Google group.
4273 # For example, `admins@example.com`.
4274 #
Dan O'Mearadd494642020-05-01 07:42:23 -07004275 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
4276 # identifier) representing a user that has been recently deleted. For
4277 # example, `alice@example.com?uid=123456789012345678901`. If the user is
4278 # recovered, this value reverts to `user:{emailid}` and the recovered user
4279 # retains the role in the binding.
4280 #
4281 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
4282 # unique identifier) representing a service account that has been recently
4283 # deleted. For example,
4284 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
4285 # If the service account is undeleted, this value reverts to
4286 # `serviceAccount:{emailid}` and the undeleted service account retains the
4287 # role in the binding.
4288 #
4289 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
4290 # identifier) representing a Google group that has been recently
4291 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
4292 # the group is recovered, this value reverts to `group:{emailid}` and the
4293 # recovered group retains the role in the binding.
4294 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004295 #
4296 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
4297 # users of that domain. For example, `google.com` or `example.com`.
4298 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004299 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004300 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004301 },
4302 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004303 },
4304 }
4305
4306 x__xgafv: string, V1 error format.
4307 Allowed values
4308 1 - v1 error format
4309 2 - v2 error format
4310
4311Returns:
4312 An object of the form:
4313
Dan O'Mearadd494642020-05-01 07:42:23 -07004314 { # An Identity and Access Management (IAM) policy, which specifies access
4315 # controls for Google Cloud resources.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004316 #
4317 #
Dan O'Mearadd494642020-05-01 07:42:23 -07004318 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
4319 # `members` to a single `role`. Members can be user accounts, service accounts,
4320 # Google groups, and domains (such as G Suite). A `role` is a named list of
4321 # permissions; each `role` can be an IAM predefined role or a user-created
4322 # custom role.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004323 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004324 # For some types of Google Cloud resources, a `binding` can also specify a
4325 # `condition`, which is a logical expression that allows access to a resource
4326 # only if the expression evaluates to `true`. A condition can add constraints
4327 # based on attributes of the request, the resource, or both. To learn which
4328 # resources support conditions in their IAM policies, see the
4329 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -07004330 #
4331 # **JSON example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004332 #
4333 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07004334 # &quot;bindings&quot;: [
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004335 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07004336 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
4337 # &quot;members&quot;: [
4338 # &quot;user:mike@example.com&quot;,
4339 # &quot;group:admins@example.com&quot;,
4340 # &quot;domain:google.com&quot;,
4341 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004342 # ]
4343 # },
4344 # {
Bu Sun Kim65020912020-05-20 12:08:20 -07004345 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
4346 # &quot;members&quot;: [
4347 # &quot;user:eve@example.com&quot;
4348 # ],
4349 # &quot;condition&quot;: {
4350 # &quot;title&quot;: &quot;expirable access&quot;,
4351 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
4352 # &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -07004353 # }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004354 # }
Dan O'Mearadd494642020-05-01 07:42:23 -07004355 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004356 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
4357 # &quot;version&quot;: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004358 # }
4359 #
Dan O'Mearadd494642020-05-01 07:42:23 -07004360 # **YAML example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004361 #
4362 # bindings:
4363 # - members:
4364 # - user:mike@example.com
4365 # - group:admins@example.com
4366 # - domain:google.com
Dan O'Mearadd494642020-05-01 07:42:23 -07004367 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
4368 # role: roles/resourcemanager.organizationAdmin
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004369 # - members:
Dan O'Mearadd494642020-05-01 07:42:23 -07004370 # - user:eve@example.com
4371 # role: roles/resourcemanager.organizationViewer
4372 # condition:
4373 # title: expirable access
4374 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -07004375 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -07004376 # - etag: BwWWja0YfJA=
4377 # - version: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004378 #
4379 # For a description of IAM and its features, see the
Dan O'Mearadd494642020-05-01 07:42:23 -07004380 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim65020912020-05-20 12:08:20 -07004381 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
4382 # prevent simultaneous updates of a policy from overwriting each other.
4383 # It is strongly suggested that systems make use of the `etag` in the
4384 # read-modify-write cycle to perform policy updates in order to avoid race
4385 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
4386 # systems are expected to put that etag in the request to `setIamPolicy` to
4387 # ensure that their change will be applied to the same version of the policy.
4388 #
4389 # **Important:** If you use IAM Conditions, you must include the `etag` field
4390 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
4391 # you to overwrite a version `3` policy with a version `1` policy, and all of
4392 # the conditions in the version `3` policy are lost.
4393 &quot;version&quot;: 42, # Specifies the format of the policy.
4394 #
4395 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
4396 # are rejected.
4397 #
4398 # Any operation that affects conditional role bindings must specify version
4399 # `3`. This requirement applies to the following operations:
4400 #
4401 # * Getting a policy that includes a conditional role binding
4402 # * Adding a conditional role binding to a policy
4403 # * Changing a conditional role binding in a policy
4404 # * Removing any role binding, with or without a condition, from a policy
4405 # that includes conditions
4406 #
4407 # **Important:** If you use IAM Conditions, you must include the `etag` field
4408 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
4409 # you to overwrite a version `3` policy with a version `1` policy, and all of
4410 # the conditions in the version `3` policy are lost.
4411 #
4412 # If a policy does not include any conditions, operations on that policy may
4413 # specify any valid version or leave the field unset.
4414 #
4415 # To learn which resources support conditions in their IAM policies, see the
4416 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
4417 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -07004418 # `condition` that determines how and when the `bindings` are applied. Each
4419 # of the `bindings` must contain at least one member.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004420 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -07004421 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004422 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -07004423 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
4424 #
4425 # If the condition evaluates to `true`, then this binding applies to the
4426 # current request.
4427 #
4428 # If the condition evaluates to `false`, then this binding does not apply to
4429 # the current request. However, a different role binding might grant the same
4430 # role to one or more of the members in this binding.
4431 #
4432 # To learn which resources support conditions in their IAM policies, see the
4433 # [IAM
4434 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -07004435 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
4436 # are documented at https://github.com/google/cel-spec.
4437 #
4438 # Example (Comparison):
4439 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004440 # title: &quot;Summary size limit&quot;
4441 # description: &quot;Determines if a summary is less than 100 chars&quot;
4442 # expression: &quot;document.summary.size() &lt; 100&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07004443 #
4444 # Example (Equality):
4445 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004446 # title: &quot;Requestor is owner&quot;
4447 # description: &quot;Determines if requestor is the document owner&quot;
4448 # expression: &quot;document.owner == request.auth.claims.email&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07004449 #
4450 # Example (Logic):
4451 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004452 # title: &quot;Public documents&quot;
4453 # description: &quot;Determine whether the document should be publicly visible&quot;
4454 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07004455 #
4456 # Example (Data Manipulation):
4457 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004458 # title: &quot;Notification string&quot;
4459 # description: &quot;Create a notification string with a timestamp.&quot;
4460 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -07004461 #
4462 # The exact variables and functions that may be referenced within an expression
4463 # are determined by the service that evaluates it. See the service
4464 # documentation for additional information.
Bu Sun Kim65020912020-05-20 12:08:20 -07004465 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
Dan O'Mearadd494642020-05-01 07:42:23 -07004466 # its purpose. This can be used e.g. in UIs which allow to enter the
4467 # expression.
Bu Sun Kim65020912020-05-20 12:08:20 -07004468 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
4469 # reporting, e.g. a file name and a position in the file.
4470 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
4471 # describes the expression, e.g. when hovered over it in a UI.
4472 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
4473 # syntax.
Dan O'Mearadd494642020-05-01 07:42:23 -07004474 },
Bu Sun Kim65020912020-05-20 12:08:20 -07004475 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004476 # `members` can have the following values:
4477 #
4478 # * `allUsers`: A special identifier that represents anyone who is
4479 # on the internet; with or without a Google account.
4480 #
4481 # * `allAuthenticatedUsers`: A special identifier that represents anyone
4482 # who is authenticated with a Google account or a service account.
4483 #
4484 # * `user:{emailid}`: An email address that represents a specific Google
Dan O'Mearadd494642020-05-01 07:42:23 -07004485 # account. For example, `alice@example.com` .
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004486 #
4487 #
4488 # * `serviceAccount:{emailid}`: An email address that represents a service
4489 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
4490 #
4491 # * `group:{emailid}`: An email address that represents a Google group.
4492 # For example, `admins@example.com`.
4493 #
Dan O'Mearadd494642020-05-01 07:42:23 -07004494 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
4495 # identifier) representing a user that has been recently deleted. For
4496 # example, `alice@example.com?uid=123456789012345678901`. If the user is
4497 # recovered, this value reverts to `user:{emailid}` and the recovered user
4498 # retains the role in the binding.
4499 #
4500 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
4501 # unique identifier) representing a service account that has been recently
4502 # deleted. For example,
4503 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
4504 # If the service account is undeleted, this value reverts to
4505 # `serviceAccount:{emailid}` and the undeleted service account retains the
4506 # role in the binding.
4507 #
4508 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
4509 # identifier) representing a Google group that has been recently
4510 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
4511 # the group is recovered, this value reverts to `group:{emailid}` and the
4512 # recovered group retains the role in the binding.
4513 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004514 #
4515 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
4516 # users of that domain. For example, `google.com` or `example.com`.
4517 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004518 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004519 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004520 },
4521 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004522 }</pre>
4523</div>
4524
4525<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07004526 <code class="details" id="testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004527 <pre>Returns permissions that a caller has on a Queue.
4528If the resource does not exist, this will return an empty set of
4529permissions, not a NOT_FOUND error.
4530
4531Note: This operation is designed to be used for building permission-aware
4532UIs and command-line tools, not for authorization checking. This operation
Bu Sun Kim65020912020-05-20 12:08:20 -07004533may &quot;fail open&quot; without warning.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004534
4535Args:
4536 resource: string, REQUIRED: The resource for which the policy detail is being requested.
4537See the operation documentation for the appropriate value for this field. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07004538 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004539 The object takes the form of:
4540
4541{ # Request message for `TestIamPermissions` method.
Bu Sun Kim65020912020-05-20 12:08:20 -07004542 &quot;permissions&quot;: [ # The set of permissions to check for the `resource`. Permissions with
4543 # wildcards (such as &#x27;*&#x27; or &#x27;storage.*&#x27;) are not allowed. For more
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004544 # information see
4545 # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
Bu Sun Kim65020912020-05-20 12:08:20 -07004546 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004547 ],
4548 }
4549
4550 x__xgafv: string, V1 error format.
4551 Allowed values
4552 1 - v1 error format
4553 2 - v2 error format
4554
4555Returns:
4556 An object of the form:
4557
4558 { # Response message for `TestIamPermissions` method.
Bu Sun Kim65020912020-05-20 12:08:20 -07004559 &quot;permissions&quot;: [ # A subset of `TestPermissionsRequest.permissions` that the caller is
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004560 # allowed.
Bu Sun Kim65020912020-05-20 12:08:20 -07004561 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004562 ],
4563 }</pre>
4564</div>
4565
4566</body></html>