• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<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_v2beta3.html">Cloud Tasks API</a> . <a href="cloudtasks_v2beta3.projects.html">projects</a> . <a href="cloudtasks_v2beta3.projects.locations.html">locations</a> . <a href="cloudtasks_v2beta3.projects.locations.queues.html">queues</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78  <code><a href="cloudtasks_v2beta3.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">
83  <code><a href="#create">create(parent, body, x__xgafv=None)</a></code></p>
84<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">
89  <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
90<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">
95  <code><a href="#list">list(parent, pageToken=None, x__xgafv=None, pageSize=None, filter=None)</a></code></p>
96<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">
101  <code><a href="#patch">patch(name, body, updateMask=None, x__xgafv=None)</a></code></p>
102<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">
113  <code><a href="#setIamPolicy">setIamPolicy(resource, body, x__xgafv=None)</a></code></p>
114<p class="firstline">Sets the access control policy for a Queue. Replaces any existing</p>
115<p class="toc_element">
116  <code><a href="#testIamPermissions">testIamPermissions(resource, body, x__xgafv=None)</a></code></p>
117<p class="firstline">Returns permissions that a caller has on a Queue.</p>
118<h3>Method Details</h3>
119<div class="method">
120    <code class="details" id="create">create(parent, body, x__xgafv=None)</code>
121  <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:
135  parent: string, Required.
136
137The location name in which the queue will be created.
138For example: `projects/PROJECT_ID/locations/LOCATION_ID`
139
140The list of allowed locations can be obtained by calling Cloud
141Tasks' implementation of
142ListLocations. (required)
143  body: object, The request body. (required)
144    The object takes the form of:
145
146{ # A queue is a container of related tasks. Queues are configured to manage
147    # how those tasks are dispatched. Configurable properties include rate limits,
148    # retry options, queue types, and others.
149  "name": "A String", # Caller-specified and required in CreateQueue,
150      # after which it becomes output only.
151      #
152      # The queue name.
153      #
154      # The queue name must have the following format:
155      # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
156      #
157      # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
158      #    hyphens (-), colons (:), or periods (.).
159      #    For more information, see
160      #    [Identifying
161      #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
162      # * `LOCATION_ID` is the canonical ID for the queue's location.
163      #    The list of available locations can be obtained by calling
164      #    ListLocations.
165      #    For more information, see https://cloud.google.com/about/locations/.
166      # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
167      #   hyphens (-). The maximum length is 100 characters.
168  "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
169      # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
170      # field is unset, then no logs are written.
171      # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
172    "samplingRatio": 3.14, # Specifies the fraction of operations to write to
173        # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
174        # This field may contain any value between 0.0 and 1.0, inclusive.
175        # 0.0 is the default and means that no operations are logged.
176  },
177  "rateLimits": { # Rate limits. # Rate limits for task dispatches.
178      #
179      # rate_limits and retry_config are
180      # related because they both control task attempts. However they control task
181      # attempts in different ways:
182      #
183      # * rate_limits controls the total rate of
184      #   dispatches from a queue (i.e. all traffic dispatched from the
185      #   queue, regardless of whether the dispatch is from a first
186      #   attempt or a retry).
187      # * retry_config controls what happens to
188      #   particular a task after its first attempt fails. That is,
189      #   retry_config controls task retries (the
190      #   second attempt, third attempt, etc).
191      #
192      # The queue's actual dispatch rate is the result of:
193      #
194      # * Number of tasks in the queue
195      # * User-specified throttling: rate_limits,
196      #   retry_config, and the
197      #   queue's state.
198      # * System throttling due to `429` (Too Many Requests) or `503` (Service
199      #   Unavailable) responses from the worker, high error rates, or to smooth
200      #   sudden large traffic spikes.
201      #
202      # This message determines the maximum rate that tasks can be dispatched by a
203      # queue, regardless of whether the dispatch is a first task attempt or a retry.
204      #
205      # Note: The debugging command, RunTask, will run a task
206      # even if the queue has reached its RateLimits.
207    "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
208        # to be dispatched for this queue. After this threshold has been
209        # reached, Cloud Tasks stops dispatching tasks until the number of
210        # concurrent requests decreases.
211        #
212        # If unspecified when the queue is created, Cloud Tasks will pick the
213        # default.
214        #
215        #
216        # The maximum allowed value is 5,000.
217        #
218        #
219        # This field has the same meaning as
220        # [max_concurrent_requests in
221        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
222    "maxBurstSize": 42, # Output only. The max burst size.
223        #
224        # Max burst size limits how fast tasks in queue are processed when
225        # many tasks are in the queue and the rate is high. This field
226        # allows the queue to have a high rate so processing starts shortly
227        # after a task is enqueued, but still limits resource usage when
228        # many tasks are enqueued in a short period of time.
229        #
230        # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
231        # algorithm is used to control the rate of task dispatches. Each
232        # queue has a token bucket that holds tokens, up to the maximum
233        # specified by `max_burst_size`. Each time a task is dispatched, a
234        # token is removed from the bucket. Tasks will be dispatched until
235        # the queue's bucket runs out of tokens. The bucket will be
236        # continuously refilled with new tokens based on
237        # max_dispatches_per_second.
238        #
239        # Cloud Tasks will pick the value of `max_burst_size` based on the
240        # value of
241        # max_dispatches_per_second.
242        #
243        # For App Engine queues that were created or updated using
244        # `queue.yaml/xml`, `max_burst_size` is equal to
245        # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
246        # Since `max_burst_size` is output only, if
247        # UpdateQueue is called on a queue
248        # created by `queue.yaml/xml`, `max_burst_size` will be reset based
249        # on the value of
250        # max_dispatches_per_second,
251        # regardless of whether
252        # max_dispatches_per_second
253        # is updated.
254    "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
255        #
256        # If unspecified when the queue is created, Cloud Tasks will pick the
257        # default.
258        #
259        # * For App Engine queues, the maximum allowed value
260        #   is 500.
261        #
262        #
263        # This field has the same meaning as
264        # [rate in
265        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
266  },
267  "state": "A String", # Output only. The state of the queue.
268      #
269      # `state` can only be changed by called
270      # PauseQueue,
271      # ResumeQueue, or uploading
272      # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
273      # UpdateQueue cannot be used to change `state`.
274  "purgeTime": "A String", # Output only. The last time this queue was purged.
275      #
276      # All tasks that were created before this time
277      # were purged.
278      #
279      # A queue can be purged using PurgeQueue, the
280      # [App Engine Task Queue SDK, or the Cloud
281      # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
282      #
283      # Purge time will be truncated to the nearest microsecond. Purge
284      # time will be unset if the queue has never been purged.
285  "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
286      # App Engine tasks in this queue.
287      # Http tasks are not affected by this proto.
288      #
289      # The task will be delivered to the App Engine application hostname
290      # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
291      # The documentation for AppEngineHttpRequest explains how the
292      # task's host URL is constructed.
293      #
294      # Using AppEngineHttpQueue requires
295      # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
296      # Google IAM permission for the project
297      # and the following scope:
298      #
299      # `https://www.googleapis.com/auth/cloud-platform`
300    "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
301        # task-level app_engine_routing.
302        #
303        # If set, `app_engine_routing_override` is used for all tasks in
304        # the queue, no matter what the setting is for the
305        # task-level app_engine_routing.
306        #
307        # Defines routing characteristics specific to App Engine - service, version,
308        # and instance.
309        #
310        # For more information about services, versions, and instances see
311        # [An Overview of App
312        # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
313        # [Microservices Architecture on Google App
314        # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
315        # [App Engine Standard request
316        # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
317        # and [App Engine Flex request
318        # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
319      "instance": "A String", # App instance.
320          #
321          # By default, the task is sent to an instance which is available when
322          # the task is attempted.
323          #
324          # Requests can only be sent to a specific instance if
325          # [manual scaling is used in App Engine
326          # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
327          # App Engine Flex does not support instances. For more information, see
328          # [App Engine Standard request
329          # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
330          # and [App Engine Flex request
331          # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
332      "host": "A String", # Output only. The host that the task is sent to.
333          #
334          # The host is constructed from the domain name of the app associated with
335          # the queue's project ID (for example <app-id>.appspot.com), and the
336          # service, version,
337          # and instance. Tasks which were created using
338          # the App Engine SDK might have a custom domain name.
339          #
340          # For more information, see
341          # [How Requests are
342          # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
343      "version": "A String", # App version.
344          #
345          # By default, the task is sent to the version which is the default
346          # version when the task is attempted.
347          #
348          # For some queues or tasks which were created using the App Engine
349          # Task Queue API, host is not parsable
350          # into service,
351          # version, and
352          # instance. For example, some tasks
353          # which were created using the App Engine SDK use a custom domain
354          # name; custom domains are not parsed by Cloud Tasks. If
355          # host is not parsable, then
356          # service,
357          # version, and
358          # instance are the empty string.
359      "service": "A String", # App service.
360          #
361          # By default, the task is sent to the service which is the default
362          # service when the task is attempted.
363          #
364          # For some queues or tasks which were created using the App Engine
365          # Task Queue API, host is not parsable
366          # into service,
367          # version, and
368          # instance. For example, some tasks
369          # which were created using the App Engine SDK use a custom domain
370          # name; custom domains are not parsed by Cloud Tasks. If
371          # host is not parsable, then
372          # service,
373          # version, and
374          # instance are the empty string.
375    },
376  },
377  "retryConfig": { # Retry config. # Settings that determine the retry behavior.
378      #
379      # * For tasks created using Cloud Tasks: the queue-level retry settings
380      #   apply to all tasks in the queue that were created using Cloud Tasks.
381      #   Retry settings cannot be set on individual tasks.
382      # * For tasks created using the App Engine SDK: the queue-level retry
383      #   settings apply to all tasks in the queue which do not have retry settings
384      #   explicitly set on the task and were created by the App Engine SDK. See
385      #   [App Engine
386      #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
387      #
388      # These settings determine when a failed task attempt is retried.
389    "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
390        # retrying a failed task, measured from when the task was first
391        # attempted. Once `max_retry_duration` time has passed *and* the
392        # task has been attempted max_attempts
393        # times, no further attempts will be made and the task will be
394        # deleted.
395        #
396        # If zero, then the task age is unlimited.
397        #
398        # If unspecified when the queue is created, Cloud Tasks will pick the
399        # default.
400        #
401        #
402        # `max_retry_duration` will be truncated to the nearest second.
403        #
404        # This field has the same meaning as
405        # [task_age_limit in
406        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
407    "maxDoublings": 42, # The time between retries will double `max_doublings` times.
408        #
409        # A task's retry interval starts at
410        # min_backoff, then doubles
411        # `max_doublings` times, then increases linearly, and finally
412        # retries retries at intervals of
413        # max_backoff up to
414        # max_attempts times.
415        #
416        # For example, if min_backoff is 10s,
417        # max_backoff is 300s, and
418        # `max_doublings` is 3, then the a task will first be retried in
419        # 10s. The retry interval will double three times, and then
420        # increase linearly by 2^3 * 10s.  Finally, the task will retry at
421        # intervals of max_backoff until the
422        # task has been attempted max_attempts
423        # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
424        # 240s, 300s, 300s, ....
425        #
426        # If unspecified when the queue is created, Cloud Tasks will pick the
427        # default.
428        #
429        #
430        # This field has the same meaning as
431        # [max_doublings in
432        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
433    "maxAttempts": 42, # Number of attempts per task.
434        #
435        # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
436        # first attempt fails, then there will be `max_attempts - 1` retries). Must
437        # be >= -1.
438        #
439        # If unspecified when the queue is created, Cloud Tasks will pick the
440        # default.
441        #
442        # -1 indicates unlimited attempts.
443        #
444        # This field has the same meaning as
445        # [task_retry_limit in
446        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
447    "maxBackoff": "A String", # A task will be scheduled for retry between
448        # min_backoff and
449        # max_backoff duration after it fails,
450        # if the queue's RetryConfig specifies that the task should be
451        # retried.
452        #
453        # If unspecified when the queue is created, Cloud Tasks will pick the
454        # default.
455        #
456        #
457        # `max_backoff` will be truncated to the nearest second.
458        #
459        # This field has the same meaning as
460        # [max_backoff_seconds in
461        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
462    "minBackoff": "A String", # A task will be scheduled for retry between
463        # min_backoff and
464        # max_backoff duration after it fails,
465        # if the queue's RetryConfig specifies that the task should be
466        # retried.
467        #
468        # If unspecified when the queue is created, Cloud Tasks will pick the
469        # default.
470        #
471        #
472        # `min_backoff` will be truncated to the nearest second.
473        #
474        # This field has the same meaning as
475        # [min_backoff_seconds in
476        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
477  },
478}
479
480  x__xgafv: string, V1 error format.
481    Allowed values
482      1 - v1 error format
483      2 - v2 error format
484
485Returns:
486  An object of the form:
487
488    { # A queue is a container of related tasks. Queues are configured to manage
489      # how those tasks are dispatched. Configurable properties include rate limits,
490      # retry options, queue types, and others.
491    "name": "A String", # Caller-specified and required in CreateQueue,
492        # after which it becomes output only.
493        #
494        # The queue name.
495        #
496        # The queue name must have the following format:
497        # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
498        #
499        # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
500        #    hyphens (-), colons (:), or periods (.).
501        #    For more information, see
502        #    [Identifying
503        #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
504        # * `LOCATION_ID` is the canonical ID for the queue's location.
505        #    The list of available locations can be obtained by calling
506        #    ListLocations.
507        #    For more information, see https://cloud.google.com/about/locations/.
508        # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
509        #   hyphens (-). The maximum length is 100 characters.
510    "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
511        # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
512        # field is unset, then no logs are written.
513        # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
514      "samplingRatio": 3.14, # Specifies the fraction of operations to write to
515          # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
516          # This field may contain any value between 0.0 and 1.0, inclusive.
517          # 0.0 is the default and means that no operations are logged.
518    },
519    "rateLimits": { # Rate limits. # Rate limits for task dispatches.
520        #
521        # rate_limits and retry_config are
522        # related because they both control task attempts. However they control task
523        # attempts in different ways:
524        #
525        # * rate_limits controls the total rate of
526        #   dispatches from a queue (i.e. all traffic dispatched from the
527        #   queue, regardless of whether the dispatch is from a first
528        #   attempt or a retry).
529        # * retry_config controls what happens to
530        #   particular a task after its first attempt fails. That is,
531        #   retry_config controls task retries (the
532        #   second attempt, third attempt, etc).
533        #
534        # The queue's actual dispatch rate is the result of:
535        #
536        # * Number of tasks in the queue
537        # * User-specified throttling: rate_limits,
538        #   retry_config, and the
539        #   queue's state.
540        # * System throttling due to `429` (Too Many Requests) or `503` (Service
541        #   Unavailable) responses from the worker, high error rates, or to smooth
542        #   sudden large traffic spikes.
543        #
544        # This message determines the maximum rate that tasks can be dispatched by a
545        # queue, regardless of whether the dispatch is a first task attempt or a retry.
546        #
547        # Note: The debugging command, RunTask, will run a task
548        # even if the queue has reached its RateLimits.
549      "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
550          # to be dispatched for this queue. After this threshold has been
551          # reached, Cloud Tasks stops dispatching tasks until the number of
552          # concurrent requests decreases.
553          #
554          # If unspecified when the queue is created, Cloud Tasks will pick the
555          # default.
556          #
557          #
558          # The maximum allowed value is 5,000.
559          #
560          #
561          # This field has the same meaning as
562          # [max_concurrent_requests in
563          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
564      "maxBurstSize": 42, # Output only. The max burst size.
565          #
566          # Max burst size limits how fast tasks in queue are processed when
567          # many tasks are in the queue and the rate is high. This field
568          # allows the queue to have a high rate so processing starts shortly
569          # after a task is enqueued, but still limits resource usage when
570          # many tasks are enqueued in a short period of time.
571          #
572          # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
573          # algorithm is used to control the rate of task dispatches. Each
574          # queue has a token bucket that holds tokens, up to the maximum
575          # specified by `max_burst_size`. Each time a task is dispatched, a
576          # token is removed from the bucket. Tasks will be dispatched until
577          # the queue's bucket runs out of tokens. The bucket will be
578          # continuously refilled with new tokens based on
579          # max_dispatches_per_second.
580          #
581          # Cloud Tasks will pick the value of `max_burst_size` based on the
582          # value of
583          # max_dispatches_per_second.
584          #
585          # For App Engine queues that were created or updated using
586          # `queue.yaml/xml`, `max_burst_size` is equal to
587          # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
588          # Since `max_burst_size` is output only, if
589          # UpdateQueue is called on a queue
590          # created by `queue.yaml/xml`, `max_burst_size` will be reset based
591          # on the value of
592          # max_dispatches_per_second,
593          # regardless of whether
594          # max_dispatches_per_second
595          # is updated.
596      "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
597          #
598          # If unspecified when the queue is created, Cloud Tasks will pick the
599          # default.
600          #
601          # * For App Engine queues, the maximum allowed value
602          #   is 500.
603          #
604          #
605          # This field has the same meaning as
606          # [rate in
607          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
608    },
609    "state": "A String", # Output only. The state of the queue.
610        #
611        # `state` can only be changed by called
612        # PauseQueue,
613        # ResumeQueue, or uploading
614        # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
615        # UpdateQueue cannot be used to change `state`.
616    "purgeTime": "A String", # Output only. The last time this queue was purged.
617        #
618        # All tasks that were created before this time
619        # were purged.
620        #
621        # A queue can be purged using PurgeQueue, the
622        # [App Engine Task Queue SDK, or the Cloud
623        # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
624        #
625        # Purge time will be truncated to the nearest microsecond. Purge
626        # time will be unset if the queue has never been purged.
627    "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
628        # App Engine tasks in this queue.
629        # Http tasks are not affected by this proto.
630        #
631        # The task will be delivered to the App Engine application hostname
632        # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
633        # The documentation for AppEngineHttpRequest explains how the
634        # task's host URL is constructed.
635        #
636        # Using AppEngineHttpQueue requires
637        # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
638        # Google IAM permission for the project
639        # and the following scope:
640        #
641        # `https://www.googleapis.com/auth/cloud-platform`
642      "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
643          # task-level app_engine_routing.
644          #
645          # If set, `app_engine_routing_override` is used for all tasks in
646          # the queue, no matter what the setting is for the
647          # task-level app_engine_routing.
648          #
649          # Defines routing characteristics specific to App Engine - service, version,
650          # and instance.
651          #
652          # For more information about services, versions, and instances see
653          # [An Overview of App
654          # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
655          # [Microservices Architecture on Google App
656          # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
657          # [App Engine Standard request
658          # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
659          # and [App Engine Flex request
660          # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
661        "instance": "A String", # App instance.
662            #
663            # By default, the task is sent to an instance which is available when
664            # the task is attempted.
665            #
666            # Requests can only be sent to a specific instance if
667            # [manual scaling is used in App Engine
668            # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
669            # App Engine Flex does not support instances. For more information, see
670            # [App Engine Standard request
671            # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
672            # and [App Engine Flex request
673            # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
674        "host": "A String", # Output only. The host that the task is sent to.
675            #
676            # The host is constructed from the domain name of the app associated with
677            # the queue's project ID (for example <app-id>.appspot.com), and the
678            # service, version,
679            # and instance. Tasks which were created using
680            # the App Engine SDK might have a custom domain name.
681            #
682            # For more information, see
683            # [How Requests are
684            # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
685        "version": "A String", # App version.
686            #
687            # By default, the task is sent to the version which is the default
688            # version when the task is attempted.
689            #
690            # For some queues or tasks which were created using the App Engine
691            # Task Queue API, host is not parsable
692            # into service,
693            # version, and
694            # instance. For example, some tasks
695            # which were created using the App Engine SDK use a custom domain
696            # name; custom domains are not parsed by Cloud Tasks. If
697            # host is not parsable, then
698            # service,
699            # version, and
700            # instance are the empty string.
701        "service": "A String", # App service.
702            #
703            # By default, the task is sent to the service which is the default
704            # service when the task is attempted.
705            #
706            # For some queues or tasks which were created using the App Engine
707            # Task Queue API, host is not parsable
708            # into service,
709            # version, and
710            # instance. For example, some tasks
711            # which were created using the App Engine SDK use a custom domain
712            # name; custom domains are not parsed by Cloud Tasks. If
713            # host is not parsable, then
714            # service,
715            # version, and
716            # instance are the empty string.
717      },
718    },
719    "retryConfig": { # Retry config. # Settings that determine the retry behavior.
720        #
721        # * For tasks created using Cloud Tasks: the queue-level retry settings
722        #   apply to all tasks in the queue that were created using Cloud Tasks.
723        #   Retry settings cannot be set on individual tasks.
724        # * For tasks created using the App Engine SDK: the queue-level retry
725        #   settings apply to all tasks in the queue which do not have retry settings
726        #   explicitly set on the task and were created by the App Engine SDK. See
727        #   [App Engine
728        #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
729        #
730        # These settings determine when a failed task attempt is retried.
731      "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
732          # retrying a failed task, measured from when the task was first
733          # attempted. Once `max_retry_duration` time has passed *and* the
734          # task has been attempted max_attempts
735          # times, no further attempts will be made and the task will be
736          # deleted.
737          #
738          # If zero, then the task age is unlimited.
739          #
740          # If unspecified when the queue is created, Cloud Tasks will pick the
741          # default.
742          #
743          #
744          # `max_retry_duration` will be truncated to the nearest second.
745          #
746          # This field has the same meaning as
747          # [task_age_limit in
748          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
749      "maxDoublings": 42, # The time between retries will double `max_doublings` times.
750          #
751          # A task's retry interval starts at
752          # min_backoff, then doubles
753          # `max_doublings` times, then increases linearly, and finally
754          # retries retries at intervals of
755          # max_backoff up to
756          # max_attempts times.
757          #
758          # For example, if min_backoff is 10s,
759          # max_backoff is 300s, and
760          # `max_doublings` is 3, then the a task will first be retried in
761          # 10s. The retry interval will double three times, and then
762          # increase linearly by 2^3 * 10s.  Finally, the task will retry at
763          # intervals of max_backoff until the
764          # task has been attempted max_attempts
765          # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
766          # 240s, 300s, 300s, ....
767          #
768          # If unspecified when the queue is created, Cloud Tasks will pick the
769          # default.
770          #
771          #
772          # This field has the same meaning as
773          # [max_doublings in
774          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
775      "maxAttempts": 42, # Number of attempts per task.
776          #
777          # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
778          # first attempt fails, then there will be `max_attempts - 1` retries). Must
779          # be >= -1.
780          #
781          # If unspecified when the queue is created, Cloud Tasks will pick the
782          # default.
783          #
784          # -1 indicates unlimited attempts.
785          #
786          # This field has the same meaning as
787          # [task_retry_limit in
788          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
789      "maxBackoff": "A String", # A task will be scheduled for retry between
790          # min_backoff and
791          # max_backoff duration after it fails,
792          # if the queue's RetryConfig specifies that the task should be
793          # retried.
794          #
795          # If unspecified when the queue is created, Cloud Tasks will pick the
796          # default.
797          #
798          #
799          # `max_backoff` will be truncated to the nearest second.
800          #
801          # This field has the same meaning as
802          # [max_backoff_seconds in
803          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
804      "minBackoff": "A String", # A task will be scheduled for retry between
805          # min_backoff and
806          # max_backoff duration after it fails,
807          # if the queue's RetryConfig specifies that the task should be
808          # retried.
809          #
810          # If unspecified when the queue is created, Cloud Tasks will pick the
811          # default.
812          #
813          #
814          # `min_backoff` will be truncated to the nearest second.
815          #
816          # This field has the same meaning as
817          # [min_backoff_seconds in
818          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
819    },
820  }</pre>
821</div>
822
823<div class="method">
824    <code class="details" id="delete">delete(name, x__xgafv=None)</code>
825  <pre>Deletes a queue.
826
827This command will delete the queue even if it has tasks in it.
828
829Note: If you delete a queue, a queue with the same name can't be created
830for 7 days.
831
832WARNING: Using this method may have unintended side effects if you are
833using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
834Read
835[Overview of Queue Management and
836queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
837this method.
838
839Args:
840  name: string, Required.
841
842The queue name. For example:
843`projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` (required)
844  x__xgafv: string, V1 error format.
845    Allowed values
846      1 - v1 error format
847      2 - v2 error format
848
849Returns:
850  An object of the form:
851
852    { # A generic empty message that you can re-use to avoid defining duplicated
853      # empty messages in your APIs. A typical example is to use it as the request
854      # or the response type of an API method. For instance:
855      #
856      #     service Foo {
857      #       rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
858      #     }
859      #
860      # The JSON representation for `Empty` is empty JSON object `{}`.
861  }</pre>
862</div>
863
864<div class="method">
865    <code class="details" id="get">get(name, x__xgafv=None)</code>
866  <pre>Gets a queue.
867
868Args:
869  name: string, Required.
870
871The resource name of the queue. For example:
872`projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID` (required)
873  x__xgafv: string, V1 error format.
874    Allowed values
875      1 - v1 error format
876      2 - v2 error format
877
878Returns:
879  An object of the form:
880
881    { # A queue is a container of related tasks. Queues are configured to manage
882      # how those tasks are dispatched. Configurable properties include rate limits,
883      # retry options, queue types, and others.
884    "name": "A String", # Caller-specified and required in CreateQueue,
885        # after which it becomes output only.
886        #
887        # The queue name.
888        #
889        # The queue name must have the following format:
890        # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
891        #
892        # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
893        #    hyphens (-), colons (:), or periods (.).
894        #    For more information, see
895        #    [Identifying
896        #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
897        # * `LOCATION_ID` is the canonical ID for the queue's location.
898        #    The list of available locations can be obtained by calling
899        #    ListLocations.
900        #    For more information, see https://cloud.google.com/about/locations/.
901        # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
902        #   hyphens (-). The maximum length is 100 characters.
903    "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
904        # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
905        # field is unset, then no logs are written.
906        # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
907      "samplingRatio": 3.14, # Specifies the fraction of operations to write to
908          # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
909          # This field may contain any value between 0.0 and 1.0, inclusive.
910          # 0.0 is the default and means that no operations are logged.
911    },
912    "rateLimits": { # Rate limits. # Rate limits for task dispatches.
913        #
914        # rate_limits and retry_config are
915        # related because they both control task attempts. However they control task
916        # attempts in different ways:
917        #
918        # * rate_limits controls the total rate of
919        #   dispatches from a queue (i.e. all traffic dispatched from the
920        #   queue, regardless of whether the dispatch is from a first
921        #   attempt or a retry).
922        # * retry_config controls what happens to
923        #   particular a task after its first attempt fails. That is,
924        #   retry_config controls task retries (the
925        #   second attempt, third attempt, etc).
926        #
927        # The queue's actual dispatch rate is the result of:
928        #
929        # * Number of tasks in the queue
930        # * User-specified throttling: rate_limits,
931        #   retry_config, and the
932        #   queue's state.
933        # * System throttling due to `429` (Too Many Requests) or `503` (Service
934        #   Unavailable) responses from the worker, high error rates, or to smooth
935        #   sudden large traffic spikes.
936        #
937        # This message determines the maximum rate that tasks can be dispatched by a
938        # queue, regardless of whether the dispatch is a first task attempt or a retry.
939        #
940        # Note: The debugging command, RunTask, will run a task
941        # even if the queue has reached its RateLimits.
942      "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
943          # to be dispatched for this queue. After this threshold has been
944          # reached, Cloud Tasks stops dispatching tasks until the number of
945          # concurrent requests decreases.
946          #
947          # If unspecified when the queue is created, Cloud Tasks will pick the
948          # default.
949          #
950          #
951          # The maximum allowed value is 5,000.
952          #
953          #
954          # This field has the same meaning as
955          # [max_concurrent_requests in
956          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
957      "maxBurstSize": 42, # Output only. The max burst size.
958          #
959          # Max burst size limits how fast tasks in queue are processed when
960          # many tasks are in the queue and the rate is high. This field
961          # allows the queue to have a high rate so processing starts shortly
962          # after a task is enqueued, but still limits resource usage when
963          # many tasks are enqueued in a short period of time.
964          #
965          # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
966          # algorithm is used to control the rate of task dispatches. Each
967          # queue has a token bucket that holds tokens, up to the maximum
968          # specified by `max_burst_size`. Each time a task is dispatched, a
969          # token is removed from the bucket. Tasks will be dispatched until
970          # the queue's bucket runs out of tokens. The bucket will be
971          # continuously refilled with new tokens based on
972          # max_dispatches_per_second.
973          #
974          # Cloud Tasks will pick the value of `max_burst_size` based on the
975          # value of
976          # max_dispatches_per_second.
977          #
978          # For App Engine queues that were created or updated using
979          # `queue.yaml/xml`, `max_burst_size` is equal to
980          # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
981          # Since `max_burst_size` is output only, if
982          # UpdateQueue is called on a queue
983          # created by `queue.yaml/xml`, `max_burst_size` will be reset based
984          # on the value of
985          # max_dispatches_per_second,
986          # regardless of whether
987          # max_dispatches_per_second
988          # is updated.
989      "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
990          #
991          # If unspecified when the queue is created, Cloud Tasks will pick the
992          # default.
993          #
994          # * For App Engine queues, the maximum allowed value
995          #   is 500.
996          #
997          #
998          # This field has the same meaning as
999          # [rate in
1000          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
1001    },
1002    "state": "A String", # Output only. The state of the queue.
1003        #
1004        # `state` can only be changed by called
1005        # PauseQueue,
1006        # ResumeQueue, or uploading
1007        # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
1008        # UpdateQueue cannot be used to change `state`.
1009    "purgeTime": "A String", # Output only. The last time this queue was purged.
1010        #
1011        # All tasks that were created before this time
1012        # were purged.
1013        #
1014        # A queue can be purged using PurgeQueue, the
1015        # [App Engine Task Queue SDK, or the Cloud
1016        # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
1017        #
1018        # Purge time will be truncated to the nearest microsecond. Purge
1019        # time will be unset if the queue has never been purged.
1020    "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
1021        # App Engine tasks in this queue.
1022        # Http tasks are not affected by this proto.
1023        #
1024        # The task will be delivered to the App Engine application hostname
1025        # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
1026        # The documentation for AppEngineHttpRequest explains how the
1027        # task's host URL is constructed.
1028        #
1029        # Using AppEngineHttpQueue requires
1030        # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
1031        # Google IAM permission for the project
1032        # and the following scope:
1033        #
1034        # `https://www.googleapis.com/auth/cloud-platform`
1035      "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
1036          # task-level app_engine_routing.
1037          #
1038          # If set, `app_engine_routing_override` is used for all tasks in
1039          # the queue, no matter what the setting is for the
1040          # task-level app_engine_routing.
1041          #
1042          # Defines routing characteristics specific to App Engine - service, version,
1043          # and instance.
1044          #
1045          # For more information about services, versions, and instances see
1046          # [An Overview of App
1047          # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
1048          # [Microservices Architecture on Google App
1049          # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
1050          # [App Engine Standard request
1051          # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
1052          # and [App Engine Flex request
1053          # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
1054        "instance": "A String", # App instance.
1055            #
1056            # By default, the task is sent to an instance which is available when
1057            # the task is attempted.
1058            #
1059            # Requests can only be sent to a specific instance if
1060            # [manual scaling is used in App Engine
1061            # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
1062            # App Engine Flex does not support instances. For more information, see
1063            # [App Engine Standard request
1064            # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
1065            # and [App Engine Flex request
1066            # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
1067        "host": "A String", # Output only. The host that the task is sent to.
1068            #
1069            # The host is constructed from the domain name of the app associated with
1070            # the queue's project ID (for example <app-id>.appspot.com), and the
1071            # service, version,
1072            # and instance. Tasks which were created using
1073            # the App Engine SDK might have a custom domain name.
1074            #
1075            # For more information, see
1076            # [How Requests are
1077            # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
1078        "version": "A String", # App version.
1079            #
1080            # By default, the task is sent to the version which is the default
1081            # version when the task is attempted.
1082            #
1083            # For some queues or tasks which were created using the App Engine
1084            # Task Queue API, host is not parsable
1085            # into service,
1086            # version, and
1087            # instance. For example, some tasks
1088            # which were created using the App Engine SDK use a custom domain
1089            # name; custom domains are not parsed by Cloud Tasks. If
1090            # host is not parsable, then
1091            # service,
1092            # version, and
1093            # instance are the empty string.
1094        "service": "A String", # App service.
1095            #
1096            # By default, the task is sent to the service which is the default
1097            # service when the task is attempted.
1098            #
1099            # For some queues or tasks which were created using the App Engine
1100            # Task Queue API, host is not parsable
1101            # into service,
1102            # version, and
1103            # instance. For example, some tasks
1104            # which were created using the App Engine SDK use a custom domain
1105            # name; custom domains are not parsed by Cloud Tasks. If
1106            # host is not parsable, then
1107            # service,
1108            # version, and
1109            # instance are the empty string.
1110      },
1111    },
1112    "retryConfig": { # Retry config. # Settings that determine the retry behavior.
1113        #
1114        # * For tasks created using Cloud Tasks: the queue-level retry settings
1115        #   apply to all tasks in the queue that were created using Cloud Tasks.
1116        #   Retry settings cannot be set on individual tasks.
1117        # * For tasks created using the App Engine SDK: the queue-level retry
1118        #   settings apply to all tasks in the queue which do not have retry settings
1119        #   explicitly set on the task and were created by the App Engine SDK. See
1120        #   [App Engine
1121        #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
1122        #
1123        # These settings determine when a failed task attempt is retried.
1124      "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
1125          # retrying a failed task, measured from when the task was first
1126          # attempted. Once `max_retry_duration` time has passed *and* the
1127          # task has been attempted max_attempts
1128          # times, no further attempts will be made and the task will be
1129          # deleted.
1130          #
1131          # If zero, then the task age is unlimited.
1132          #
1133          # If unspecified when the queue is created, Cloud Tasks will pick the
1134          # default.
1135          #
1136          #
1137          # `max_retry_duration` will be truncated to the nearest second.
1138          #
1139          # This field has the same meaning as
1140          # [task_age_limit in
1141          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1142      "maxDoublings": 42, # The time between retries will double `max_doublings` times.
1143          #
1144          # A task's retry interval starts at
1145          # min_backoff, then doubles
1146          # `max_doublings` times, then increases linearly, and finally
1147          # retries retries at intervals of
1148          # max_backoff up to
1149          # max_attempts times.
1150          #
1151          # For example, if min_backoff is 10s,
1152          # max_backoff is 300s, and
1153          # `max_doublings` is 3, then the a task will first be retried in
1154          # 10s. The retry interval will double three times, and then
1155          # increase linearly by 2^3 * 10s.  Finally, the task will retry at
1156          # intervals of max_backoff until the
1157          # task has been attempted max_attempts
1158          # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
1159          # 240s, 300s, 300s, ....
1160          #
1161          # If unspecified when the queue is created, Cloud Tasks will pick the
1162          # default.
1163          #
1164          #
1165          # This field has the same meaning as
1166          # [max_doublings in
1167          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1168      "maxAttempts": 42, # Number of attempts per task.
1169          #
1170          # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
1171          # first attempt fails, then there will be `max_attempts - 1` retries). Must
1172          # be >= -1.
1173          #
1174          # If unspecified when the queue is created, Cloud Tasks will pick the
1175          # default.
1176          #
1177          # -1 indicates unlimited attempts.
1178          #
1179          # This field has the same meaning as
1180          # [task_retry_limit in
1181          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1182      "maxBackoff": "A String", # A task will be scheduled for retry between
1183          # min_backoff and
1184          # max_backoff duration after it fails,
1185          # if the queue's RetryConfig specifies that the task should be
1186          # retried.
1187          #
1188          # If unspecified when the queue is created, Cloud Tasks will pick the
1189          # default.
1190          #
1191          #
1192          # `max_backoff` will be truncated to the nearest second.
1193          #
1194          # This field has the same meaning as
1195          # [max_backoff_seconds in
1196          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1197      "minBackoff": "A String", # A task will be scheduled for retry between
1198          # min_backoff and
1199          # max_backoff duration after it fails,
1200          # if the queue's RetryConfig specifies that the task should be
1201          # retried.
1202          #
1203          # If unspecified when the queue is created, Cloud Tasks will pick the
1204          # default.
1205          #
1206          #
1207          # `min_backoff` will be truncated to the nearest second.
1208          #
1209          # This field has the same meaning as
1210          # [min_backoff_seconds in
1211          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1212    },
1213  }</pre>
1214</div>
1215
1216<div class="method">
1217    <code class="details" id="getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</code>
1218  <pre>Gets the access control policy for a Queue.
1219Returns an empty policy if the resource exists and does not have a policy
1220set.
1221
1222Authorization requires the following
1223[Google IAM](https://cloud.google.com/iam) permission on the specified
1224resource parent:
1225
1226* `cloudtasks.queues.getIamPolicy`
1227
1228Args:
1229  resource: string, REQUIRED: The resource for which the policy is being requested.
1230See the operation documentation for the appropriate value for this field. (required)
1231  body: object, The request body.
1232    The object takes the form of:
1233
1234{ # Request message for `GetIamPolicy` method.
1235  }
1236
1237  x__xgafv: string, V1 error format.
1238    Allowed values
1239      1 - v1 error format
1240      2 - v2 error format
1241
1242Returns:
1243  An object of the form:
1244
1245    { # Defines an Identity and Access Management (IAM) policy. It is used to
1246      # specify access control policies for Cloud Platform resources.
1247      #
1248      #
1249      # A `Policy` consists of a list of `bindings`. A `binding` binds a list of
1250      # `members` to a `role`, where the members can be user accounts, Google groups,
1251      # Google domains, and service accounts. A `role` is a named list of permissions
1252      # defined by IAM.
1253      #
1254      # **JSON Example**
1255      #
1256      #     {
1257      #       "bindings": [
1258      #         {
1259      #           "role": "roles/owner",
1260      #           "members": [
1261      #             "user:mike@example.com",
1262      #             "group:admins@example.com",
1263      #             "domain:google.com",
1264      #             "serviceAccount:my-other-app@appspot.gserviceaccount.com"
1265      #           ]
1266      #         },
1267      #         {
1268      #           "role": "roles/viewer",
1269      #           "members": ["user:sean@example.com"]
1270      #         }
1271      #       ]
1272      #     }
1273      #
1274      # **YAML Example**
1275      #
1276      #     bindings:
1277      #     - members:
1278      #       - user:mike@example.com
1279      #       - group:admins@example.com
1280      #       - domain:google.com
1281      #       - serviceAccount:my-other-app@appspot.gserviceaccount.com
1282      #       role: roles/owner
1283      #     - members:
1284      #       - user:sean@example.com
1285      #       role: roles/viewer
1286      #
1287      #
1288      # For a description of IAM and its features, see the
1289      # [IAM developer's guide](https://cloud.google.com/iam/docs).
1290    "bindings": [ # Associates a list of `members` to a `role`.
1291        # `bindings` with no members will result in an error.
1292      { # Associates `members` with a `role`.
1293        "role": "A String", # Role that is assigned to `members`.
1294            # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
1295        "condition": { # Represents an expression text. Example: # The condition that is associated with this binding.
1296            # NOTE: An unsatisfied condition will not allow user access via current
1297            # binding. Different bindings, including their conditions, are examined
1298            # independently.
1299            #
1300            #     title: "User account presence"
1301            #     description: "Determines whether the request has a user account"
1302            #     expression: "size(request.user) > 0"
1303          "description": "A String", # An optional description of the expression. This is a longer text which
1304              # describes the expression, e.g. when hovered over it in a UI.
1305          "expression": "A String", # Textual representation of an expression in
1306              # Common Expression Language syntax.
1307              #
1308              # The application context of the containing message determines which
1309              # well-known feature set of CEL is supported.
1310          "location": "A String", # An optional string indicating the location of the expression for error
1311              # reporting, e.g. a file name and a position in the file.
1312          "title": "A String", # An optional title for the expression, i.e. a short string describing
1313              # its purpose. This can be used e.g. in UIs which allow to enter the
1314              # expression.
1315        },
1316        "members": [ # Specifies the identities requesting access for a Cloud Platform resource.
1317            # `members` can have the following values:
1318            #
1319            # * `allUsers`: A special identifier that represents anyone who is
1320            #    on the internet; with or without a Google account.
1321            #
1322            # * `allAuthenticatedUsers`: A special identifier that represents anyone
1323            #    who is authenticated with a Google account or a service account.
1324            #
1325            # * `user:{emailid}`: An email address that represents a specific Google
1326            #    account. For example, `alice@gmail.com` .
1327            #
1328            #
1329            # * `serviceAccount:{emailid}`: An email address that represents a service
1330            #    account. For example, `my-other-app@appspot.gserviceaccount.com`.
1331            #
1332            # * `group:{emailid}`: An email address that represents a Google group.
1333            #    For example, `admins@example.com`.
1334            #
1335            #
1336            # * `domain:{domain}`: The G Suite domain (primary) that represents all the
1337            #    users of that domain. For example, `google.com` or `example.com`.
1338            #
1339          "A String",
1340        ],
1341      },
1342    ],
1343    "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help
1344        # prevent simultaneous updates of a policy from overwriting each other.
1345        # It is strongly suggested that systems make use of the `etag` in the
1346        # read-modify-write cycle to perform policy updates in order to avoid race
1347        # conditions: An `etag` is returned in the response to `getIamPolicy`, and
1348        # systems are expected to put that etag in the request to `setIamPolicy` to
1349        # ensure that their change will be applied to the same version of the policy.
1350        #
1351        # If no `etag` is provided in the call to `setIamPolicy`, then the existing
1352        # policy is overwritten blindly.
1353    "version": 42, # Deprecated.
1354  }</pre>
1355</div>
1356
1357<div class="method">
1358    <code class="details" id="list">list(parent, pageToken=None, x__xgafv=None, pageSize=None, filter=None)</code>
1359  <pre>Lists queues.
1360
1361Queues are returned in lexicographical order.
1362
1363Args:
1364  parent: string, Required.
1365
1366The location name.
1367For example: `projects/PROJECT_ID/locations/LOCATION_ID` (required)
1368  pageToken: string, A token identifying the page of results to return.
1369
1370To request the first page results, page_token must be empty. To
1371request the next page of results, page_token must be the value of
1372next_page_token returned
1373from the previous call to ListQueues
1374method. It is an error to switch the value of the
1375filter while iterating through pages.
1376  x__xgafv: string, V1 error format.
1377    Allowed values
1378      1 - v1 error format
1379      2 - v2 error format
1380  pageSize: integer, Requested page size.
1381
1382The maximum page size is 9800. If unspecified, the page size will
1383be the maximum. Fewer queues than requested might be returned,
1384even if more queues exist; use the
1385next_page_token in the
1386response to determine if more queues exist.
1387  filter: string, `filter` can be used to specify a subset of queues. Any Queue
1388field can be used as a filter and several operators as supported.
1389For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as
1390described in
1391[Stackdriver's Advanced Logs
1392Filters](https://cloud.google.com/logging/docs/view/advanced_filters).
1393
1394Sample filter "state: PAUSED".
1395
1396Note that using filters might cause fewer queues than the
1397requested page_size to be returned.
1398
1399Returns:
1400  An object of the form:
1401
1402    { # Response message for ListQueues.
1403    "nextPageToken": "A String", # A token to retrieve next page of results.
1404        #
1405        # To return the next page of results, call
1406        # ListQueues with this value as the
1407        # page_token.
1408        #
1409        # If the next_page_token is empty, there are no more results.
1410        #
1411        # The page token is valid for only 2 hours.
1412    "queues": [ # The list of queues.
1413      { # A queue is a container of related tasks. Queues are configured to manage
1414          # how those tasks are dispatched. Configurable properties include rate limits,
1415          # retry options, queue types, and others.
1416        "name": "A String", # Caller-specified and required in CreateQueue,
1417            # after which it becomes output only.
1418            #
1419            # The queue name.
1420            #
1421            # The queue name must have the following format:
1422            # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
1423            #
1424            # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
1425            #    hyphens (-), colons (:), or periods (.).
1426            #    For more information, see
1427            #    [Identifying
1428            #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
1429            # * `LOCATION_ID` is the canonical ID for the queue's location.
1430            #    The list of available locations can be obtained by calling
1431            #    ListLocations.
1432            #    For more information, see https://cloud.google.com/about/locations/.
1433            # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
1434            #   hyphens (-). The maximum length is 100 characters.
1435        "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
1436            # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
1437            # field is unset, then no logs are written.
1438            # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
1439          "samplingRatio": 3.14, # Specifies the fraction of operations to write to
1440              # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
1441              # This field may contain any value between 0.0 and 1.0, inclusive.
1442              # 0.0 is the default and means that no operations are logged.
1443        },
1444        "rateLimits": { # Rate limits. # Rate limits for task dispatches.
1445            #
1446            # rate_limits and retry_config are
1447            # related because they both control task attempts. However they control task
1448            # attempts in different ways:
1449            #
1450            # * rate_limits controls the total rate of
1451            #   dispatches from a queue (i.e. all traffic dispatched from the
1452            #   queue, regardless of whether the dispatch is from a first
1453            #   attempt or a retry).
1454            # * retry_config controls what happens to
1455            #   particular a task after its first attempt fails. That is,
1456            #   retry_config controls task retries (the
1457            #   second attempt, third attempt, etc).
1458            #
1459            # The queue's actual dispatch rate is the result of:
1460            #
1461            # * Number of tasks in the queue
1462            # * User-specified throttling: rate_limits,
1463            #   retry_config, and the
1464            #   queue's state.
1465            # * System throttling due to `429` (Too Many Requests) or `503` (Service
1466            #   Unavailable) responses from the worker, high error rates, or to smooth
1467            #   sudden large traffic spikes.
1468            #
1469            # This message determines the maximum rate that tasks can be dispatched by a
1470            # queue, regardless of whether the dispatch is a first task attempt or a retry.
1471            #
1472            # Note: The debugging command, RunTask, will run a task
1473            # even if the queue has reached its RateLimits.
1474          "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
1475              # to be dispatched for this queue. After this threshold has been
1476              # reached, Cloud Tasks stops dispatching tasks until the number of
1477              # concurrent requests decreases.
1478              #
1479              # If unspecified when the queue is created, Cloud Tasks will pick the
1480              # default.
1481              #
1482              #
1483              # The maximum allowed value is 5,000.
1484              #
1485              #
1486              # This field has the same meaning as
1487              # [max_concurrent_requests in
1488              # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
1489          "maxBurstSize": 42, # Output only. The max burst size.
1490              #
1491              # Max burst size limits how fast tasks in queue are processed when
1492              # many tasks are in the queue and the rate is high. This field
1493              # allows the queue to have a high rate so processing starts shortly
1494              # after a task is enqueued, but still limits resource usage when
1495              # many tasks are enqueued in a short period of time.
1496              #
1497              # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
1498              # algorithm is used to control the rate of task dispatches. Each
1499              # queue has a token bucket that holds tokens, up to the maximum
1500              # specified by `max_burst_size`. Each time a task is dispatched, a
1501              # token is removed from the bucket. Tasks will be dispatched until
1502              # the queue's bucket runs out of tokens. The bucket will be
1503              # continuously refilled with new tokens based on
1504              # max_dispatches_per_second.
1505              #
1506              # Cloud Tasks will pick the value of `max_burst_size` based on the
1507              # value of
1508              # max_dispatches_per_second.
1509              #
1510              # For App Engine queues that were created or updated using
1511              # `queue.yaml/xml`, `max_burst_size` is equal to
1512              # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
1513              # Since `max_burst_size` is output only, if
1514              # UpdateQueue is called on a queue
1515              # created by `queue.yaml/xml`, `max_burst_size` will be reset based
1516              # on the value of
1517              # max_dispatches_per_second,
1518              # regardless of whether
1519              # max_dispatches_per_second
1520              # is updated.
1521          "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
1522              #
1523              # If unspecified when the queue is created, Cloud Tasks will pick the
1524              # default.
1525              #
1526              # * For App Engine queues, the maximum allowed value
1527              #   is 500.
1528              #
1529              #
1530              # This field has the same meaning as
1531              # [rate in
1532              # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
1533        },
1534        "state": "A String", # Output only. The state of the queue.
1535            #
1536            # `state` can only be changed by called
1537            # PauseQueue,
1538            # ResumeQueue, or uploading
1539            # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
1540            # UpdateQueue cannot be used to change `state`.
1541        "purgeTime": "A String", # Output only. The last time this queue was purged.
1542            #
1543            # All tasks that were created before this time
1544            # were purged.
1545            #
1546            # A queue can be purged using PurgeQueue, the
1547            # [App Engine Task Queue SDK, or the Cloud
1548            # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
1549            #
1550            # Purge time will be truncated to the nearest microsecond. Purge
1551            # time will be unset if the queue has never been purged.
1552        "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
1553            # App Engine tasks in this queue.
1554            # Http tasks are not affected by this proto.
1555            #
1556            # The task will be delivered to the App Engine application hostname
1557            # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
1558            # The documentation for AppEngineHttpRequest explains how the
1559            # task's host URL is constructed.
1560            #
1561            # Using AppEngineHttpQueue requires
1562            # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
1563            # Google IAM permission for the project
1564            # and the following scope:
1565            #
1566            # `https://www.googleapis.com/auth/cloud-platform`
1567          "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
1568              # task-level app_engine_routing.
1569              #
1570              # If set, `app_engine_routing_override` is used for all tasks in
1571              # the queue, no matter what the setting is for the
1572              # task-level app_engine_routing.
1573              #
1574              # Defines routing characteristics specific to App Engine - service, version,
1575              # and instance.
1576              #
1577              # For more information about services, versions, and instances see
1578              # [An Overview of App
1579              # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
1580              # [Microservices Architecture on Google App
1581              # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
1582              # [App Engine Standard request
1583              # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
1584              # and [App Engine Flex request
1585              # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
1586            "instance": "A String", # App instance.
1587                #
1588                # By default, the task is sent to an instance which is available when
1589                # the task is attempted.
1590                #
1591                # Requests can only be sent to a specific instance if
1592                # [manual scaling is used in App Engine
1593                # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
1594                # App Engine Flex does not support instances. For more information, see
1595                # [App Engine Standard request
1596                # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
1597                # and [App Engine Flex request
1598                # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
1599            "host": "A String", # Output only. The host that the task is sent to.
1600                #
1601                # The host is constructed from the domain name of the app associated with
1602                # the queue's project ID (for example <app-id>.appspot.com), and the
1603                # service, version,
1604                # and instance. Tasks which were created using
1605                # the App Engine SDK might have a custom domain name.
1606                #
1607                # For more information, see
1608                # [How Requests are
1609                # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
1610            "version": "A String", # App version.
1611                #
1612                # By default, the task is sent to the version which is the default
1613                # version when the task is attempted.
1614                #
1615                # For some queues or tasks which were created using the App Engine
1616                # Task Queue API, host is not parsable
1617                # into service,
1618                # version, and
1619                # instance. For example, some tasks
1620                # which were created using the App Engine SDK use a custom domain
1621                # name; custom domains are not parsed by Cloud Tasks. If
1622                # host is not parsable, then
1623                # service,
1624                # version, and
1625                # instance are the empty string.
1626            "service": "A String", # App service.
1627                #
1628                # By default, the task is sent to the service which is the default
1629                # service when the task is attempted.
1630                #
1631                # For some queues or tasks which were created using the App Engine
1632                # Task Queue API, host is not parsable
1633                # into service,
1634                # version, and
1635                # instance. For example, some tasks
1636                # which were created using the App Engine SDK use a custom domain
1637                # name; custom domains are not parsed by Cloud Tasks. If
1638                # host is not parsable, then
1639                # service,
1640                # version, and
1641                # instance are the empty string.
1642          },
1643        },
1644        "retryConfig": { # Retry config. # Settings that determine the retry behavior.
1645            #
1646            # * For tasks created using Cloud Tasks: the queue-level retry settings
1647            #   apply to all tasks in the queue that were created using Cloud Tasks.
1648            #   Retry settings cannot be set on individual tasks.
1649            # * For tasks created using the App Engine SDK: the queue-level retry
1650            #   settings apply to all tasks in the queue which do not have retry settings
1651            #   explicitly set on the task and were created by the App Engine SDK. See
1652            #   [App Engine
1653            #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
1654            #
1655            # These settings determine when a failed task attempt is retried.
1656          "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
1657              # retrying a failed task, measured from when the task was first
1658              # attempted. Once `max_retry_duration` time has passed *and* the
1659              # task has been attempted max_attempts
1660              # times, no further attempts will be made and the task will be
1661              # deleted.
1662              #
1663              # If zero, then the task age is unlimited.
1664              #
1665              # If unspecified when the queue is created, Cloud Tasks will pick the
1666              # default.
1667              #
1668              #
1669              # `max_retry_duration` will be truncated to the nearest second.
1670              #
1671              # This field has the same meaning as
1672              # [task_age_limit in
1673              # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1674          "maxDoublings": 42, # The time between retries will double `max_doublings` times.
1675              #
1676              # A task's retry interval starts at
1677              # min_backoff, then doubles
1678              # `max_doublings` times, then increases linearly, and finally
1679              # retries retries at intervals of
1680              # max_backoff up to
1681              # max_attempts times.
1682              #
1683              # For example, if min_backoff is 10s,
1684              # max_backoff is 300s, and
1685              # `max_doublings` is 3, then the a task will first be retried in
1686              # 10s. The retry interval will double three times, and then
1687              # increase linearly by 2^3 * 10s.  Finally, the task will retry at
1688              # intervals of max_backoff until the
1689              # task has been attempted max_attempts
1690              # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
1691              # 240s, 300s, 300s, ....
1692              #
1693              # If unspecified when the queue is created, Cloud Tasks will pick the
1694              # default.
1695              #
1696              #
1697              # This field has the same meaning as
1698              # [max_doublings in
1699              # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1700          "maxAttempts": 42, # Number of attempts per task.
1701              #
1702              # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
1703              # first attempt fails, then there will be `max_attempts - 1` retries). Must
1704              # be >= -1.
1705              #
1706              # If unspecified when the queue is created, Cloud Tasks will pick the
1707              # default.
1708              #
1709              # -1 indicates unlimited attempts.
1710              #
1711              # This field has the same meaning as
1712              # [task_retry_limit in
1713              # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1714          "maxBackoff": "A String", # A task will be scheduled for retry between
1715              # min_backoff and
1716              # max_backoff duration after it fails,
1717              # if the queue's RetryConfig specifies that the task should be
1718              # retried.
1719              #
1720              # If unspecified when the queue is created, Cloud Tasks will pick the
1721              # default.
1722              #
1723              #
1724              # `max_backoff` will be truncated to the nearest second.
1725              #
1726              # This field has the same meaning as
1727              # [max_backoff_seconds in
1728              # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1729          "minBackoff": "A String", # A task will be scheduled for retry between
1730              # min_backoff and
1731              # max_backoff duration after it fails,
1732              # if the queue's RetryConfig specifies that the task should be
1733              # retried.
1734              #
1735              # If unspecified when the queue is created, Cloud Tasks will pick the
1736              # default.
1737              #
1738              #
1739              # `min_backoff` will be truncated to the nearest second.
1740              #
1741              # This field has the same meaning as
1742              # [min_backoff_seconds in
1743              # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
1744        },
1745      },
1746    ],
1747  }</pre>
1748</div>
1749
1750<div class="method">
1751    <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
1752  <pre>Retrieves the next page of results.
1753
1754Args:
1755  previous_request: The request for the previous page. (required)
1756  previous_response: The response from the request for the previous page. (required)
1757
1758Returns:
1759  A request object that you can call 'execute()' on to request the next
1760  page. Returns None if there are no more items in the collection.
1761    </pre>
1762</div>
1763
1764<div class="method">
1765    <code class="details" id="patch">patch(name, body, updateMask=None, x__xgafv=None)</code>
1766  <pre>Updates a queue.
1767
1768This method creates the queue if it does not exist and updates
1769the queue if it does exist.
1770
1771Queues created with this method allow tasks to live for a maximum of 31
1772days. After a task is 31 days old, the task will be deleted regardless of whether
1773it was dispatched or not.
1774
1775WARNING: Using this method may have unintended side effects if you are
1776using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
1777Read
1778[Overview of Queue Management and
1779queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
1780this method.
1781
1782Args:
1783  name: string, Caller-specified and required in CreateQueue,
1784after which it becomes output only.
1785
1786The queue name.
1787
1788The queue name must have the following format:
1789`projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
1790
1791* `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
1792   hyphens (-), colons (:), or periods (.).
1793   For more information, see
1794   [Identifying
1795   projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
1796* `LOCATION_ID` is the canonical ID for the queue's location.
1797   The list of available locations can be obtained by calling
1798   ListLocations.
1799   For more information, see https://cloud.google.com/about/locations/.
1800* `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
1801  hyphens (-). The maximum length is 100 characters. (required)
1802  body: object, The request body. (required)
1803    The object takes the form of:
1804
1805{ # A queue is a container of related tasks. Queues are configured to manage
1806    # how those tasks are dispatched. Configurable properties include rate limits,
1807    # retry options, queue types, and others.
1808  "name": "A String", # Caller-specified and required in CreateQueue,
1809      # after which it becomes output only.
1810      #
1811      # The queue name.
1812      #
1813      # The queue name must have the following format:
1814      # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
1815      #
1816      # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
1817      #    hyphens (-), colons (:), or periods (.).
1818      #    For more information, see
1819      #    [Identifying
1820      #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
1821      # * `LOCATION_ID` is the canonical ID for the queue's location.
1822      #    The list of available locations can be obtained by calling
1823      #    ListLocations.
1824      #    For more information, see https://cloud.google.com/about/locations/.
1825      # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
1826      #   hyphens (-). The maximum length is 100 characters.
1827  "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
1828      # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
1829      # field is unset, then no logs are written.
1830      # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
1831    "samplingRatio": 3.14, # Specifies the fraction of operations to write to
1832        # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
1833        # This field may contain any value between 0.0 and 1.0, inclusive.
1834        # 0.0 is the default and means that no operations are logged.
1835  },
1836  "rateLimits": { # Rate limits. # Rate limits for task dispatches.
1837      #
1838      # rate_limits and retry_config are
1839      # related because they both control task attempts. However they control task
1840      # attempts in different ways:
1841      #
1842      # * rate_limits controls the total rate of
1843      #   dispatches from a queue (i.e. all traffic dispatched from the
1844      #   queue, regardless of whether the dispatch is from a first
1845      #   attempt or a retry).
1846      # * retry_config controls what happens to
1847      #   particular a task after its first attempt fails. That is,
1848      #   retry_config controls task retries (the
1849      #   second attempt, third attempt, etc).
1850      #
1851      # The queue's actual dispatch rate is the result of:
1852      #
1853      # * Number of tasks in the queue
1854      # * User-specified throttling: rate_limits,
1855      #   retry_config, and the
1856      #   queue's state.
1857      # * System throttling due to `429` (Too Many Requests) or `503` (Service
1858      #   Unavailable) responses from the worker, high error rates, or to smooth
1859      #   sudden large traffic spikes.
1860      #
1861      # This message determines the maximum rate that tasks can be dispatched by a
1862      # queue, regardless of whether the dispatch is a first task attempt or a retry.
1863      #
1864      # Note: The debugging command, RunTask, will run a task
1865      # even if the queue has reached its RateLimits.
1866    "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
1867        # to be dispatched for this queue. After this threshold has been
1868        # reached, Cloud Tasks stops dispatching tasks until the number of
1869        # concurrent requests decreases.
1870        #
1871        # If unspecified when the queue is created, Cloud Tasks will pick the
1872        # default.
1873        #
1874        #
1875        # The maximum allowed value is 5,000.
1876        #
1877        #
1878        # This field has the same meaning as
1879        # [max_concurrent_requests in
1880        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
1881    "maxBurstSize": 42, # Output only. The max burst size.
1882        #
1883        # Max burst size limits how fast tasks in queue are processed when
1884        # many tasks are in the queue and the rate is high. This field
1885        # allows the queue to have a high rate so processing starts shortly
1886        # after a task is enqueued, but still limits resource usage when
1887        # many tasks are enqueued in a short period of time.
1888        #
1889        # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
1890        # algorithm is used to control the rate of task dispatches. Each
1891        # queue has a token bucket that holds tokens, up to the maximum
1892        # specified by `max_burst_size`. Each time a task is dispatched, a
1893        # token is removed from the bucket. Tasks will be dispatched until
1894        # the queue's bucket runs out of tokens. The bucket will be
1895        # continuously refilled with new tokens based on
1896        # max_dispatches_per_second.
1897        #
1898        # Cloud Tasks will pick the value of `max_burst_size` based on the
1899        # value of
1900        # max_dispatches_per_second.
1901        #
1902        # For App Engine queues that were created or updated using
1903        # `queue.yaml/xml`, `max_burst_size` is equal to
1904        # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
1905        # Since `max_burst_size` is output only, if
1906        # UpdateQueue is called on a queue
1907        # created by `queue.yaml/xml`, `max_burst_size` will be reset based
1908        # on the value of
1909        # max_dispatches_per_second,
1910        # regardless of whether
1911        # max_dispatches_per_second
1912        # is updated.
1913    "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
1914        #
1915        # If unspecified when the queue is created, Cloud Tasks will pick the
1916        # default.
1917        #
1918        # * For App Engine queues, the maximum allowed value
1919        #   is 500.
1920        #
1921        #
1922        # This field has the same meaning as
1923        # [rate in
1924        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
1925  },
1926  "state": "A String", # Output only. The state of the queue.
1927      #
1928      # `state` can only be changed by called
1929      # PauseQueue,
1930      # ResumeQueue, or uploading
1931      # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
1932      # UpdateQueue cannot be used to change `state`.
1933  "purgeTime": "A String", # Output only. The last time this queue was purged.
1934      #
1935      # All tasks that were created before this time
1936      # were purged.
1937      #
1938      # A queue can be purged using PurgeQueue, the
1939      # [App Engine Task Queue SDK, or the Cloud
1940      # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
1941      #
1942      # Purge time will be truncated to the nearest microsecond. Purge
1943      # time will be unset if the queue has never been purged.
1944  "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
1945      # App Engine tasks in this queue.
1946      # Http tasks are not affected by this proto.
1947      #
1948      # The task will be delivered to the App Engine application hostname
1949      # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
1950      # The documentation for AppEngineHttpRequest explains how the
1951      # task's host URL is constructed.
1952      #
1953      # Using AppEngineHttpQueue requires
1954      # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
1955      # Google IAM permission for the project
1956      # and the following scope:
1957      #
1958      # `https://www.googleapis.com/auth/cloud-platform`
1959    "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
1960        # task-level app_engine_routing.
1961        #
1962        # If set, `app_engine_routing_override` is used for all tasks in
1963        # the queue, no matter what the setting is for the
1964        # task-level app_engine_routing.
1965        #
1966        # Defines routing characteristics specific to App Engine - service, version,
1967        # and instance.
1968        #
1969        # For more information about services, versions, and instances see
1970        # [An Overview of App
1971        # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
1972        # [Microservices Architecture on Google App
1973        # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
1974        # [App Engine Standard request
1975        # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
1976        # and [App Engine Flex request
1977        # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
1978      "instance": "A String", # App instance.
1979          #
1980          # By default, the task is sent to an instance which is available when
1981          # the task is attempted.
1982          #
1983          # Requests can only be sent to a specific instance if
1984          # [manual scaling is used in App Engine
1985          # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
1986          # App Engine Flex does not support instances. For more information, see
1987          # [App Engine Standard request
1988          # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
1989          # and [App Engine Flex request
1990          # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
1991      "host": "A String", # Output only. The host that the task is sent to.
1992          #
1993          # The host is constructed from the domain name of the app associated with
1994          # the queue's project ID (for example <app-id>.appspot.com), and the
1995          # service, version,
1996          # and instance. Tasks which were created using
1997          # the App Engine SDK might have a custom domain name.
1998          #
1999          # For more information, see
2000          # [How Requests are
2001          # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
2002      "version": "A String", # App version.
2003          #
2004          # By default, the task is sent to the version which is the default
2005          # version when the task is attempted.
2006          #
2007          # For some queues or tasks which were created using the App Engine
2008          # Task Queue API, host is not parsable
2009          # into service,
2010          # version, and
2011          # instance. For example, some tasks
2012          # which were created using the App Engine SDK use a custom domain
2013          # name; custom domains are not parsed by Cloud Tasks. If
2014          # host is not parsable, then
2015          # service,
2016          # version, and
2017          # instance are the empty string.
2018      "service": "A String", # App service.
2019          #
2020          # By default, the task is sent to the service which is the default
2021          # service when the task is attempted.
2022          #
2023          # For some queues or tasks which were created using the App Engine
2024          # Task Queue API, host is not parsable
2025          # into service,
2026          # version, and
2027          # instance. For example, some tasks
2028          # which were created using the App Engine SDK use a custom domain
2029          # name; custom domains are not parsed by Cloud Tasks. If
2030          # host is not parsable, then
2031          # service,
2032          # version, and
2033          # instance are the empty string.
2034    },
2035  },
2036  "retryConfig": { # Retry config. # Settings that determine the retry behavior.
2037      #
2038      # * For tasks created using Cloud Tasks: the queue-level retry settings
2039      #   apply to all tasks in the queue that were created using Cloud Tasks.
2040      #   Retry settings cannot be set on individual tasks.
2041      # * For tasks created using the App Engine SDK: the queue-level retry
2042      #   settings apply to all tasks in the queue which do not have retry settings
2043      #   explicitly set on the task and were created by the App Engine SDK. See
2044      #   [App Engine
2045      #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
2046      #
2047      # These settings determine when a failed task attempt is retried.
2048    "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
2049        # retrying a failed task, measured from when the task was first
2050        # attempted. Once `max_retry_duration` time has passed *and* the
2051        # task has been attempted max_attempts
2052        # times, no further attempts will be made and the task will be
2053        # deleted.
2054        #
2055        # If zero, then the task age is unlimited.
2056        #
2057        # If unspecified when the queue is created, Cloud Tasks will pick the
2058        # default.
2059        #
2060        #
2061        # `max_retry_duration` will be truncated to the nearest second.
2062        #
2063        # This field has the same meaning as
2064        # [task_age_limit in
2065        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2066    "maxDoublings": 42, # The time between retries will double `max_doublings` times.
2067        #
2068        # A task's retry interval starts at
2069        # min_backoff, then doubles
2070        # `max_doublings` times, then increases linearly, and finally
2071        # retries retries at intervals of
2072        # max_backoff up to
2073        # max_attempts times.
2074        #
2075        # For example, if min_backoff is 10s,
2076        # max_backoff is 300s, and
2077        # `max_doublings` is 3, then the a task will first be retried in
2078        # 10s. The retry interval will double three times, and then
2079        # increase linearly by 2^3 * 10s.  Finally, the task will retry at
2080        # intervals of max_backoff until the
2081        # task has been attempted max_attempts
2082        # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
2083        # 240s, 300s, 300s, ....
2084        #
2085        # If unspecified when the queue is created, Cloud Tasks will pick the
2086        # default.
2087        #
2088        #
2089        # This field has the same meaning as
2090        # [max_doublings in
2091        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2092    "maxAttempts": 42, # Number of attempts per task.
2093        #
2094        # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
2095        # first attempt fails, then there will be `max_attempts - 1` retries). Must
2096        # be >= -1.
2097        #
2098        # If unspecified when the queue is created, Cloud Tasks will pick the
2099        # default.
2100        #
2101        # -1 indicates unlimited attempts.
2102        #
2103        # This field has the same meaning as
2104        # [task_retry_limit in
2105        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2106    "maxBackoff": "A String", # A task will be scheduled for retry between
2107        # min_backoff and
2108        # max_backoff duration after it fails,
2109        # if the queue's RetryConfig specifies that the task should be
2110        # retried.
2111        #
2112        # If unspecified when the queue is created, Cloud Tasks will pick the
2113        # default.
2114        #
2115        #
2116        # `max_backoff` will be truncated to the nearest second.
2117        #
2118        # This field has the same meaning as
2119        # [max_backoff_seconds in
2120        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2121    "minBackoff": "A String", # A task will be scheduled for retry between
2122        # min_backoff and
2123        # max_backoff duration after it fails,
2124        # if the queue's RetryConfig specifies that the task should be
2125        # retried.
2126        #
2127        # If unspecified when the queue is created, Cloud Tasks will pick the
2128        # default.
2129        #
2130        #
2131        # `min_backoff` will be truncated to the nearest second.
2132        #
2133        # This field has the same meaning as
2134        # [min_backoff_seconds in
2135        # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2136  },
2137}
2138
2139  updateMask: string, A mask used to specify which fields of the queue are being updated.
2140
2141If empty, then all fields will be updated.
2142  x__xgafv: string, V1 error format.
2143    Allowed values
2144      1 - v1 error format
2145      2 - v2 error format
2146
2147Returns:
2148  An object of the form:
2149
2150    { # A queue is a container of related tasks. Queues are configured to manage
2151      # how those tasks are dispatched. Configurable properties include rate limits,
2152      # retry options, queue types, and others.
2153    "name": "A String", # Caller-specified and required in CreateQueue,
2154        # after which it becomes output only.
2155        #
2156        # The queue name.
2157        #
2158        # The queue name must have the following format:
2159        # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
2160        #
2161        # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
2162        #    hyphens (-), colons (:), or periods (.).
2163        #    For more information, see
2164        #    [Identifying
2165        #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
2166        # * `LOCATION_ID` is the canonical ID for the queue's location.
2167        #    The list of available locations can be obtained by calling
2168        #    ListLocations.
2169        #    For more information, see https://cloud.google.com/about/locations/.
2170        # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
2171        #   hyphens (-). The maximum length is 100 characters.
2172    "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
2173        # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
2174        # field is unset, then no logs are written.
2175        # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
2176      "samplingRatio": 3.14, # Specifies the fraction of operations to write to
2177          # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
2178          # This field may contain any value between 0.0 and 1.0, inclusive.
2179          # 0.0 is the default and means that no operations are logged.
2180    },
2181    "rateLimits": { # Rate limits. # Rate limits for task dispatches.
2182        #
2183        # rate_limits and retry_config are
2184        # related because they both control task attempts. However they control task
2185        # attempts in different ways:
2186        #
2187        # * rate_limits controls the total rate of
2188        #   dispatches from a queue (i.e. all traffic dispatched from the
2189        #   queue, regardless of whether the dispatch is from a first
2190        #   attempt or a retry).
2191        # * retry_config controls what happens to
2192        #   particular a task after its first attempt fails. That is,
2193        #   retry_config controls task retries (the
2194        #   second attempt, third attempt, etc).
2195        #
2196        # The queue's actual dispatch rate is the result of:
2197        #
2198        # * Number of tasks in the queue
2199        # * User-specified throttling: rate_limits,
2200        #   retry_config, and the
2201        #   queue's state.
2202        # * System throttling due to `429` (Too Many Requests) or `503` (Service
2203        #   Unavailable) responses from the worker, high error rates, or to smooth
2204        #   sudden large traffic spikes.
2205        #
2206        # This message determines the maximum rate that tasks can be dispatched by a
2207        # queue, regardless of whether the dispatch is a first task attempt or a retry.
2208        #
2209        # Note: The debugging command, RunTask, will run a task
2210        # even if the queue has reached its RateLimits.
2211      "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
2212          # to be dispatched for this queue. After this threshold has been
2213          # reached, Cloud Tasks stops dispatching tasks until the number of
2214          # concurrent requests decreases.
2215          #
2216          # If unspecified when the queue is created, Cloud Tasks will pick the
2217          # default.
2218          #
2219          #
2220          # The maximum allowed value is 5,000.
2221          #
2222          #
2223          # This field has the same meaning as
2224          # [max_concurrent_requests in
2225          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
2226      "maxBurstSize": 42, # Output only. The max burst size.
2227          #
2228          # Max burst size limits how fast tasks in queue are processed when
2229          # many tasks are in the queue and the rate is high. This field
2230          # allows the queue to have a high rate so processing starts shortly
2231          # after a task is enqueued, but still limits resource usage when
2232          # many tasks are enqueued in a short period of time.
2233          #
2234          # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
2235          # algorithm is used to control the rate of task dispatches. Each
2236          # queue has a token bucket that holds tokens, up to the maximum
2237          # specified by `max_burst_size`. Each time a task is dispatched, a
2238          # token is removed from the bucket. Tasks will be dispatched until
2239          # the queue's bucket runs out of tokens. The bucket will be
2240          # continuously refilled with new tokens based on
2241          # max_dispatches_per_second.
2242          #
2243          # Cloud Tasks will pick the value of `max_burst_size` based on the
2244          # value of
2245          # max_dispatches_per_second.
2246          #
2247          # For App Engine queues that were created or updated using
2248          # `queue.yaml/xml`, `max_burst_size` is equal to
2249          # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
2250          # Since `max_burst_size` is output only, if
2251          # UpdateQueue is called on a queue
2252          # created by `queue.yaml/xml`, `max_burst_size` will be reset based
2253          # on the value of
2254          # max_dispatches_per_second,
2255          # regardless of whether
2256          # max_dispatches_per_second
2257          # is updated.
2258      "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
2259          #
2260          # If unspecified when the queue is created, Cloud Tasks will pick the
2261          # default.
2262          #
2263          # * For App Engine queues, the maximum allowed value
2264          #   is 500.
2265          #
2266          #
2267          # This field has the same meaning as
2268          # [rate in
2269          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
2270    },
2271    "state": "A String", # Output only. The state of the queue.
2272        #
2273        # `state` can only be changed by called
2274        # PauseQueue,
2275        # ResumeQueue, or uploading
2276        # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
2277        # UpdateQueue cannot be used to change `state`.
2278    "purgeTime": "A String", # Output only. The last time this queue was purged.
2279        #
2280        # All tasks that were created before this time
2281        # were purged.
2282        #
2283        # A queue can be purged using PurgeQueue, the
2284        # [App Engine Task Queue SDK, or the Cloud
2285        # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
2286        #
2287        # Purge time will be truncated to the nearest microsecond. Purge
2288        # time will be unset if the queue has never been purged.
2289    "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
2290        # App Engine tasks in this queue.
2291        # Http tasks are not affected by this proto.
2292        #
2293        # The task will be delivered to the App Engine application hostname
2294        # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
2295        # The documentation for AppEngineHttpRequest explains how the
2296        # task's host URL is constructed.
2297        #
2298        # Using AppEngineHttpQueue requires
2299        # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
2300        # Google IAM permission for the project
2301        # and the following scope:
2302        #
2303        # `https://www.googleapis.com/auth/cloud-platform`
2304      "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
2305          # task-level app_engine_routing.
2306          #
2307          # If set, `app_engine_routing_override` is used for all tasks in
2308          # the queue, no matter what the setting is for the
2309          # task-level app_engine_routing.
2310          #
2311          # Defines routing characteristics specific to App Engine - service, version,
2312          # and instance.
2313          #
2314          # For more information about services, versions, and instances see
2315          # [An Overview of App
2316          # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
2317          # [Microservices Architecture on Google App
2318          # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
2319          # [App Engine Standard request
2320          # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
2321          # and [App Engine Flex request
2322          # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
2323        "instance": "A String", # App instance.
2324            #
2325            # By default, the task is sent to an instance which is available when
2326            # the task is attempted.
2327            #
2328            # Requests can only be sent to a specific instance if
2329            # [manual scaling is used in App Engine
2330            # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
2331            # App Engine Flex does not support instances. For more information, see
2332            # [App Engine Standard request
2333            # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
2334            # and [App Engine Flex request
2335            # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
2336        "host": "A String", # Output only. The host that the task is sent to.
2337            #
2338            # The host is constructed from the domain name of the app associated with
2339            # the queue's project ID (for example <app-id>.appspot.com), and the
2340            # service, version,
2341            # and instance. Tasks which were created using
2342            # the App Engine SDK might have a custom domain name.
2343            #
2344            # For more information, see
2345            # [How Requests are
2346            # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
2347        "version": "A String", # App version.
2348            #
2349            # By default, the task is sent to the version which is the default
2350            # version when the task is attempted.
2351            #
2352            # For some queues or tasks which were created using the App Engine
2353            # Task Queue API, host is not parsable
2354            # into service,
2355            # version, and
2356            # instance. For example, some tasks
2357            # which were created using the App Engine SDK use a custom domain
2358            # name; custom domains are not parsed by Cloud Tasks. If
2359            # host is not parsable, then
2360            # service,
2361            # version, and
2362            # instance are the empty string.
2363        "service": "A String", # App service.
2364            #
2365            # By default, the task is sent to the service which is the default
2366            # service when the task is attempted.
2367            #
2368            # For some queues or tasks which were created using the App Engine
2369            # Task Queue API, host is not parsable
2370            # into service,
2371            # version, and
2372            # instance. For example, some tasks
2373            # which were created using the App Engine SDK use a custom domain
2374            # name; custom domains are not parsed by Cloud Tasks. If
2375            # host is not parsable, then
2376            # service,
2377            # version, and
2378            # instance are the empty string.
2379      },
2380    },
2381    "retryConfig": { # Retry config. # Settings that determine the retry behavior.
2382        #
2383        # * For tasks created using Cloud Tasks: the queue-level retry settings
2384        #   apply to all tasks in the queue that were created using Cloud Tasks.
2385        #   Retry settings cannot be set on individual tasks.
2386        # * For tasks created using the App Engine SDK: the queue-level retry
2387        #   settings apply to all tasks in the queue which do not have retry settings
2388        #   explicitly set on the task and were created by the App Engine SDK. See
2389        #   [App Engine
2390        #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
2391        #
2392        # These settings determine when a failed task attempt is retried.
2393      "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
2394          # retrying a failed task, measured from when the task was first
2395          # attempted. Once `max_retry_duration` time has passed *and* the
2396          # task has been attempted max_attempts
2397          # times, no further attempts will be made and the task will be
2398          # deleted.
2399          #
2400          # If zero, then the task age is unlimited.
2401          #
2402          # If unspecified when the queue is created, Cloud Tasks will pick the
2403          # default.
2404          #
2405          #
2406          # `max_retry_duration` will be truncated to the nearest second.
2407          #
2408          # This field has the same meaning as
2409          # [task_age_limit in
2410          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2411      "maxDoublings": 42, # The time between retries will double `max_doublings` times.
2412          #
2413          # A task's retry interval starts at
2414          # min_backoff, then doubles
2415          # `max_doublings` times, then increases linearly, and finally
2416          # retries retries at intervals of
2417          # max_backoff up to
2418          # max_attempts times.
2419          #
2420          # For example, if min_backoff is 10s,
2421          # max_backoff is 300s, and
2422          # `max_doublings` is 3, then the a task will first be retried in
2423          # 10s. The retry interval will double three times, and then
2424          # increase linearly by 2^3 * 10s.  Finally, the task will retry at
2425          # intervals of max_backoff until the
2426          # task has been attempted max_attempts
2427          # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
2428          # 240s, 300s, 300s, ....
2429          #
2430          # If unspecified when the queue is created, Cloud Tasks will pick the
2431          # default.
2432          #
2433          #
2434          # This field has the same meaning as
2435          # [max_doublings in
2436          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2437      "maxAttempts": 42, # Number of attempts per task.
2438          #
2439          # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
2440          # first attempt fails, then there will be `max_attempts - 1` retries). Must
2441          # be >= -1.
2442          #
2443          # If unspecified when the queue is created, Cloud Tasks will pick the
2444          # default.
2445          #
2446          # -1 indicates unlimited attempts.
2447          #
2448          # This field has the same meaning as
2449          # [task_retry_limit in
2450          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2451      "maxBackoff": "A String", # A task will be scheduled for retry between
2452          # min_backoff and
2453          # max_backoff duration after it fails,
2454          # if the queue's RetryConfig specifies that the task should be
2455          # retried.
2456          #
2457          # If unspecified when the queue is created, Cloud Tasks will pick the
2458          # default.
2459          #
2460          #
2461          # `max_backoff` will be truncated to the nearest second.
2462          #
2463          # This field has the same meaning as
2464          # [max_backoff_seconds in
2465          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2466      "minBackoff": "A String", # A task will be scheduled for retry between
2467          # min_backoff and
2468          # max_backoff duration after it fails,
2469          # if the queue's RetryConfig specifies that the task should be
2470          # retried.
2471          #
2472          # If unspecified when the queue is created, Cloud Tasks will pick the
2473          # default.
2474          #
2475          #
2476          # `min_backoff` will be truncated to the nearest second.
2477          #
2478          # This field has the same meaning as
2479          # [min_backoff_seconds in
2480          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2481    },
2482  }</pre>
2483</div>
2484
2485<div class="method">
2486    <code class="details" id="pause">pause(name, body=None, x__xgafv=None)</code>
2487  <pre>Pauses the queue.
2488
2489If a queue is paused then the system will stop dispatching tasks
2490until the queue is resumed via
2491ResumeQueue. Tasks can still be added
2492when the queue is paused. A queue is paused if its
2493state is PAUSED.
2494
2495Args:
2496  name: string, Required.
2497
2498The queue name. For example:
2499`projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` (required)
2500  body: object, The request body.
2501    The object takes the form of:
2502
2503{ # Request message for PauseQueue.
2504  }
2505
2506  x__xgafv: string, V1 error format.
2507    Allowed values
2508      1 - v1 error format
2509      2 - v2 error format
2510
2511Returns:
2512  An object of the form:
2513
2514    { # A queue is a container of related tasks. Queues are configured to manage
2515      # how those tasks are dispatched. Configurable properties include rate limits,
2516      # retry options, queue types, and others.
2517    "name": "A String", # Caller-specified and required in CreateQueue,
2518        # after which it becomes output only.
2519        #
2520        # The queue name.
2521        #
2522        # The queue name must have the following format:
2523        # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
2524        #
2525        # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
2526        #    hyphens (-), colons (:), or periods (.).
2527        #    For more information, see
2528        #    [Identifying
2529        #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
2530        # * `LOCATION_ID` is the canonical ID for the queue's location.
2531        #    The list of available locations can be obtained by calling
2532        #    ListLocations.
2533        #    For more information, see https://cloud.google.com/about/locations/.
2534        # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
2535        #   hyphens (-). The maximum length is 100 characters.
2536    "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
2537        # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
2538        # field is unset, then no logs are written.
2539        # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
2540      "samplingRatio": 3.14, # Specifies the fraction of operations to write to
2541          # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
2542          # This field may contain any value between 0.0 and 1.0, inclusive.
2543          # 0.0 is the default and means that no operations are logged.
2544    },
2545    "rateLimits": { # Rate limits. # Rate limits for task dispatches.
2546        #
2547        # rate_limits and retry_config are
2548        # related because they both control task attempts. However they control task
2549        # attempts in different ways:
2550        #
2551        # * rate_limits controls the total rate of
2552        #   dispatches from a queue (i.e. all traffic dispatched from the
2553        #   queue, regardless of whether the dispatch is from a first
2554        #   attempt or a retry).
2555        # * retry_config controls what happens to
2556        #   particular a task after its first attempt fails. That is,
2557        #   retry_config controls task retries (the
2558        #   second attempt, third attempt, etc).
2559        #
2560        # The queue's actual dispatch rate is the result of:
2561        #
2562        # * Number of tasks in the queue
2563        # * User-specified throttling: rate_limits,
2564        #   retry_config, and the
2565        #   queue's state.
2566        # * System throttling due to `429` (Too Many Requests) or `503` (Service
2567        #   Unavailable) responses from the worker, high error rates, or to smooth
2568        #   sudden large traffic spikes.
2569        #
2570        # This message determines the maximum rate that tasks can be dispatched by a
2571        # queue, regardless of whether the dispatch is a first task attempt or a retry.
2572        #
2573        # Note: The debugging command, RunTask, will run a task
2574        # even if the queue has reached its RateLimits.
2575      "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
2576          # to be dispatched for this queue. After this threshold has been
2577          # reached, Cloud Tasks stops dispatching tasks until the number of
2578          # concurrent requests decreases.
2579          #
2580          # If unspecified when the queue is created, Cloud Tasks will pick the
2581          # default.
2582          #
2583          #
2584          # The maximum allowed value is 5,000.
2585          #
2586          #
2587          # This field has the same meaning as
2588          # [max_concurrent_requests in
2589          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
2590      "maxBurstSize": 42, # Output only. The max burst size.
2591          #
2592          # Max burst size limits how fast tasks in queue are processed when
2593          # many tasks are in the queue and the rate is high. This field
2594          # allows the queue to have a high rate so processing starts shortly
2595          # after a task is enqueued, but still limits resource usage when
2596          # many tasks are enqueued in a short period of time.
2597          #
2598          # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
2599          # algorithm is used to control the rate of task dispatches. Each
2600          # queue has a token bucket that holds tokens, up to the maximum
2601          # specified by `max_burst_size`. Each time a task is dispatched, a
2602          # token is removed from the bucket. Tasks will be dispatched until
2603          # the queue's bucket runs out of tokens. The bucket will be
2604          # continuously refilled with new tokens based on
2605          # max_dispatches_per_second.
2606          #
2607          # Cloud Tasks will pick the value of `max_burst_size` based on the
2608          # value of
2609          # max_dispatches_per_second.
2610          #
2611          # For App Engine queues that were created or updated using
2612          # `queue.yaml/xml`, `max_burst_size` is equal to
2613          # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
2614          # Since `max_burst_size` is output only, if
2615          # UpdateQueue is called on a queue
2616          # created by `queue.yaml/xml`, `max_burst_size` will be reset based
2617          # on the value of
2618          # max_dispatches_per_second,
2619          # regardless of whether
2620          # max_dispatches_per_second
2621          # is updated.
2622      "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
2623          #
2624          # If unspecified when the queue is created, Cloud Tasks will pick the
2625          # default.
2626          #
2627          # * For App Engine queues, the maximum allowed value
2628          #   is 500.
2629          #
2630          #
2631          # This field has the same meaning as
2632          # [rate in
2633          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
2634    },
2635    "state": "A String", # Output only. The state of the queue.
2636        #
2637        # `state` can only be changed by called
2638        # PauseQueue,
2639        # ResumeQueue, or uploading
2640        # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
2641        # UpdateQueue cannot be used to change `state`.
2642    "purgeTime": "A String", # Output only. The last time this queue was purged.
2643        #
2644        # All tasks that were created before this time
2645        # were purged.
2646        #
2647        # A queue can be purged using PurgeQueue, the
2648        # [App Engine Task Queue SDK, or the Cloud
2649        # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
2650        #
2651        # Purge time will be truncated to the nearest microsecond. Purge
2652        # time will be unset if the queue has never been purged.
2653    "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
2654        # App Engine tasks in this queue.
2655        # Http tasks are not affected by this proto.
2656        #
2657        # The task will be delivered to the App Engine application hostname
2658        # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
2659        # The documentation for AppEngineHttpRequest explains how the
2660        # task's host URL is constructed.
2661        #
2662        # Using AppEngineHttpQueue requires
2663        # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
2664        # Google IAM permission for the project
2665        # and the following scope:
2666        #
2667        # `https://www.googleapis.com/auth/cloud-platform`
2668      "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
2669          # task-level app_engine_routing.
2670          #
2671          # If set, `app_engine_routing_override` is used for all tasks in
2672          # the queue, no matter what the setting is for the
2673          # task-level app_engine_routing.
2674          #
2675          # Defines routing characteristics specific to App Engine - service, version,
2676          # and instance.
2677          #
2678          # For more information about services, versions, and instances see
2679          # [An Overview of App
2680          # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
2681          # [Microservices Architecture on Google App
2682          # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
2683          # [App Engine Standard request
2684          # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
2685          # and [App Engine Flex request
2686          # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
2687        "instance": "A String", # App instance.
2688            #
2689            # By default, the task is sent to an instance which is available when
2690            # the task is attempted.
2691            #
2692            # Requests can only be sent to a specific instance if
2693            # [manual scaling is used in App Engine
2694            # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
2695            # App Engine Flex does not support instances. For more information, see
2696            # [App Engine Standard request
2697            # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
2698            # and [App Engine Flex request
2699            # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
2700        "host": "A String", # Output only. The host that the task is sent to.
2701            #
2702            # The host is constructed from the domain name of the app associated with
2703            # the queue's project ID (for example <app-id>.appspot.com), and the
2704            # service, version,
2705            # and instance. Tasks which were created using
2706            # the App Engine SDK might have a custom domain name.
2707            #
2708            # For more information, see
2709            # [How Requests are
2710            # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
2711        "version": "A String", # App version.
2712            #
2713            # By default, the task is sent to the version which is the default
2714            # version when the task is attempted.
2715            #
2716            # For some queues or tasks which were created using the App Engine
2717            # Task Queue API, host is not parsable
2718            # into service,
2719            # version, and
2720            # instance. For example, some tasks
2721            # which were created using the App Engine SDK use a custom domain
2722            # name; custom domains are not parsed by Cloud Tasks. If
2723            # host is not parsable, then
2724            # service,
2725            # version, and
2726            # instance are the empty string.
2727        "service": "A String", # App service.
2728            #
2729            # By default, the task is sent to the service which is the default
2730            # service when the task is attempted.
2731            #
2732            # For some queues or tasks which were created using the App Engine
2733            # Task Queue API, host is not parsable
2734            # into service,
2735            # version, and
2736            # instance. For example, some tasks
2737            # which were created using the App Engine SDK use a custom domain
2738            # name; custom domains are not parsed by Cloud Tasks. If
2739            # host is not parsable, then
2740            # service,
2741            # version, and
2742            # instance are the empty string.
2743      },
2744    },
2745    "retryConfig": { # Retry config. # Settings that determine the retry behavior.
2746        #
2747        # * For tasks created using Cloud Tasks: the queue-level retry settings
2748        #   apply to all tasks in the queue that were created using Cloud Tasks.
2749        #   Retry settings cannot be set on individual tasks.
2750        # * For tasks created using the App Engine SDK: the queue-level retry
2751        #   settings apply to all tasks in the queue which do not have retry settings
2752        #   explicitly set on the task and were created by the App Engine SDK. See
2753        #   [App Engine
2754        #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
2755        #
2756        # These settings determine when a failed task attempt is retried.
2757      "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
2758          # retrying a failed task, measured from when the task was first
2759          # attempted. Once `max_retry_duration` time has passed *and* the
2760          # task has been attempted max_attempts
2761          # times, no further attempts will be made and the task will be
2762          # deleted.
2763          #
2764          # If zero, then the task age is unlimited.
2765          #
2766          # If unspecified when the queue is created, Cloud Tasks will pick the
2767          # default.
2768          #
2769          #
2770          # `max_retry_duration` will be truncated to the nearest second.
2771          #
2772          # This field has the same meaning as
2773          # [task_age_limit in
2774          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2775      "maxDoublings": 42, # The time between retries will double `max_doublings` times.
2776          #
2777          # A task's retry interval starts at
2778          # min_backoff, then doubles
2779          # `max_doublings` times, then increases linearly, and finally
2780          # retries retries at intervals of
2781          # max_backoff up to
2782          # max_attempts times.
2783          #
2784          # For example, if min_backoff is 10s,
2785          # max_backoff is 300s, and
2786          # `max_doublings` is 3, then the a task will first be retried in
2787          # 10s. The retry interval will double three times, and then
2788          # increase linearly by 2^3 * 10s.  Finally, the task will retry at
2789          # intervals of max_backoff until the
2790          # task has been attempted max_attempts
2791          # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
2792          # 240s, 300s, 300s, ....
2793          #
2794          # If unspecified when the queue is created, Cloud Tasks will pick the
2795          # default.
2796          #
2797          #
2798          # This field has the same meaning as
2799          # [max_doublings in
2800          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2801      "maxAttempts": 42, # Number of attempts per task.
2802          #
2803          # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
2804          # first attempt fails, then there will be `max_attempts - 1` retries). Must
2805          # be >= -1.
2806          #
2807          # If unspecified when the queue is created, Cloud Tasks will pick the
2808          # default.
2809          #
2810          # -1 indicates unlimited attempts.
2811          #
2812          # This field has the same meaning as
2813          # [task_retry_limit in
2814          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2815      "maxBackoff": "A String", # A task will be scheduled for retry between
2816          # min_backoff and
2817          # max_backoff duration after it fails,
2818          # if the queue's RetryConfig specifies that the task should be
2819          # retried.
2820          #
2821          # If unspecified when the queue is created, Cloud Tasks will pick the
2822          # default.
2823          #
2824          #
2825          # `max_backoff` will be truncated to the nearest second.
2826          #
2827          # This field has the same meaning as
2828          # [max_backoff_seconds in
2829          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2830      "minBackoff": "A String", # A task will be scheduled for retry between
2831          # min_backoff and
2832          # max_backoff duration after it fails,
2833          # if the queue's RetryConfig specifies that the task should be
2834          # retried.
2835          #
2836          # If unspecified when the queue is created, Cloud Tasks will pick the
2837          # default.
2838          #
2839          #
2840          # `min_backoff` will be truncated to the nearest second.
2841          #
2842          # This field has the same meaning as
2843          # [min_backoff_seconds in
2844          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
2845    },
2846  }</pre>
2847</div>
2848
2849<div class="method">
2850    <code class="details" id="purge">purge(name, body=None, x__xgafv=None)</code>
2851  <pre>Purges a queue by deleting all of its tasks.
2852
2853All tasks created before this method is called are permanently deleted.
2854
2855Purge operations can take up to one minute to take effect. Tasks
2856might be dispatched before the purge takes effect. A purge is irreversible.
2857
2858Args:
2859  name: string, Required.
2860
2861The queue name. For example:
2862`projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` (required)
2863  body: object, The request body.
2864    The object takes the form of:
2865
2866{ # Request message for PurgeQueue.
2867  }
2868
2869  x__xgafv: string, V1 error format.
2870    Allowed values
2871      1 - v1 error format
2872      2 - v2 error format
2873
2874Returns:
2875  An object of the form:
2876
2877    { # A queue is a container of related tasks. Queues are configured to manage
2878      # how those tasks are dispatched. Configurable properties include rate limits,
2879      # retry options, queue types, and others.
2880    "name": "A String", # Caller-specified and required in CreateQueue,
2881        # after which it becomes output only.
2882        #
2883        # The queue name.
2884        #
2885        # The queue name must have the following format:
2886        # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
2887        #
2888        # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
2889        #    hyphens (-), colons (:), or periods (.).
2890        #    For more information, see
2891        #    [Identifying
2892        #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
2893        # * `LOCATION_ID` is the canonical ID for the queue's location.
2894        #    The list of available locations can be obtained by calling
2895        #    ListLocations.
2896        #    For more information, see https://cloud.google.com/about/locations/.
2897        # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
2898        #   hyphens (-). The maximum length is 100 characters.
2899    "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
2900        # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
2901        # field is unset, then no logs are written.
2902        # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
2903      "samplingRatio": 3.14, # Specifies the fraction of operations to write to
2904          # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
2905          # This field may contain any value between 0.0 and 1.0, inclusive.
2906          # 0.0 is the default and means that no operations are logged.
2907    },
2908    "rateLimits": { # Rate limits. # Rate limits for task dispatches.
2909        #
2910        # rate_limits and retry_config are
2911        # related because they both control task attempts. However they control task
2912        # attempts in different ways:
2913        #
2914        # * rate_limits controls the total rate of
2915        #   dispatches from a queue (i.e. all traffic dispatched from the
2916        #   queue, regardless of whether the dispatch is from a first
2917        #   attempt or a retry).
2918        # * retry_config controls what happens to
2919        #   particular a task after its first attempt fails. That is,
2920        #   retry_config controls task retries (the
2921        #   second attempt, third attempt, etc).
2922        #
2923        # The queue's actual dispatch rate is the result of:
2924        #
2925        # * Number of tasks in the queue
2926        # * User-specified throttling: rate_limits,
2927        #   retry_config, and the
2928        #   queue's state.
2929        # * System throttling due to `429` (Too Many Requests) or `503` (Service
2930        #   Unavailable) responses from the worker, high error rates, or to smooth
2931        #   sudden large traffic spikes.
2932        #
2933        # This message determines the maximum rate that tasks can be dispatched by a
2934        # queue, regardless of whether the dispatch is a first task attempt or a retry.
2935        #
2936        # Note: The debugging command, RunTask, will run a task
2937        # even if the queue has reached its RateLimits.
2938      "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
2939          # to be dispatched for this queue. After this threshold has been
2940          # reached, Cloud Tasks stops dispatching tasks until the number of
2941          # concurrent requests decreases.
2942          #
2943          # If unspecified when the queue is created, Cloud Tasks will pick the
2944          # default.
2945          #
2946          #
2947          # The maximum allowed value is 5,000.
2948          #
2949          #
2950          # This field has the same meaning as
2951          # [max_concurrent_requests in
2952          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
2953      "maxBurstSize": 42, # Output only. The max burst size.
2954          #
2955          # Max burst size limits how fast tasks in queue are processed when
2956          # many tasks are in the queue and the rate is high. This field
2957          # allows the queue to have a high rate so processing starts shortly
2958          # after a task is enqueued, but still limits resource usage when
2959          # many tasks are enqueued in a short period of time.
2960          #
2961          # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
2962          # algorithm is used to control the rate of task dispatches. Each
2963          # queue has a token bucket that holds tokens, up to the maximum
2964          # specified by `max_burst_size`. Each time a task is dispatched, a
2965          # token is removed from the bucket. Tasks will be dispatched until
2966          # the queue's bucket runs out of tokens. The bucket will be
2967          # continuously refilled with new tokens based on
2968          # max_dispatches_per_second.
2969          #
2970          # Cloud Tasks will pick the value of `max_burst_size` based on the
2971          # value of
2972          # max_dispatches_per_second.
2973          #
2974          # For App Engine queues that were created or updated using
2975          # `queue.yaml/xml`, `max_burst_size` is equal to
2976          # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
2977          # Since `max_burst_size` is output only, if
2978          # UpdateQueue is called on a queue
2979          # created by `queue.yaml/xml`, `max_burst_size` will be reset based
2980          # on the value of
2981          # max_dispatches_per_second,
2982          # regardless of whether
2983          # max_dispatches_per_second
2984          # is updated.
2985      "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
2986          #
2987          # If unspecified when the queue is created, Cloud Tasks will pick the
2988          # default.
2989          #
2990          # * For App Engine queues, the maximum allowed value
2991          #   is 500.
2992          #
2993          #
2994          # This field has the same meaning as
2995          # [rate in
2996          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
2997    },
2998    "state": "A String", # Output only. The state of the queue.
2999        #
3000        # `state` can only be changed by called
3001        # PauseQueue,
3002        # ResumeQueue, or uploading
3003        # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
3004        # UpdateQueue cannot be used to change `state`.
3005    "purgeTime": "A String", # Output only. The last time this queue was purged.
3006        #
3007        # All tasks that were created before this time
3008        # were purged.
3009        #
3010        # A queue can be purged using PurgeQueue, the
3011        # [App Engine Task Queue SDK, or the Cloud
3012        # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
3013        #
3014        # Purge time will be truncated to the nearest microsecond. Purge
3015        # time will be unset if the queue has never been purged.
3016    "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
3017        # App Engine tasks in this queue.
3018        # Http tasks are not affected by this proto.
3019        #
3020        # The task will be delivered to the App Engine application hostname
3021        # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
3022        # The documentation for AppEngineHttpRequest explains how the
3023        # task's host URL is constructed.
3024        #
3025        # Using AppEngineHttpQueue requires
3026        # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
3027        # Google IAM permission for the project
3028        # and the following scope:
3029        #
3030        # `https://www.googleapis.com/auth/cloud-platform`
3031      "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
3032          # task-level app_engine_routing.
3033          #
3034          # If set, `app_engine_routing_override` is used for all tasks in
3035          # the queue, no matter what the setting is for the
3036          # task-level app_engine_routing.
3037          #
3038          # Defines routing characteristics specific to App Engine - service, version,
3039          # and instance.
3040          #
3041          # For more information about services, versions, and instances see
3042          # [An Overview of App
3043          # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
3044          # [Microservices Architecture on Google App
3045          # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
3046          # [App Engine Standard request
3047          # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
3048          # and [App Engine Flex request
3049          # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
3050        "instance": "A String", # App instance.
3051            #
3052            # By default, the task is sent to an instance which is available when
3053            # the task is attempted.
3054            #
3055            # Requests can only be sent to a specific instance if
3056            # [manual scaling is used in App Engine
3057            # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
3058            # App Engine Flex does not support instances. For more information, see
3059            # [App Engine Standard request
3060            # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
3061            # and [App Engine Flex request
3062            # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
3063        "host": "A String", # Output only. The host that the task is sent to.
3064            #
3065            # The host is constructed from the domain name of the app associated with
3066            # the queue's project ID (for example <app-id>.appspot.com), and the
3067            # service, version,
3068            # and instance. Tasks which were created using
3069            # the App Engine SDK might have a custom domain name.
3070            #
3071            # For more information, see
3072            # [How Requests are
3073            # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
3074        "version": "A String", # App version.
3075            #
3076            # By default, the task is sent to the version which is the default
3077            # version when the task is attempted.
3078            #
3079            # For some queues or tasks which were created using the App Engine
3080            # Task Queue API, host is not parsable
3081            # into service,
3082            # version, and
3083            # instance. For example, some tasks
3084            # which were created using the App Engine SDK use a custom domain
3085            # name; custom domains are not parsed by Cloud Tasks. If
3086            # host is not parsable, then
3087            # service,
3088            # version, and
3089            # instance are the empty string.
3090        "service": "A String", # App service.
3091            #
3092            # By default, the task is sent to the service which is the default
3093            # service when the task is attempted.
3094            #
3095            # For some queues or tasks which were created using the App Engine
3096            # Task Queue API, host is not parsable
3097            # into service,
3098            # version, and
3099            # instance. For example, some tasks
3100            # which were created using the App Engine SDK use a custom domain
3101            # name; custom domains are not parsed by Cloud Tasks. If
3102            # host is not parsable, then
3103            # service,
3104            # version, and
3105            # instance are the empty string.
3106      },
3107    },
3108    "retryConfig": { # Retry config. # Settings that determine the retry behavior.
3109        #
3110        # * For tasks created using Cloud Tasks: the queue-level retry settings
3111        #   apply to all tasks in the queue that were created using Cloud Tasks.
3112        #   Retry settings cannot be set on individual tasks.
3113        # * For tasks created using the App Engine SDK: the queue-level retry
3114        #   settings apply to all tasks in the queue which do not have retry settings
3115        #   explicitly set on the task and were created by the App Engine SDK. See
3116        #   [App Engine
3117        #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
3118        #
3119        # These settings determine when a failed task attempt is retried.
3120      "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
3121          # retrying a failed task, measured from when the task was first
3122          # attempted. Once `max_retry_duration` time has passed *and* the
3123          # task has been attempted max_attempts
3124          # times, no further attempts will be made and the task will be
3125          # deleted.
3126          #
3127          # If zero, then the task age is unlimited.
3128          #
3129          # If unspecified when the queue is created, Cloud Tasks will pick the
3130          # default.
3131          #
3132          #
3133          # `max_retry_duration` will be truncated to the nearest second.
3134          #
3135          # This field has the same meaning as
3136          # [task_age_limit in
3137          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3138      "maxDoublings": 42, # The time between retries will double `max_doublings` times.
3139          #
3140          # A task's retry interval starts at
3141          # min_backoff, then doubles
3142          # `max_doublings` times, then increases linearly, and finally
3143          # retries retries at intervals of
3144          # max_backoff up to
3145          # max_attempts times.
3146          #
3147          # For example, if min_backoff is 10s,
3148          # max_backoff is 300s, and
3149          # `max_doublings` is 3, then the a task will first be retried in
3150          # 10s. The retry interval will double three times, and then
3151          # increase linearly by 2^3 * 10s.  Finally, the task will retry at
3152          # intervals of max_backoff until the
3153          # task has been attempted max_attempts
3154          # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
3155          # 240s, 300s, 300s, ....
3156          #
3157          # If unspecified when the queue is created, Cloud Tasks will pick the
3158          # default.
3159          #
3160          #
3161          # This field has the same meaning as
3162          # [max_doublings in
3163          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3164      "maxAttempts": 42, # Number of attempts per task.
3165          #
3166          # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
3167          # first attempt fails, then there will be `max_attempts - 1` retries). Must
3168          # be >= -1.
3169          #
3170          # If unspecified when the queue is created, Cloud Tasks will pick the
3171          # default.
3172          #
3173          # -1 indicates unlimited attempts.
3174          #
3175          # This field has the same meaning as
3176          # [task_retry_limit in
3177          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3178      "maxBackoff": "A String", # A task will be scheduled for retry between
3179          # min_backoff and
3180          # max_backoff duration after it fails,
3181          # if the queue's RetryConfig specifies that the task should be
3182          # retried.
3183          #
3184          # If unspecified when the queue is created, Cloud Tasks will pick the
3185          # default.
3186          #
3187          #
3188          # `max_backoff` will be truncated to the nearest second.
3189          #
3190          # This field has the same meaning as
3191          # [max_backoff_seconds in
3192          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3193      "minBackoff": "A String", # A task will be scheduled for retry between
3194          # min_backoff and
3195          # max_backoff duration after it fails,
3196          # if the queue's RetryConfig specifies that the task should be
3197          # retried.
3198          #
3199          # If unspecified when the queue is created, Cloud Tasks will pick the
3200          # default.
3201          #
3202          #
3203          # `min_backoff` will be truncated to the nearest second.
3204          #
3205          # This field has the same meaning as
3206          # [min_backoff_seconds in
3207          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3208    },
3209  }</pre>
3210</div>
3211
3212<div class="method">
3213    <code class="details" id="resume">resume(name, body=None, x__xgafv=None)</code>
3214  <pre>Resume a queue.
3215
3216This method resumes a queue after it has been
3217PAUSED or
3218DISABLED. The state of a queue is stored
3219in the queue's state; after calling this method it
3220will be set to RUNNING.
3221
3222WARNING: Resuming many high-QPS queues at the same time can
3223lead to target overloading. If you are resuming high-QPS
3224queues, follow the 500/50/5 pattern described in
3225[Managing Cloud Tasks Scaling
3226Risks](https://cloud.google.com/tasks/docs/manage-cloud-task-scaling).
3227
3228Args:
3229  name: string, Required.
3230
3231The queue name. For example:
3232`projects/PROJECT_ID/location/LOCATION_ID/queues/QUEUE_ID` (required)
3233  body: object, The request body.
3234    The object takes the form of:
3235
3236{ # Request message for ResumeQueue.
3237  }
3238
3239  x__xgafv: string, V1 error format.
3240    Allowed values
3241      1 - v1 error format
3242      2 - v2 error format
3243
3244Returns:
3245  An object of the form:
3246
3247    { # A queue is a container of related tasks. Queues are configured to manage
3248      # how those tasks are dispatched. Configurable properties include rate limits,
3249      # retry options, queue types, and others.
3250    "name": "A String", # Caller-specified and required in CreateQueue,
3251        # after which it becomes output only.
3252        #
3253        # The queue name.
3254        #
3255        # The queue name must have the following format:
3256        # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
3257        #
3258        # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
3259        #    hyphens (-), colons (:), or periods (.).
3260        #    For more information, see
3261        #    [Identifying
3262        #    projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
3263        # * `LOCATION_ID` is the canonical ID for the queue's location.
3264        #    The list of available locations can be obtained by calling
3265        #    ListLocations.
3266        #    For more information, see https://cloud.google.com/about/locations/.
3267        # * `QUEUE_ID` can contain letters ([A-Za-z]), numbers ([0-9]), or
3268        #   hyphens (-). The maximum length is 100 characters.
3269    "stackdriverLoggingConfig": { # Configuration options for writing logs to # Configuration options for writing logs to
3270        # [Stackdriver Logging](https://cloud.google.com/logging/docs/). If this
3271        # field is unset, then no logs are written.
3272        # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
3273      "samplingRatio": 3.14, # Specifies the fraction of operations to write to
3274          # [Stackdriver Logging](https://cloud.google.com/logging/docs/).
3275          # This field may contain any value between 0.0 and 1.0, inclusive.
3276          # 0.0 is the default and means that no operations are logged.
3277    },
3278    "rateLimits": { # Rate limits. # Rate limits for task dispatches.
3279        #
3280        # rate_limits and retry_config are
3281        # related because they both control task attempts. However they control task
3282        # attempts in different ways:
3283        #
3284        # * rate_limits controls the total rate of
3285        #   dispatches from a queue (i.e. all traffic dispatched from the
3286        #   queue, regardless of whether the dispatch is from a first
3287        #   attempt or a retry).
3288        # * retry_config controls what happens to
3289        #   particular a task after its first attempt fails. That is,
3290        #   retry_config controls task retries (the
3291        #   second attempt, third attempt, etc).
3292        #
3293        # The queue's actual dispatch rate is the result of:
3294        #
3295        # * Number of tasks in the queue
3296        # * User-specified throttling: rate_limits,
3297        #   retry_config, and the
3298        #   queue's state.
3299        # * System throttling due to `429` (Too Many Requests) or `503` (Service
3300        #   Unavailable) responses from the worker, high error rates, or to smooth
3301        #   sudden large traffic spikes.
3302        #
3303        # This message determines the maximum rate that tasks can be dispatched by a
3304        # queue, regardless of whether the dispatch is a first task attempt or a retry.
3305        #
3306        # Note: The debugging command, RunTask, will run a task
3307        # even if the queue has reached its RateLimits.
3308      "maxConcurrentDispatches": 42, # The maximum number of concurrent tasks that Cloud Tasks allows
3309          # to be dispatched for this queue. After this threshold has been
3310          # reached, Cloud Tasks stops dispatching tasks until the number of
3311          # concurrent requests decreases.
3312          #
3313          # If unspecified when the queue is created, Cloud Tasks will pick the
3314          # default.
3315          #
3316          #
3317          # The maximum allowed value is 5,000.
3318          #
3319          #
3320          # This field has the same meaning as
3321          # [max_concurrent_requests in
3322          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#max_concurrent_requests).
3323      "maxBurstSize": 42, # Output only. The max burst size.
3324          #
3325          # Max burst size limits how fast tasks in queue are processed when
3326          # many tasks are in the queue and the rate is high. This field
3327          # allows the queue to have a high rate so processing starts shortly
3328          # after a task is enqueued, but still limits resource usage when
3329          # many tasks are enqueued in a short period of time.
3330          #
3331          # The [token bucket](https://wikipedia.org/wiki/Token_Bucket)
3332          # algorithm is used to control the rate of task dispatches. Each
3333          # queue has a token bucket that holds tokens, up to the maximum
3334          # specified by `max_burst_size`. Each time a task is dispatched, a
3335          # token is removed from the bucket. Tasks will be dispatched until
3336          # the queue's bucket runs out of tokens. The bucket will be
3337          # continuously refilled with new tokens based on
3338          # max_dispatches_per_second.
3339          #
3340          # Cloud Tasks will pick the value of `max_burst_size` based on the
3341          # value of
3342          # max_dispatches_per_second.
3343          #
3344          # For App Engine queues that were created or updated using
3345          # `queue.yaml/xml`, `max_burst_size` is equal to
3346          # [bucket_size](https://cloud.google.com/appengine/docs/standard/python/config/queueref#bucket_size).
3347          # Since `max_burst_size` is output only, if
3348          # UpdateQueue is called on a queue
3349          # created by `queue.yaml/xml`, `max_burst_size` will be reset based
3350          # on the value of
3351          # max_dispatches_per_second,
3352          # regardless of whether
3353          # max_dispatches_per_second
3354          # is updated.
3355      "maxDispatchesPerSecond": 3.14, # The maximum rate at which tasks are dispatched from this queue.
3356          #
3357          # If unspecified when the queue is created, Cloud Tasks will pick the
3358          # default.
3359          #
3360          # * For App Engine queues, the maximum allowed value
3361          #   is 500.
3362          #
3363          #
3364          # This field has the same meaning as
3365          # [rate in
3366          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#rate).
3367    },
3368    "state": "A String", # Output only. The state of the queue.
3369        #
3370        # `state` can only be changed by called
3371        # PauseQueue,
3372        # ResumeQueue, or uploading
3373        # [queue.yaml/xml](https://cloud.google.com/appengine/docs/python/config/queueref).
3374        # UpdateQueue cannot be used to change `state`.
3375    "purgeTime": "A String", # Output only. The last time this queue was purged.
3376        #
3377        # All tasks that were created before this time
3378        # were purged.
3379        #
3380        # A queue can be purged using PurgeQueue, the
3381        # [App Engine Task Queue SDK, or the Cloud
3382        # Console](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/deleting-tasks-and-queues#purging_all_tasks_from_a_queue).
3383        #
3384        # Purge time will be truncated to the nearest microsecond. Purge
3385        # time will be unset if the queue has never been purged.
3386    "appEngineHttpQueue": { # App Engine HTTP queue. # AppEngineHttpQueue settings apply only to
3387        # App Engine tasks in this queue.
3388        # Http tasks are not affected by this proto.
3389        #
3390        # The task will be delivered to the App Engine application hostname
3391        # specified by its AppEngineHttpQueue and AppEngineHttpRequest.
3392        # The documentation for AppEngineHttpRequest explains how the
3393        # task's host URL is constructed.
3394        #
3395        # Using AppEngineHttpQueue requires
3396        # [`appengine.applications.get`](https://cloud.google.com/appengine/docs/admin-api/access-control)
3397        # Google IAM permission for the project
3398        # and the following scope:
3399        #
3400        # `https://www.googleapis.com/auth/cloud-platform`
3401      "appEngineRoutingOverride": { # App Engine Routing. # Overrides for the
3402          # task-level app_engine_routing.
3403          #
3404          # If set, `app_engine_routing_override` is used for all tasks in
3405          # the queue, no matter what the setting is for the
3406          # task-level app_engine_routing.
3407          #
3408          # Defines routing characteristics specific to App Engine - service, version,
3409          # and instance.
3410          #
3411          # For more information about services, versions, and instances see
3412          # [An Overview of App
3413          # Engine](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine),
3414          # [Microservices Architecture on Google App
3415          # Engine](https://cloud.google.com/appengine/docs/python/microservices-on-app-engine),
3416          # [App Engine Standard request
3417          # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed),
3418          # and [App Engine Flex request
3419          # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
3420        "instance": "A String", # App instance.
3421            #
3422            # By default, the task is sent to an instance which is available when
3423            # the task is attempted.
3424            #
3425            # Requests can only be sent to a specific instance if
3426            # [manual scaling is used in App Engine
3427            # Standard](https://cloud.google.com/appengine/docs/python/an-overview-of-app-engine?hl=en_US#scaling_types_and_instance_classes).
3428            # App Engine Flex does not support instances. For more information, see
3429            # [App Engine Standard request
3430            # routing](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed)
3431            # and [App Engine Flex request
3432            # routing](https://cloud.google.com/appengine/docs/flexible/python/how-requests-are-routed).
3433        "host": "A String", # Output only. The host that the task is sent to.
3434            #
3435            # The host is constructed from the domain name of the app associated with
3436            # the queue's project ID (for example <app-id>.appspot.com), and the
3437            # service, version,
3438            # and instance. Tasks which were created using
3439            # the App Engine SDK might have a custom domain name.
3440            #
3441            # For more information, see
3442            # [How Requests are
3443            # Routed](https://cloud.google.com/appengine/docs/standard/python/how-requests-are-routed).
3444        "version": "A String", # App version.
3445            #
3446            # By default, the task is sent to the version which is the default
3447            # version when the task is attempted.
3448            #
3449            # For some queues or tasks which were created using the App Engine
3450            # Task Queue API, host is not parsable
3451            # into service,
3452            # version, and
3453            # instance. For example, some tasks
3454            # which were created using the App Engine SDK use a custom domain
3455            # name; custom domains are not parsed by Cloud Tasks. If
3456            # host is not parsable, then
3457            # service,
3458            # version, and
3459            # instance are the empty string.
3460        "service": "A String", # App service.
3461            #
3462            # By default, the task is sent to the service which is the default
3463            # service when the task is attempted.
3464            #
3465            # For some queues or tasks which were created using the App Engine
3466            # Task Queue API, host is not parsable
3467            # into service,
3468            # version, and
3469            # instance. For example, some tasks
3470            # which were created using the App Engine SDK use a custom domain
3471            # name; custom domains are not parsed by Cloud Tasks. If
3472            # host is not parsable, then
3473            # service,
3474            # version, and
3475            # instance are the empty string.
3476      },
3477    },
3478    "retryConfig": { # Retry config. # Settings that determine the retry behavior.
3479        #
3480        # * For tasks created using Cloud Tasks: the queue-level retry settings
3481        #   apply to all tasks in the queue that were created using Cloud Tasks.
3482        #   Retry settings cannot be set on individual tasks.
3483        # * For tasks created using the App Engine SDK: the queue-level retry
3484        #   settings apply to all tasks in the queue which do not have retry settings
3485        #   explicitly set on the task and were created by the App Engine SDK. See
3486        #   [App Engine
3487        #   documentation](https://cloud.google.com/appengine/docs/standard/python/taskqueue/push/retrying-tasks).
3488        #
3489        # These settings determine when a failed task attempt is retried.
3490      "maxRetryDuration": "A String", # If positive, `max_retry_duration` specifies the time limit for
3491          # retrying a failed task, measured from when the task was first
3492          # attempted. Once `max_retry_duration` time has passed *and* the
3493          # task has been attempted max_attempts
3494          # times, no further attempts will be made and the task will be
3495          # deleted.
3496          #
3497          # If zero, then the task age is unlimited.
3498          #
3499          # If unspecified when the queue is created, Cloud Tasks will pick the
3500          # default.
3501          #
3502          #
3503          # `max_retry_duration` will be truncated to the nearest second.
3504          #
3505          # This field has the same meaning as
3506          # [task_age_limit in
3507          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3508      "maxDoublings": 42, # The time between retries will double `max_doublings` times.
3509          #
3510          # A task's retry interval starts at
3511          # min_backoff, then doubles
3512          # `max_doublings` times, then increases linearly, and finally
3513          # retries retries at intervals of
3514          # max_backoff up to
3515          # max_attempts times.
3516          #
3517          # For example, if min_backoff is 10s,
3518          # max_backoff is 300s, and
3519          # `max_doublings` is 3, then the a task will first be retried in
3520          # 10s. The retry interval will double three times, and then
3521          # increase linearly by 2^3 * 10s.  Finally, the task will retry at
3522          # intervals of max_backoff until the
3523          # task has been attempted max_attempts
3524          # times. Thus, the requests will retry at 10s, 20s, 40s, 80s, 160s,
3525          # 240s, 300s, 300s, ....
3526          #
3527          # If unspecified when the queue is created, Cloud Tasks will pick the
3528          # default.
3529          #
3530          #
3531          # This field has the same meaning as
3532          # [max_doublings in
3533          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3534      "maxAttempts": 42, # Number of attempts per task.
3535          #
3536          # Cloud Tasks will attempt the task `max_attempts` times (that is, if the
3537          # first attempt fails, then there will be `max_attempts - 1` retries). Must
3538          # be >= -1.
3539          #
3540          # If unspecified when the queue is created, Cloud Tasks will pick the
3541          # default.
3542          #
3543          # -1 indicates unlimited attempts.
3544          #
3545          # This field has the same meaning as
3546          # [task_retry_limit in
3547          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3548      "maxBackoff": "A String", # A task will be scheduled for retry between
3549          # min_backoff and
3550          # max_backoff duration after it fails,
3551          # if the queue's RetryConfig specifies that the task should be
3552          # retried.
3553          #
3554          # If unspecified when the queue is created, Cloud Tasks will pick the
3555          # default.
3556          #
3557          #
3558          # `max_backoff` will be truncated to the nearest second.
3559          #
3560          # This field has the same meaning as
3561          # [max_backoff_seconds in
3562          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3563      "minBackoff": "A String", # A task will be scheduled for retry between
3564          # min_backoff and
3565          # max_backoff duration after it fails,
3566          # if the queue's RetryConfig specifies that the task should be
3567          # retried.
3568          #
3569          # If unspecified when the queue is created, Cloud Tasks will pick the
3570          # default.
3571          #
3572          #
3573          # `min_backoff` will be truncated to the nearest second.
3574          #
3575          # This field has the same meaning as
3576          # [min_backoff_seconds in
3577          # queue.yaml/xml](https://cloud.google.com/appengine/docs/standard/python/config/queueref#retry_parameters).
3578    },
3579  }</pre>
3580</div>
3581
3582<div class="method">
3583    <code class="details" id="setIamPolicy">setIamPolicy(resource, body, x__xgafv=None)</code>
3584  <pre>Sets the access control policy for a Queue. Replaces any existing
3585policy.
3586
3587Note: The Cloud Console does not check queue-level IAM permissions yet.
3588Project-level permissions are required to use the Cloud Console.
3589
3590Authorization requires the following
3591[Google IAM](https://cloud.google.com/iam) permission on the specified
3592resource parent:
3593
3594* `cloudtasks.queues.setIamPolicy`
3595
3596Args:
3597  resource: string, REQUIRED: The resource for which the policy is being specified.
3598See the operation documentation for the appropriate value for this field. (required)
3599  body: object, The request body. (required)
3600    The object takes the form of:
3601
3602{ # Request message for `SetIamPolicy` method.
3603    "policy": { # Defines an Identity and Access Management (IAM) policy. It is used to # REQUIRED: The complete policy to be applied to the `resource`. The size of
3604        # the policy is limited to a few 10s of KB. An empty policy is a
3605        # valid policy but certain Cloud Platform services (such as Projects)
3606        # might reject them.
3607        # specify access control policies for Cloud Platform resources.
3608        #
3609        #
3610        # A `Policy` consists of a list of `bindings`. A `binding` binds a list of
3611        # `members` to a `role`, where the members can be user accounts, Google groups,
3612        # Google domains, and service accounts. A `role` is a named list of permissions
3613        # defined by IAM.
3614        #
3615        # **JSON Example**
3616        #
3617        #     {
3618        #       "bindings": [
3619        #         {
3620        #           "role": "roles/owner",
3621        #           "members": [
3622        #             "user:mike@example.com",
3623        #             "group:admins@example.com",
3624        #             "domain:google.com",
3625        #             "serviceAccount:my-other-app@appspot.gserviceaccount.com"
3626        #           ]
3627        #         },
3628        #         {
3629        #           "role": "roles/viewer",
3630        #           "members": ["user:sean@example.com"]
3631        #         }
3632        #       ]
3633        #     }
3634        #
3635        # **YAML Example**
3636        #
3637        #     bindings:
3638        #     - members:
3639        #       - user:mike@example.com
3640        #       - group:admins@example.com
3641        #       - domain:google.com
3642        #       - serviceAccount:my-other-app@appspot.gserviceaccount.com
3643        #       role: roles/owner
3644        #     - members:
3645        #       - user:sean@example.com
3646        #       role: roles/viewer
3647        #
3648        #
3649        # For a description of IAM and its features, see the
3650        # [IAM developer's guide](https://cloud.google.com/iam/docs).
3651      "bindings": [ # Associates a list of `members` to a `role`.
3652          # `bindings` with no members will result in an error.
3653        { # Associates `members` with a `role`.
3654          "role": "A String", # Role that is assigned to `members`.
3655              # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
3656          "condition": { # Represents an expression text. Example: # The condition that is associated with this binding.
3657              # NOTE: An unsatisfied condition will not allow user access via current
3658              # binding. Different bindings, including their conditions, are examined
3659              # independently.
3660              #
3661              #     title: "User account presence"
3662              #     description: "Determines whether the request has a user account"
3663              #     expression: "size(request.user) > 0"
3664            "description": "A String", # An optional description of the expression. This is a longer text which
3665                # describes the expression, e.g. when hovered over it in a UI.
3666            "expression": "A String", # Textual representation of an expression in
3667                # Common Expression Language syntax.
3668                #
3669                # The application context of the containing message determines which
3670                # well-known feature set of CEL is supported.
3671            "location": "A String", # An optional string indicating the location of the expression for error
3672                # reporting, e.g. a file name and a position in the file.
3673            "title": "A String", # An optional title for the expression, i.e. a short string describing
3674                # its purpose. This can be used e.g. in UIs which allow to enter the
3675                # expression.
3676          },
3677          "members": [ # Specifies the identities requesting access for a Cloud Platform resource.
3678              # `members` can have the following values:
3679              #
3680              # * `allUsers`: A special identifier that represents anyone who is
3681              #    on the internet; with or without a Google account.
3682              #
3683              # * `allAuthenticatedUsers`: A special identifier that represents anyone
3684              #    who is authenticated with a Google account or a service account.
3685              #
3686              # * `user:{emailid}`: An email address that represents a specific Google
3687              #    account. For example, `alice@gmail.com` .
3688              #
3689              #
3690              # * `serviceAccount:{emailid}`: An email address that represents a service
3691              #    account. For example, `my-other-app@appspot.gserviceaccount.com`.
3692              #
3693              # * `group:{emailid}`: An email address that represents a Google group.
3694              #    For example, `admins@example.com`.
3695              #
3696              #
3697              # * `domain:{domain}`: The G Suite domain (primary) that represents all the
3698              #    users of that domain. For example, `google.com` or `example.com`.
3699              #
3700            "A String",
3701          ],
3702        },
3703      ],
3704      "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help
3705          # prevent simultaneous updates of a policy from overwriting each other.
3706          # It is strongly suggested that systems make use of the `etag` in the
3707          # read-modify-write cycle to perform policy updates in order to avoid race
3708          # conditions: An `etag` is returned in the response to `getIamPolicy`, and
3709          # systems are expected to put that etag in the request to `setIamPolicy` to
3710          # ensure that their change will be applied to the same version of the policy.
3711          #
3712          # If no `etag` is provided in the call to `setIamPolicy`, then the existing
3713          # policy is overwritten blindly.
3714      "version": 42, # Deprecated.
3715    },
3716  }
3717
3718  x__xgafv: string, V1 error format.
3719    Allowed values
3720      1 - v1 error format
3721      2 - v2 error format
3722
3723Returns:
3724  An object of the form:
3725
3726    { # Defines an Identity and Access Management (IAM) policy. It is used to
3727      # specify access control policies for Cloud Platform resources.
3728      #
3729      #
3730      # A `Policy` consists of a list of `bindings`. A `binding` binds a list of
3731      # `members` to a `role`, where the members can be user accounts, Google groups,
3732      # Google domains, and service accounts. A `role` is a named list of permissions
3733      # defined by IAM.
3734      #
3735      # **JSON Example**
3736      #
3737      #     {
3738      #       "bindings": [
3739      #         {
3740      #           "role": "roles/owner",
3741      #           "members": [
3742      #             "user:mike@example.com",
3743      #             "group:admins@example.com",
3744      #             "domain:google.com",
3745      #             "serviceAccount:my-other-app@appspot.gserviceaccount.com"
3746      #           ]
3747      #         },
3748      #         {
3749      #           "role": "roles/viewer",
3750      #           "members": ["user:sean@example.com"]
3751      #         }
3752      #       ]
3753      #     }
3754      #
3755      # **YAML Example**
3756      #
3757      #     bindings:
3758      #     - members:
3759      #       - user:mike@example.com
3760      #       - group:admins@example.com
3761      #       - domain:google.com
3762      #       - serviceAccount:my-other-app@appspot.gserviceaccount.com
3763      #       role: roles/owner
3764      #     - members:
3765      #       - user:sean@example.com
3766      #       role: roles/viewer
3767      #
3768      #
3769      # For a description of IAM and its features, see the
3770      # [IAM developer's guide](https://cloud.google.com/iam/docs).
3771    "bindings": [ # Associates a list of `members` to a `role`.
3772        # `bindings` with no members will result in an error.
3773      { # Associates `members` with a `role`.
3774        "role": "A String", # Role that is assigned to `members`.
3775            # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
3776        "condition": { # Represents an expression text. Example: # The condition that is associated with this binding.
3777            # NOTE: An unsatisfied condition will not allow user access via current
3778            # binding. Different bindings, including their conditions, are examined
3779            # independently.
3780            #
3781            #     title: "User account presence"
3782            #     description: "Determines whether the request has a user account"
3783            #     expression: "size(request.user) > 0"
3784          "description": "A String", # An optional description of the expression. This is a longer text which
3785              # describes the expression, e.g. when hovered over it in a UI.
3786          "expression": "A String", # Textual representation of an expression in
3787              # Common Expression Language syntax.
3788              #
3789              # The application context of the containing message determines which
3790              # well-known feature set of CEL is supported.
3791          "location": "A String", # An optional string indicating the location of the expression for error
3792              # reporting, e.g. a file name and a position in the file.
3793          "title": "A String", # An optional title for the expression, i.e. a short string describing
3794              # its purpose. This can be used e.g. in UIs which allow to enter the
3795              # expression.
3796        },
3797        "members": [ # Specifies the identities requesting access for a Cloud Platform resource.
3798            # `members` can have the following values:
3799            #
3800            # * `allUsers`: A special identifier that represents anyone who is
3801            #    on the internet; with or without a Google account.
3802            #
3803            # * `allAuthenticatedUsers`: A special identifier that represents anyone
3804            #    who is authenticated with a Google account or a service account.
3805            #
3806            # * `user:{emailid}`: An email address that represents a specific Google
3807            #    account. For example, `alice@gmail.com` .
3808            #
3809            #
3810            # * `serviceAccount:{emailid}`: An email address that represents a service
3811            #    account. For example, `my-other-app@appspot.gserviceaccount.com`.
3812            #
3813            # * `group:{emailid}`: An email address that represents a Google group.
3814            #    For example, `admins@example.com`.
3815            #
3816            #
3817            # * `domain:{domain}`: The G Suite domain (primary) that represents all the
3818            #    users of that domain. For example, `google.com` or `example.com`.
3819            #
3820          "A String",
3821        ],
3822      },
3823    ],
3824    "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help
3825        # prevent simultaneous updates of a policy from overwriting each other.
3826        # It is strongly suggested that systems make use of the `etag` in the
3827        # read-modify-write cycle to perform policy updates in order to avoid race
3828        # conditions: An `etag` is returned in the response to `getIamPolicy`, and
3829        # systems are expected to put that etag in the request to `setIamPolicy` to
3830        # ensure that their change will be applied to the same version of the policy.
3831        #
3832        # If no `etag` is provided in the call to `setIamPolicy`, then the existing
3833        # policy is overwritten blindly.
3834    "version": 42, # Deprecated.
3835  }</pre>
3836</div>
3837
3838<div class="method">
3839    <code class="details" id="testIamPermissions">testIamPermissions(resource, body, x__xgafv=None)</code>
3840  <pre>Returns permissions that a caller has on a Queue.
3841If the resource does not exist, this will return an empty set of
3842permissions, not a NOT_FOUND error.
3843
3844Note: This operation is designed to be used for building permission-aware
3845UIs and command-line tools, not for authorization checking. This operation
3846may "fail open" without warning.
3847
3848Args:
3849  resource: string, REQUIRED: The resource for which the policy detail is being requested.
3850See the operation documentation for the appropriate value for this field. (required)
3851  body: object, The request body. (required)
3852    The object takes the form of:
3853
3854{ # Request message for `TestIamPermissions` method.
3855    "permissions": [ # The set of permissions to check for the `resource`. Permissions with
3856        # wildcards (such as '*' or 'storage.*') are not allowed. For more
3857        # information see
3858        # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
3859      "A String",
3860    ],
3861  }
3862
3863  x__xgafv: string, V1 error format.
3864    Allowed values
3865      1 - v1 error format
3866      2 - v2 error format
3867
3868Returns:
3869  An object of the form:
3870
3871    { # Response message for `TestIamPermissions` method.
3872    "permissions": [ # A subset of `TestPermissionsRequest.permissions` that the caller is
3873        # allowed.
3874      "A String",
3875    ],
3876  }</pre>
3877</div>
3878
3879</body></html>