google-cloud-tasks 0.3.0 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/google/cloud/tasks/v2beta2/cloud_tasks_client.rb +210 -181
- data/lib/google/cloud/tasks/v2beta2/cloudtasks_services_pb.rb +79 -63
- data/lib/google/cloud/tasks/v2beta2/doc/google/cloud/tasks/v2beta2/cloudtasks.rb +178 -146
- data/lib/google/cloud/tasks/v2beta2/doc/google/cloud/tasks/v2beta2/queue.rb +103 -68
- data/lib/google/cloud/tasks/v2beta2/doc/google/cloud/tasks/v2beta2/target.rb +110 -71
- data/lib/google/cloud/tasks/v2beta2/doc/google/cloud/tasks/v2beta2/task.rb +43 -25
- data/lib/google/cloud/tasks/v2beta2/doc/google/rpc/status.rb +17 -14
- data/lib/google/cloud/tasks/v2beta3/cloud_tasks_client.rb +123 -104
- data/lib/google/cloud/tasks/v2beta3/cloudtasks_services_pb.rb +51 -39
- data/lib/google/cloud/tasks/v2beta3/doc/google/cloud/tasks/v2beta3/cloudtasks.rb +116 -92
- data/lib/google/cloud/tasks/v2beta3/doc/google/cloud/tasks/v2beta3/queue.rb +84 -55
- data/lib/google/cloud/tasks/v2beta3/doc/google/cloud/tasks/v2beta3/target.rb +175 -52
- data/lib/google/cloud/tasks/v2beta3/doc/google/cloud/tasks/v2beta3/task.rb +40 -16
- data/lib/google/cloud/tasks/v2beta3/doc/google/rpc/status.rb +17 -14
- data/lib/google/cloud/tasks/v2beta3/target_pb.rb +7 -0
- data/lib/google/cloud/tasks/v2beta3/task_pb.rb +1 -0
- metadata +4 -4
@@ -20,7 +20,8 @@ module Google
|
|
20
20
|
# A unit of scheduled work.
|
21
21
|
# @!attribute [rw] name
|
22
22
|
# @return [String]
|
23
|
-
# Optionally caller-specified in
|
23
|
+
# Optionally caller-specified in
|
24
|
+
# {Google::Cloud::Tasks::V2beta2::CloudTasks::CreateTask CreateTask}.
|
24
25
|
#
|
25
26
|
# The task name.
|
26
27
|
#
|
@@ -30,7 +31,8 @@ module Google
|
|
30
31
|
# * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]),
|
31
32
|
# hyphens (-), colons (:), or periods (.).
|
32
33
|
# For more information, see
|
33
|
-
# [Identifying
|
34
|
+
# [Identifying
|
35
|
+
# projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects#identifying_projects)
|
34
36
|
# * `LOCATION_ID` is the canonical ID for the task's location.
|
35
37
|
# The list of available locations can be obtained by calling
|
36
38
|
# {Google::Cloud::Location::Locations::ListLocations ListLocations}.
|
@@ -43,16 +45,21 @@ module Google
|
|
43
45
|
# @return [Google::Cloud::Tasks::V2beta2::AppEngineHttpRequest]
|
44
46
|
# App Engine HTTP request that is sent to the task's target. Can
|
45
47
|
# be set only if
|
46
|
-
# {Google::Cloud::Tasks::V2beta2::Queue#app_engine_http_target app_engine_http_target}
|
47
|
-
# on the queue.
|
48
|
+
# {Google::Cloud::Tasks::V2beta2::Queue#app_engine_http_target app_engine_http_target}
|
49
|
+
# is set on the queue.
|
48
50
|
#
|
49
|
-
# An App Engine task is a task that has
|
51
|
+
# An App Engine task is a task that has
|
52
|
+
# {Google::Cloud::Tasks::V2beta2::AppEngineHttpRequest AppEngineHttpRequest}
|
53
|
+
# set.
|
50
54
|
# @!attribute [rw] pull_message
|
51
55
|
# @return [Google::Cloud::Tasks::V2beta2::PullMessage]
|
52
|
-
# {Google::Cloud::Tasks::V2beta2::CloudTasks::LeaseTasks LeaseTasks} to process
|
53
|
-
#
|
56
|
+
# {Google::Cloud::Tasks::V2beta2::CloudTasks::LeaseTasks LeaseTasks} to process
|
57
|
+
# the task. Can be set only if
|
58
|
+
# {Google::Cloud::Tasks::V2beta2::Queue#pull_target pull_target} is set on the
|
59
|
+
# queue.
|
54
60
|
#
|
55
|
-
# A pull task is a task that has
|
61
|
+
# A pull task is a task that has
|
62
|
+
# {Google::Cloud::Tasks::V2beta2::PullMessage PullMessage} set.
|
56
63
|
# @!attribute [rw] schedule_time
|
57
64
|
# @return [Google::Protobuf::Timestamp]
|
58
65
|
# The time when the task is scheduled to be attempted.
|
@@ -62,7 +69,8 @@ module Google
|
|
62
69
|
# For pull queues, this is the time when the task is available to
|
63
70
|
# be leased; if a task is currently leased, this is the time when
|
64
71
|
# the current lease expires, that is, the time that the task was
|
65
|
-
# leased plus the
|
72
|
+
# leased plus the
|
73
|
+
# {Google::Cloud::Tasks::V2beta2::LeaseTasksRequest#lease_duration lease_duration}.
|
66
74
|
#
|
67
75
|
# `schedule_time` will be truncated to the nearest microsecond.
|
68
76
|
# @!attribute [rw] create_time
|
@@ -75,10 +83,11 @@ module Google
|
|
75
83
|
# Output only. The task status.
|
76
84
|
# @!attribute [rw] view
|
77
85
|
# @return [Google::Cloud::Tasks::V2beta2::Task::View]
|
78
|
-
# Output only. The view specifies which subset of the
|
79
|
-
# been returned.
|
86
|
+
# Output only. The view specifies which subset of the
|
87
|
+
# {Google::Cloud::Tasks::V2beta2::Task Task} has been returned.
|
80
88
|
class Task
|
81
|
-
# The view specifies a subset of {Google::Cloud::Tasks::V2beta2::Task Task}
|
89
|
+
# The view specifies a subset of {Google::Cloud::Tasks::V2beta2::Task Task}
|
90
|
+
# data.
|
82
91
|
#
|
83
92
|
# When a task is returned in a response, not all
|
84
93
|
# information is retrieved by default because some data, such as
|
@@ -93,18 +102,21 @@ module Google
|
|
93
102
|
# sensitive data.
|
94
103
|
#
|
95
104
|
# This view does not include the
|
96
|
-
# (
|
97
|
-
#
|
98
|
-
#
|
99
|
-
#
|
100
|
-
#
|
105
|
+
# ([payload in
|
106
|
+
# AppEngineHttpRequest][google.cloud.tasks.v2beta2.AppEngineHttpRequest]
|
107
|
+
# and [payload in
|
108
|
+
# PullMessage][google.cloud.tasks.v2beta2.PullMessage.payload]). These
|
109
|
+
# payloads are desirable to return only when needed, because they can be
|
110
|
+
# large and because of the sensitivity of the data that you choose to store
|
111
|
+
# in it.
|
101
112
|
BASIC = 1
|
102
113
|
|
103
114
|
# All information is returned.
|
104
115
|
#
|
105
|
-
# Authorization for {Google::Cloud::Tasks::V2beta2::Task::View::FULL FULL}
|
106
|
-
# `cloudtasks.tasks.fullView` [Google
|
107
|
-
# permission on the
|
116
|
+
# Authorization for {Google::Cloud::Tasks::V2beta2::Task::View::FULL FULL}
|
117
|
+
# requires `cloudtasks.tasks.fullView` [Google
|
118
|
+
# IAM](https://cloud.google.com/iam/) permission on the
|
119
|
+
# {Google::Cloud::Tasks::V2beta2::Queue Queue} resource.
|
108
120
|
FULL = 2
|
109
121
|
end
|
110
122
|
end
|
@@ -120,20 +132,26 @@ module Google
|
|
120
132
|
# @return [Integer]
|
121
133
|
# Output only. The number of attempts which have received a response.
|
122
134
|
#
|
123
|
-
# This field is not calculated for
|
135
|
+
# This field is not calculated for [pull
|
136
|
+
# tasks][google.cloud.tasks.v2beta2.PullMessage].
|
124
137
|
# @!attribute [rw] first_attempt_status
|
125
138
|
# @return [Google::Cloud::Tasks::V2beta2::AttemptStatus]
|
126
139
|
# Output only. The status of the task's first attempt.
|
127
140
|
#
|
128
|
-
# Only
|
129
|
-
#
|
141
|
+
# Only
|
142
|
+
# {Google::Cloud::Tasks::V2beta2::AttemptStatus#dispatch_time dispatch_time}
|
143
|
+
# will be set. The other
|
144
|
+
# {Google::Cloud::Tasks::V2beta2::AttemptStatus AttemptStatus} information is
|
145
|
+
# not retained by Cloud Tasks.
|
130
146
|
#
|
131
|
-
# This field is not calculated for
|
147
|
+
# This field is not calculated for [pull
|
148
|
+
# tasks][google.cloud.tasks.v2beta2.PullMessage].
|
132
149
|
# @!attribute [rw] last_attempt_status
|
133
150
|
# @return [Google::Cloud::Tasks::V2beta2::AttemptStatus]
|
134
151
|
# Output only. The status of the task's last attempt.
|
135
152
|
#
|
136
|
-
# This field is not calculated for
|
153
|
+
# This field is not calculated for [pull
|
154
|
+
# tasks][google.cloud.tasks.v2beta2.PullMessage].
|
137
155
|
class TaskStatus; end
|
138
156
|
|
139
157
|
# The status of a task attempt.
|
@@ -15,24 +15,25 @@
|
|
15
15
|
|
16
16
|
module Google
|
17
17
|
module Rpc
|
18
|
-
# The `Status` type defines a logical error model that is suitable for
|
19
|
-
# programming environments, including REST APIs and RPC APIs. It is
|
20
|
-
# [gRPC](https://github.com/grpc). The error model is designed to be:
|
18
|
+
# The `Status` type defines a logical error model that is suitable for
|
19
|
+
# different programming environments, including REST APIs and RPC APIs. It is
|
20
|
+
# used by [gRPC](https://github.com/grpc). The error model is designed to be:
|
21
21
|
#
|
22
22
|
# * Simple to use and understand for most users
|
23
23
|
# * Flexible enough to meet unexpected needs
|
24
24
|
#
|
25
25
|
# = Overview
|
26
26
|
#
|
27
|
-
# The `Status` message contains three pieces of data: error code, error
|
28
|
-
# and error details. The error code should be an enum value of
|
29
|
-
# {Google::Rpc::Code}, but it may accept additional error codes
|
30
|
-
# error message should be a developer-facing English message
|
31
|
-
# developers *understand* and *resolve* the error. If a localized
|
32
|
-
# error message is needed, put the localized message in the error
|
33
|
-
# localize it in the client. The optional error details may contain
|
34
|
-
# information about the error. There is a predefined set of error
|
35
|
-
# in the package `google.rpc` that can be used for common error
|
27
|
+
# The `Status` message contains three pieces of data: error code, error
|
28
|
+
# message, and error details. The error code should be an enum value of
|
29
|
+
# {Google::Rpc::Code}, but it may accept additional error codes
|
30
|
+
# if needed. The error message should be a developer-facing English message
|
31
|
+
# that helps developers *understand* and *resolve* the error. If a localized
|
32
|
+
# user-facing error message is needed, put the localized message in the error
|
33
|
+
# details or localize it in the client. The optional error details may contain
|
34
|
+
# arbitrary information about the error. There is a predefined set of error
|
35
|
+
# detail types in the package `google.rpc` that can be used for common error
|
36
|
+
# conditions.
|
36
37
|
#
|
37
38
|
# = Language mapping
|
38
39
|
#
|
@@ -69,12 +70,14 @@ module Google
|
|
69
70
|
# be used directly after any stripping needed for security/privacy reasons.
|
70
71
|
# @!attribute [rw] code
|
71
72
|
# @return [Integer]
|
72
|
-
# The status code, which should be an enum value of
|
73
|
+
# The status code, which should be an enum value of
|
74
|
+
# {Google::Rpc::Code}.
|
73
75
|
# @!attribute [rw] message
|
74
76
|
# @return [String]
|
75
77
|
# A developer-facing error message, which should be in English. Any
|
76
78
|
# user-facing error message should be localized and sent in the
|
77
|
-
# {Google::Rpc::Status#details} field, or localized
|
79
|
+
# {Google::Rpc::Status#details} field, or localized
|
80
|
+
# by the client.
|
78
81
|
# @!attribute [rw] details
|
79
82
|
# @return [Array<Google::Protobuf::Any>]
|
80
83
|
# A list of messages that carry the error details. There is a common set of
|
@@ -389,11 +389,11 @@ module Google
|
|
389
389
|
# The location name.
|
390
390
|
# For example: `projects/PROJECT_ID/locations/LOCATION_ID`
|
391
391
|
# @param filter [String]
|
392
|
-
# `filter` can be used to specify a subset of queues. Any
|
393
|
-
# field can be used as a filter and
|
394
|
-
# For example: `<=, <, >=, >, !=, =, :`. The
|
395
|
-
# described in
|
396
|
-
#
|
392
|
+
# `filter` can be used to specify a subset of queues. Any
|
393
|
+
# {Google::Cloud::Tasks::V2beta3::Queue Queue} field can be used as a filter and
|
394
|
+
# several operators as supported. For example: `<=, <, >=, >, !=, =, :`. The
|
395
|
+
# filter syntax is the same as described in [Stackdriver's Advanced Logs
|
396
|
+
# Filters](https://cloud.google.com/logging/docs/view/advanced_filters).
|
397
397
|
#
|
398
398
|
# Sample filter "state: PAUSED".
|
399
399
|
#
|
@@ -487,14 +487,15 @@ module Google
|
|
487
487
|
# Creates a queue.
|
488
488
|
#
|
489
489
|
# Queues created with this method allow tasks to live for a maximum of 31
|
490
|
-
# days. After a task is 31 days old, the task will be deleted regardless of
|
491
|
-
# it was dispatched or not.
|
490
|
+
# days. After a task is 31 days old, the task will be deleted regardless of
|
491
|
+
# whether it was dispatched or not.
|
492
492
|
#
|
493
493
|
# WARNING: Using this method may have unintended side effects if you are
|
494
494
|
# using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
|
495
495
|
# Read
|
496
|
-
# [Overview of Queue Management and
|
497
|
-
# before using
|
496
|
+
# [Overview of Queue Management and
|
497
|
+
# queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
|
498
|
+
# this method.
|
498
499
|
#
|
499
500
|
# @param parent [String]
|
500
501
|
# Required.
|
@@ -510,7 +511,8 @@ module Google
|
|
510
511
|
#
|
511
512
|
# The queue to create.
|
512
513
|
#
|
513
|
-
# {Google::Cloud::Tasks::V2beta3::Queue#name Queue's name} cannot be the same as
|
514
|
+
# {Google::Cloud::Tasks::V2beta3::Queue#name Queue's name} cannot be the same as
|
515
|
+
# an existing queue.
|
514
516
|
# A hash of the same form as `Google::Cloud::Tasks::V2beta3::Queue`
|
515
517
|
# can also be provided.
|
516
518
|
# @param options [Google::Gax::CallOptions]
|
@@ -550,25 +552,28 @@ module Google
|
|
550
552
|
# the queue if it does exist.
|
551
553
|
#
|
552
554
|
# Queues created with this method allow tasks to live for a maximum of 31
|
553
|
-
# days. After a task is 31 days old, the task will be deleted regardless of
|
554
|
-
# it was dispatched or not.
|
555
|
+
# days. After a task is 31 days old, the task will be deleted regardless of
|
556
|
+
# whether it was dispatched or not.
|
555
557
|
#
|
556
558
|
# WARNING: Using this method may have unintended side effects if you are
|
557
559
|
# using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
|
558
560
|
# Read
|
559
|
-
# [Overview of Queue Management and
|
560
|
-
# before using
|
561
|
+
# [Overview of Queue Management and
|
562
|
+
# queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
|
563
|
+
# this method.
|
561
564
|
#
|
562
565
|
# @param queue [Google::Cloud::Tasks::V2beta3::Queue | Hash]
|
563
566
|
# Required.
|
564
567
|
#
|
565
568
|
# The queue to create or update.
|
566
569
|
#
|
567
|
-
# The queue's {Google::Cloud::Tasks::V2beta3::Queue#name name} must be
|
570
|
+
# The queue's {Google::Cloud::Tasks::V2beta3::Queue#name name} must be
|
571
|
+
# specified.
|
568
572
|
#
|
569
573
|
# Output only fields cannot be modified using UpdateQueue.
|
570
574
|
# Any value specified for an output only field will be ignored.
|
571
|
-
# The queue's {Google::Cloud::Tasks::V2beta3::Queue#name name} cannot be
|
575
|
+
# The queue's {Google::Cloud::Tasks::V2beta3::Queue#name name} cannot be
|
576
|
+
# changed.
|
572
577
|
# A hash of the same form as `Google::Cloud::Tasks::V2beta3::Queue`
|
573
578
|
# can also be provided.
|
574
579
|
# @param update_mask [Google::Protobuf::FieldMask | Hash]
|
@@ -617,8 +622,9 @@ module Google
|
|
617
622
|
# WARNING: Using this method may have unintended side effects if you are
|
618
623
|
# using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
|
619
624
|
# Read
|
620
|
-
# [Overview of Queue Management and
|
621
|
-
# before using
|
625
|
+
# [Overview of Queue Management and
|
626
|
+
# queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
|
627
|
+
# this method.
|
622
628
|
#
|
623
629
|
# @param name [String]
|
624
630
|
# Required.
|
@@ -693,9 +699,10 @@ module Google
|
|
693
699
|
#
|
694
700
|
# If a queue is paused then the system will stop dispatching tasks
|
695
701
|
# until the queue is resumed via
|
696
|
-
# {Google::Cloud::Tasks::V2beta3::CloudTasks::ResumeQueue ResumeQueue}. Tasks can
|
697
|
-
# when the queue is paused. A queue is paused if its
|
698
|
-
# {Google::Cloud::Tasks::V2beta3::Queue#state state} is
|
702
|
+
# {Google::Cloud::Tasks::V2beta3::CloudTasks::ResumeQueue ResumeQueue}. Tasks can
|
703
|
+
# still be added when the queue is paused. A queue is paused if its
|
704
|
+
# {Google::Cloud::Tasks::V2beta3::Queue#state state} is
|
705
|
+
# {Google::Cloud::Tasks::V2beta3::Queue::State::PAUSED PAUSED}.
|
699
706
|
#
|
700
707
|
# @param name [String]
|
701
708
|
# Required.
|
@@ -732,14 +739,17 @@ module Google
|
|
732
739
|
#
|
733
740
|
# This method resumes a queue after it has been
|
734
741
|
# {Google::Cloud::Tasks::V2beta3::Queue::State::PAUSED PAUSED} or
|
735
|
-
# {Google::Cloud::Tasks::V2beta3::Queue::State::DISABLED DISABLED}. The state of a
|
736
|
-
# in the queue's
|
737
|
-
#
|
742
|
+
# {Google::Cloud::Tasks::V2beta3::Queue::State::DISABLED DISABLED}. The state of a
|
743
|
+
# queue is stored in the queue's
|
744
|
+
# {Google::Cloud::Tasks::V2beta3::Queue#state state}; after calling this method
|
745
|
+
# it will be set to
|
746
|
+
# {Google::Cloud::Tasks::V2beta3::Queue::State::RUNNING RUNNING}.
|
738
747
|
#
|
739
748
|
# WARNING: Resuming many high-QPS queues at the same time can
|
740
749
|
# lead to target overloading. If you are resuming high-QPS
|
741
750
|
# queues, follow the 500/50/5 pattern described in
|
742
|
-
# [Managing Cloud Tasks Scaling
|
751
|
+
# [Managing Cloud Tasks Scaling
|
752
|
+
# Risks](https://cloud.google.com/tasks/docs/manage-cloud-task-scaling).
|
743
753
|
#
|
744
754
|
# @param name [String]
|
745
755
|
# Required.
|
@@ -772,9 +782,9 @@ module Google
|
|
772
782
|
@resume_queue.call(req, options, &block)
|
773
783
|
end
|
774
784
|
|
775
|
-
# Gets the access control policy for a
|
776
|
-
# Returns an empty policy if the
|
777
|
-
# set.
|
785
|
+
# Gets the access control policy for a
|
786
|
+
# {Google::Cloud::Tasks::V2beta3::Queue Queue}. Returns an empty policy if the
|
787
|
+
# resource exists and does not have a policy set.
|
778
788
|
#
|
779
789
|
# Authorization requires the following
|
780
790
|
# [Google IAM](https://cloud.google.com/iam) permission on the specified
|
@@ -812,8 +822,8 @@ module Google
|
|
812
822
|
@get_iam_policy.call(req, options, &block)
|
813
823
|
end
|
814
824
|
|
815
|
-
# Sets the access control policy for a
|
816
|
-
# policy.
|
825
|
+
# Sets the access control policy for a
|
826
|
+
# {Google::Cloud::Tasks::V2beta3::Queue Queue}. Replaces any existing policy.
|
817
827
|
#
|
818
828
|
# Note: The Cloud Console does not check queue-level IAM permissions yet.
|
819
829
|
# Project-level permissions are required to use the Cloud Console.
|
@@ -866,9 +876,10 @@ module Google
|
|
866
876
|
@set_iam_policy.call(req, options, &block)
|
867
877
|
end
|
868
878
|
|
869
|
-
# Returns permissions that a caller has on a
|
870
|
-
# If the resource does not exist,
|
871
|
-
# permissions, not a
|
879
|
+
# Returns permissions that a caller has on a
|
880
|
+
# {Google::Cloud::Tasks::V2beta3::Queue Queue}. If the resource does not exist,
|
881
|
+
# this will return an empty set of permissions, not a
|
882
|
+
# {Google::Rpc::Code::NOT_FOUND NOT_FOUND} error.
|
872
883
|
#
|
873
884
|
# Note: This operation is designed to be used for building permission-aware
|
874
885
|
# UIs and command-line tools, not for authorization checking. This operation
|
@@ -916,10 +927,10 @@ module Google
|
|
916
927
|
|
917
928
|
# Lists the tasks in a queue.
|
918
929
|
#
|
919
|
-
# By default, only the {Google::Cloud::Tasks::V2beta3::Task::View::BASIC BASIC}
|
920
|
-
# due to performance considerations;
|
921
|
-
# {Google::Cloud::Tasks::V2beta3::ListTasksRequest#response_view response_view}
|
922
|
-
# subset of information which is returned.
|
930
|
+
# By default, only the {Google::Cloud::Tasks::V2beta3::Task::View::BASIC BASIC}
|
931
|
+
# view is retrieved due to performance considerations;
|
932
|
+
# {Google::Cloud::Tasks::V2beta3::ListTasksRequest#response_view response_view}
|
933
|
+
# controls the subset of information which is returned.
|
923
934
|
#
|
924
935
|
# The tasks may be returned in any order. The ordering may change at any
|
925
936
|
# time.
|
@@ -930,18 +941,19 @@ module Google
|
|
930
941
|
# The queue name. For example:
|
931
942
|
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
|
932
943
|
# @param response_view [Google::Cloud::Tasks::V2beta3::Task::View]
|
933
|
-
# The response_view specifies which subset of the
|
934
|
-
# returned.
|
935
|
-
#
|
936
|
-
# By default response_view is
|
937
|
-
#
|
938
|
-
#
|
939
|
-
#
|
940
|
-
# contains.
|
941
|
-
#
|
942
|
-
# Authorization for {Google::Cloud::Tasks::V2beta3::Task::View::FULL FULL}
|
943
|
-
# `cloudtasks.tasks.fullView` [Google
|
944
|
-
# permission on the
|
944
|
+
# The response_view specifies which subset of the
|
945
|
+
# {Google::Cloud::Tasks::V2beta3::Task Task} will be returned.
|
946
|
+
#
|
947
|
+
# By default response_view is
|
948
|
+
# {Google::Cloud::Tasks::V2beta3::Task::View::BASIC BASIC}; not all information is
|
949
|
+
# retrieved by default because some data, such as payloads, might be
|
950
|
+
# desirable to return only when needed because of its large size or because
|
951
|
+
# of the sensitivity of data that it contains.
|
952
|
+
#
|
953
|
+
# Authorization for {Google::Cloud::Tasks::V2beta3::Task::View::FULL FULL}
|
954
|
+
# requires `cloudtasks.tasks.fullView` [Google
|
955
|
+
# IAM](https://cloud.google.com/iam/) permission on the
|
956
|
+
# {Google::Cloud::Tasks::V2beta3::Task Task} resource.
|
945
957
|
# @param page_size [Integer]
|
946
958
|
# The maximum number of resources contained in the underlying API
|
947
959
|
# response. If page streaming is performed per-resource, this
|
@@ -1002,18 +1014,19 @@ module Google
|
|
1002
1014
|
# The task name. For example:
|
1003
1015
|
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`
|
1004
1016
|
# @param response_view [Google::Cloud::Tasks::V2beta3::Task::View]
|
1005
|
-
# The response_view specifies which subset of the
|
1006
|
-
# returned.
|
1007
|
-
#
|
1008
|
-
# By default response_view is
|
1009
|
-
#
|
1010
|
-
#
|
1011
|
-
#
|
1012
|
-
# contains.
|
1013
|
-
#
|
1014
|
-
# Authorization for {Google::Cloud::Tasks::V2beta3::Task::View::FULL FULL}
|
1015
|
-
# `cloudtasks.tasks.fullView` [Google
|
1016
|
-
# permission on the
|
1017
|
+
# The response_view specifies which subset of the
|
1018
|
+
# {Google::Cloud::Tasks::V2beta3::Task Task} will be returned.
|
1019
|
+
#
|
1020
|
+
# By default response_view is
|
1021
|
+
# {Google::Cloud::Tasks::V2beta3::Task::View::BASIC BASIC}; not all information is
|
1022
|
+
# retrieved by default because some data, such as payloads, might be
|
1023
|
+
# desirable to return only when needed because of its large size or because
|
1024
|
+
# of the sensitivity of data that it contains.
|
1025
|
+
#
|
1026
|
+
# Authorization for {Google::Cloud::Tasks::V2beta3::Task::View::FULL FULL}
|
1027
|
+
# requires `cloudtasks.tasks.fullView` [Google
|
1028
|
+
# IAM](https://cloud.google.com/iam/) permission on the
|
1029
|
+
# {Google::Cloud::Tasks::V2beta3::Task Task} resource.
|
1017
1030
|
# @param options [Google::Gax::CallOptions]
|
1018
1031
|
# Overrides the default settings for this call, e.g, timeout,
|
1019
1032
|
# retries, etc.
|
@@ -1046,7 +1059,8 @@ module Google
|
|
1046
1059
|
#
|
1047
1060
|
# Tasks cannot be updated after creation; there is no UpdateTask command.
|
1048
1061
|
#
|
1049
|
-
# * For {Google::Cloud::Tasks::V2beta3::AppEngineHttpQueue App Engine queues},
|
1062
|
+
# * For {Google::Cloud::Tasks::V2beta3::AppEngineHttpQueue App Engine queues},
|
1063
|
+
# the maximum task size is
|
1050
1064
|
# 100KB.
|
1051
1065
|
#
|
1052
1066
|
# @param parent [String]
|
@@ -1063,13 +1077,13 @@ module Google
|
|
1063
1077
|
#
|
1064
1078
|
# Task names have the following format:
|
1065
1079
|
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`.
|
1066
|
-
# The user can optionally specify a task
|
1067
|
-
# name
|
1068
|
-
# unique task id, which will be set in
|
1069
|
-
# {Google::Cloud::Tasks::V2beta3::Task#name response}.
|
1080
|
+
# The user can optionally specify a task
|
1081
|
+
# {Google::Cloud::Tasks::V2beta3::Task#name name}. If a name is not specified
|
1082
|
+
# then the system will generate a random unique task id, which will be set in
|
1083
|
+
# the task returned in the {Google::Cloud::Tasks::V2beta3::Task#name response}.
|
1070
1084
|
#
|
1071
|
-
# If {Google::Cloud::Tasks::V2beta3::Task#schedule_time schedule_time} is not
|
1072
|
-
# past then Cloud Tasks will set it to the current time.
|
1085
|
+
# If {Google::Cloud::Tasks::V2beta3::Task#schedule_time schedule_time} is not
|
1086
|
+
# set or is in the past then Cloud Tasks will set it to the current time.
|
1073
1087
|
#
|
1074
1088
|
# Task De-duplication:
|
1075
1089
|
#
|
@@ -1084,10 +1098,10 @@ module Google
|
|
1084
1098
|
# for ~9days after the original task was deleted or executed.
|
1085
1099
|
#
|
1086
1100
|
# Because there is an extra lookup cost to identify duplicate task
|
1087
|
-
# names, these {Google::Cloud::Tasks::V2beta3::CloudTasks::CreateTask CreateTask}
|
1088
|
-
# increased latency. Using hashed strings for the
|
1089
|
-
# the prefix of the task id is recommended. Choosing task ids
|
1090
|
-
# are sequential or have sequential prefixes, for example using a
|
1101
|
+
# names, these {Google::Cloud::Tasks::V2beta3::CloudTasks::CreateTask CreateTask}
|
1102
|
+
# calls have significantly increased latency. Using hashed strings for the
|
1103
|
+
# task id or for the prefix of the task id is recommended. Choosing task ids
|
1104
|
+
# that are sequential or have sequential prefixes, for example using a
|
1091
1105
|
# timestamp, causes an increase in latency and error rates in all
|
1092
1106
|
# task commands. The infrastructure relies on an approximately
|
1093
1107
|
# uniform distribution of task ids to store and serve tasks
|
@@ -1095,18 +1109,19 @@ module Google
|
|
1095
1109
|
# A hash of the same form as `Google::Cloud::Tasks::V2beta3::Task`
|
1096
1110
|
# can also be provided.
|
1097
1111
|
# @param response_view [Google::Cloud::Tasks::V2beta3::Task::View]
|
1098
|
-
# The response_view specifies which subset of the
|
1099
|
-
# returned.
|
1100
|
-
#
|
1101
|
-
# By default response_view is
|
1102
|
-
#
|
1103
|
-
#
|
1104
|
-
#
|
1105
|
-
# contains.
|
1106
|
-
#
|
1107
|
-
# Authorization for {Google::Cloud::Tasks::V2beta3::Task::View::FULL FULL}
|
1108
|
-
# `cloudtasks.tasks.fullView` [Google
|
1109
|
-
# permission on the
|
1112
|
+
# The response_view specifies which subset of the
|
1113
|
+
# {Google::Cloud::Tasks::V2beta3::Task Task} will be returned.
|
1114
|
+
#
|
1115
|
+
# By default response_view is
|
1116
|
+
# {Google::Cloud::Tasks::V2beta3::Task::View::BASIC BASIC}; not all information is
|
1117
|
+
# retrieved by default because some data, such as payloads, might be
|
1118
|
+
# desirable to return only when needed because of its large size or because
|
1119
|
+
# of the sensitivity of data that it contains.
|
1120
|
+
#
|
1121
|
+
# Authorization for {Google::Cloud::Tasks::V2beta3::Task::View::FULL FULL}
|
1122
|
+
# requires `cloudtasks.tasks.fullView` [Google
|
1123
|
+
# IAM](https://cloud.google.com/iam/) permission on the
|
1124
|
+
# {Google::Cloud::Tasks::V2beta3::Task Task} resource.
|
1110
1125
|
# @param options [Google::Gax::CallOptions]
|
1111
1126
|
# Overrides the default settings for this call, e.g, timeout,
|
1112
1127
|
# retries, etc.
|
@@ -1180,13 +1195,14 @@ module Google
|
|
1180
1195
|
# Forces a task to run now.
|
1181
1196
|
#
|
1182
1197
|
# When this method is called, Cloud Tasks will dispatch the task, even if
|
1183
|
-
# the task is already running, the queue has reached its
|
1184
|
-
#
|
1198
|
+
# the task is already running, the queue has reached its
|
1199
|
+
# {Google::Cloud::Tasks::V2beta3::RateLimits RateLimits} or is
|
1200
|
+
# {Google::Cloud::Tasks::V2beta3::Queue::State::PAUSED PAUSED}.
|
1185
1201
|
#
|
1186
1202
|
# This command is meant to be used for manual debugging. For
|
1187
|
-
# example, {Google::Cloud::Tasks::V2beta3::CloudTasks::RunTask RunTask} can be
|
1188
|
-
# task after a fix has been made or to manually force
|
1189
|
-
# dispatched now.
|
1203
|
+
# example, {Google::Cloud::Tasks::V2beta3::CloudTasks::RunTask RunTask} can be
|
1204
|
+
# used to retry a failed task after a fix has been made or to manually force
|
1205
|
+
# a task to be dispatched now.
|
1190
1206
|
#
|
1191
1207
|
# The dispatched task is returned. That is, the task that is returned
|
1192
1208
|
# contains the {Task#status status} after the task is dispatched but
|
@@ -1194,9 +1210,11 @@ module Google
|
|
1194
1210
|
#
|
1195
1211
|
# If Cloud Tasks receives a successful response from the task's
|
1196
1212
|
# target, then the task will be deleted; otherwise the task's
|
1197
|
-
# {Google::Cloud::Tasks::V2beta3::Task#schedule_time schedule_time} will be
|
1198
|
-
#
|
1199
|
-
#
|
1213
|
+
# {Google::Cloud::Tasks::V2beta3::Task#schedule_time schedule_time} will be
|
1214
|
+
# reset to the time that
|
1215
|
+
# {Google::Cloud::Tasks::V2beta3::CloudTasks::RunTask RunTask} was called plus
|
1216
|
+
# the retry delay specified in the queue's
|
1217
|
+
# {Google::Cloud::Tasks::V2beta3::RetryConfig RetryConfig}.
|
1200
1218
|
#
|
1201
1219
|
# {Google::Cloud::Tasks::V2beta3::CloudTasks::RunTask RunTask} returns
|
1202
1220
|
# {Google::Rpc::Code::NOT_FOUND NOT_FOUND} when it is called on a
|
@@ -1208,18 +1226,19 @@ module Google
|
|
1208
1226
|
# The task name. For example:
|
1209
1227
|
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`
|
1210
1228
|
# @param response_view [Google::Cloud::Tasks::V2beta3::Task::View]
|
1211
|
-
# The response_view specifies which subset of the
|
1212
|
-
# returned.
|
1213
|
-
#
|
1214
|
-
# By default response_view is
|
1215
|
-
#
|
1216
|
-
#
|
1217
|
-
#
|
1218
|
-
# contains.
|
1219
|
-
#
|
1220
|
-
# Authorization for {Google::Cloud::Tasks::V2beta3::Task::View::FULL FULL}
|
1221
|
-
# `cloudtasks.tasks.fullView` [Google
|
1222
|
-
# permission on the
|
1229
|
+
# The response_view specifies which subset of the
|
1230
|
+
# {Google::Cloud::Tasks::V2beta3::Task Task} will be returned.
|
1231
|
+
#
|
1232
|
+
# By default response_view is
|
1233
|
+
# {Google::Cloud::Tasks::V2beta3::Task::View::BASIC BASIC}; not all information is
|
1234
|
+
# retrieved by default because some data, such as payloads, might be
|
1235
|
+
# desirable to return only when needed because of its large size or because
|
1236
|
+
# of the sensitivity of data that it contains.
|
1237
|
+
#
|
1238
|
+
# Authorization for {Google::Cloud::Tasks::V2beta3::Task::View::FULL FULL}
|
1239
|
+
# requires `cloudtasks.tasks.fullView` [Google
|
1240
|
+
# IAM](https://cloud.google.com/iam/) permission on the
|
1241
|
+
# {Google::Cloud::Tasks::V2beta3::Task Task} resource.
|
1223
1242
|
# @param options [Google::Gax::CallOptions]
|
1224
1243
|
# Overrides the default settings for this call, e.g, timeout,
|
1225
1244
|
# retries, etc.
|