google-cloud-tasks-v2beta3 0.3.1 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE.md +188 -190
- data/README.md +66 -2
- data/lib/google/cloud/tasks/v2beta3.rb +3 -0
- data/lib/google/cloud/tasks/v2beta3/cloud_tasks/client.rb +80 -64
- data/lib/google/cloud/tasks/v2beta3/cloudtasks_pb.rb +2 -0
- data/lib/google/cloud/tasks/v2beta3/cloudtasks_services_pb.rb +16 -16
- data/lib/google/cloud/tasks/v2beta3/queue_pb.rb +11 -0
- data/lib/google/cloud/tasks/v2beta3/target_pb.rb +5 -0
- data/lib/google/cloud/tasks/v2beta3/task_pb.rb +1 -0
- data/lib/google/cloud/tasks/v2beta3/version.rb +1 -1
- data/proto_docs/google/api/field_behavior.rb +6 -0
- data/proto_docs/google/api/resource.rb +50 -14
- data/proto_docs/google/cloud/tasks/v2beta3/cloudtasks.rb +12 -0
- data/proto_docs/google/cloud/tasks/v2beta3/queue.rb +73 -11
- data/proto_docs/google/cloud/tasks/v2beta3/target.rb +27 -0
- data/proto_docs/google/cloud/tasks/v2beta3/task.rb +9 -0
- data/proto_docs/google/protobuf/any.rb +5 -2
- data/proto_docs/google/protobuf/timestamp.rb +10 -1
- metadata +9 -7
@@ -61,90 +61,90 @@ module Google
|
|
61
61
|
parent_config = while namespace.any?
|
62
62
|
parent_name = namespace.join "::"
|
63
63
|
parent_const = const_get parent_name
|
64
|
-
break parent_const.configure if parent_const
|
64
|
+
break parent_const.configure if parent_const.respond_to? :configure
|
65
65
|
namespace.pop
|
66
66
|
end
|
67
67
|
default_config = Client::Configuration.new parent_config
|
68
68
|
|
69
|
-
default_config.rpcs.list_queues.timeout =
|
69
|
+
default_config.rpcs.list_queues.timeout = 20.0
|
70
70
|
default_config.rpcs.list_queues.retry_policy = {
|
71
71
|
initial_delay: 0.1,
|
72
|
-
|
73
|
-
|
74
|
-
|
72
|
+
max_delay: 10.0,
|
73
|
+
multiplier: 1.3,
|
74
|
+
retry_codes: [4, 14]
|
75
75
|
}
|
76
76
|
|
77
|
-
default_config.rpcs.get_queue.timeout =
|
77
|
+
default_config.rpcs.get_queue.timeout = 20.0
|
78
78
|
default_config.rpcs.get_queue.retry_policy = {
|
79
79
|
initial_delay: 0.1,
|
80
|
-
|
81
|
-
|
82
|
-
|
80
|
+
max_delay: 10.0,
|
81
|
+
multiplier: 1.3,
|
82
|
+
retry_codes: [4, 14]
|
83
83
|
}
|
84
84
|
|
85
|
-
default_config.rpcs.create_queue.timeout =
|
85
|
+
default_config.rpcs.create_queue.timeout = 20.0
|
86
86
|
|
87
|
-
default_config.rpcs.update_queue.timeout =
|
87
|
+
default_config.rpcs.update_queue.timeout = 20.0
|
88
88
|
|
89
|
-
default_config.rpcs.delete_queue.timeout =
|
89
|
+
default_config.rpcs.delete_queue.timeout = 20.0
|
90
90
|
default_config.rpcs.delete_queue.retry_policy = {
|
91
91
|
initial_delay: 0.1,
|
92
|
-
|
93
|
-
|
94
|
-
|
92
|
+
max_delay: 10.0,
|
93
|
+
multiplier: 1.3,
|
94
|
+
retry_codes: [4, 14]
|
95
95
|
}
|
96
96
|
|
97
|
-
default_config.rpcs.purge_queue.timeout =
|
97
|
+
default_config.rpcs.purge_queue.timeout = 20.0
|
98
98
|
|
99
|
-
default_config.rpcs.pause_queue.timeout =
|
99
|
+
default_config.rpcs.pause_queue.timeout = 20.0
|
100
100
|
|
101
|
-
default_config.rpcs.resume_queue.timeout =
|
101
|
+
default_config.rpcs.resume_queue.timeout = 20.0
|
102
102
|
|
103
|
-
default_config.rpcs.get_iam_policy.timeout =
|
103
|
+
default_config.rpcs.get_iam_policy.timeout = 20.0
|
104
104
|
default_config.rpcs.get_iam_policy.retry_policy = {
|
105
105
|
initial_delay: 0.1,
|
106
|
-
|
107
|
-
|
108
|
-
|
106
|
+
max_delay: 10.0,
|
107
|
+
multiplier: 1.3,
|
108
|
+
retry_codes: [4, 14]
|
109
109
|
}
|
110
110
|
|
111
|
-
default_config.rpcs.set_iam_policy.timeout =
|
111
|
+
default_config.rpcs.set_iam_policy.timeout = 20.0
|
112
112
|
|
113
|
-
default_config.rpcs.test_iam_permissions.timeout =
|
113
|
+
default_config.rpcs.test_iam_permissions.timeout = 20.0
|
114
114
|
default_config.rpcs.test_iam_permissions.retry_policy = {
|
115
115
|
initial_delay: 0.1,
|
116
|
-
|
117
|
-
|
118
|
-
|
116
|
+
max_delay: 10.0,
|
117
|
+
multiplier: 1.3,
|
118
|
+
retry_codes: [4, 14]
|
119
119
|
}
|
120
120
|
|
121
|
-
default_config.rpcs.list_tasks.timeout =
|
121
|
+
default_config.rpcs.list_tasks.timeout = 20.0
|
122
122
|
default_config.rpcs.list_tasks.retry_policy = {
|
123
123
|
initial_delay: 0.1,
|
124
|
-
|
125
|
-
|
126
|
-
|
124
|
+
max_delay: 10.0,
|
125
|
+
multiplier: 1.3,
|
126
|
+
retry_codes: [4, 14]
|
127
127
|
}
|
128
128
|
|
129
|
-
default_config.rpcs.get_task.timeout =
|
129
|
+
default_config.rpcs.get_task.timeout = 20.0
|
130
130
|
default_config.rpcs.get_task.retry_policy = {
|
131
131
|
initial_delay: 0.1,
|
132
|
-
|
133
|
-
|
134
|
-
|
132
|
+
max_delay: 10.0,
|
133
|
+
multiplier: 1.3,
|
134
|
+
retry_codes: [4, 14]
|
135
135
|
}
|
136
136
|
|
137
|
-
default_config.rpcs.create_task.timeout =
|
137
|
+
default_config.rpcs.create_task.timeout = 20.0
|
138
138
|
|
139
|
-
default_config.rpcs.delete_task.timeout =
|
139
|
+
default_config.rpcs.delete_task.timeout = 20.0
|
140
140
|
default_config.rpcs.delete_task.retry_policy = {
|
141
141
|
initial_delay: 0.1,
|
142
|
-
|
143
|
-
|
144
|
-
|
142
|
+
max_delay: 10.0,
|
143
|
+
multiplier: 1.3,
|
144
|
+
retry_codes: [4, 14]
|
145
145
|
}
|
146
146
|
|
147
|
-
default_config.rpcs.run_task.timeout =
|
147
|
+
default_config.rpcs.run_task.timeout = 20.0
|
148
148
|
|
149
149
|
default_config
|
150
150
|
end
|
@@ -207,7 +207,13 @@ module Google
|
|
207
207
|
|
208
208
|
# Create credentials
|
209
209
|
credentials = @config.credentials
|
210
|
-
|
210
|
+
# Use self-signed JWT if the scope and endpoint are unchanged from default,
|
211
|
+
# but only if the default endpoint does not have a region prefix.
|
212
|
+
enable_self_signed_jwt = @config.scope == Client.configure.scope &&
|
213
|
+
@config.endpoint == Client.configure.endpoint &&
|
214
|
+
!@config.endpoint.split(".").first.include?("-")
|
215
|
+
credentials ||= Credentials.default scope: @config.scope,
|
216
|
+
enable_self_signed_jwt: enable_self_signed_jwt
|
211
217
|
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
212
218
|
credentials = Credentials.new credentials, scope: @config.scope
|
213
219
|
end
|
@@ -240,7 +246,7 @@ module Google
|
|
240
246
|
# @param options [::Gapic::CallOptions, ::Hash]
|
241
247
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
242
248
|
#
|
243
|
-
# @overload list_queues(parent: nil, filter: nil, page_size: nil, page_token: nil)
|
249
|
+
# @overload list_queues(parent: nil, filter: nil, page_size: nil, page_token: nil, read_mask: nil)
|
244
250
|
# Pass arguments to `list_queues` via keyword arguments. Note that at
|
245
251
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
246
252
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
@@ -277,6 +283,11 @@ module Google
|
|
277
283
|
# from the previous call to {::Google::Cloud::Tasks::V2beta3::CloudTasks::Client#list_queues ListQueues}
|
278
284
|
# method. It is an error to switch the value of the
|
279
285
|
# {::Google::Cloud::Tasks::V2beta3::ListQueuesRequest#filter filter} while iterating through pages.
|
286
|
+
# @param read_mask [::Google::Protobuf::FieldMask, ::Hash]
|
287
|
+
# Optional. Read mask is used for a more granular control over what the API returns.
|
288
|
+
# If the mask is not present all fields will be returned except
|
289
|
+
# [Queue.stats]. [Queue.stats] will be returned only if it was explicitly
|
290
|
+
# specified in the mask.
|
280
291
|
#
|
281
292
|
# @yield [response, operation] Access the result along with the RPC operation
|
282
293
|
# @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::Tasks::V2beta3::Queue>]
|
@@ -337,7 +348,7 @@ module Google
|
|
337
348
|
# @param options [::Gapic::CallOptions, ::Hash]
|
338
349
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
339
350
|
#
|
340
|
-
# @overload get_queue(name: nil)
|
351
|
+
# @overload get_queue(name: nil, read_mask: nil)
|
341
352
|
# Pass arguments to `get_queue` via keyword arguments. Note that at
|
342
353
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
343
354
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
@@ -345,6 +356,11 @@ module Google
|
|
345
356
|
# @param name [::String]
|
346
357
|
# Required. The resource name of the queue. For example:
|
347
358
|
# `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
|
359
|
+
# @param read_mask [::Google::Protobuf::FieldMask, ::Hash]
|
360
|
+
# Optional. Read mask is used for a more granular control over what the API returns.
|
361
|
+
# If the mask is not present all fields will be returned except
|
362
|
+
# [Queue.stats]. [Queue.stats] will be returned only if it was explicitly
|
363
|
+
# specified in the mask.
|
348
364
|
#
|
349
365
|
# @yield [response, operation] Access the result along with the RPC operation
|
350
366
|
# @yieldparam response [::Google::Cloud::Tasks::V2beta3::Queue]
|
@@ -1675,14 +1691,14 @@ module Google
|
|
1675
1691
|
|
1676
1692
|
config_attr :endpoint, "cloudtasks.googleapis.com", ::String
|
1677
1693
|
config_attr :credentials, nil do |value|
|
1678
|
-
allowed = [::String, ::Hash, ::Proc, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
1694
|
+
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
1679
1695
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
1680
1696
|
allowed.any? { |klass| klass === value }
|
1681
1697
|
end
|
1682
1698
|
config_attr :scope, nil, ::String, ::Array, nil
|
1683
1699
|
config_attr :lib_name, nil, ::String, nil
|
1684
1700
|
config_attr :lib_version, nil, ::String, nil
|
1685
|
-
config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil)
|
1701
|
+
config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil)
|
1686
1702
|
config_attr :interceptors, nil, ::Array, nil
|
1687
1703
|
config_attr :timeout, nil, ::Numeric, nil
|
1688
1704
|
config_attr :metadata, nil, ::Hash, nil
|
@@ -1703,7 +1719,7 @@ module Google
|
|
1703
1719
|
def rpcs
|
1704
1720
|
@rpcs ||= begin
|
1705
1721
|
parent_rpcs = nil
|
1706
|
-
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config
|
1722
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
|
1707
1723
|
Rpcs.new parent_rpcs
|
1708
1724
|
end
|
1709
1725
|
end
|
@@ -1715,7 +1731,7 @@ module Google
|
|
1715
1731
|
# Each configuration object is of type `Gapic::Config::Method` and includes
|
1716
1732
|
# the following configuration fields:
|
1717
1733
|
#
|
1718
|
-
# * `timeout` (*type:* `Numeric`) - The call timeout in
|
1734
|
+
# * `timeout` (*type:* `Numeric`) - The call timeout in seconds
|
1719
1735
|
# * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers
|
1720
1736
|
# * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
|
1721
1737
|
# include the following keys:
|
@@ -1809,37 +1825,37 @@ module Google
|
|
1809
1825
|
|
1810
1826
|
# @private
|
1811
1827
|
def initialize parent_rpcs = nil
|
1812
|
-
list_queues_config = parent_rpcs
|
1828
|
+
list_queues_config = parent_rpcs.list_queues if parent_rpcs.respond_to? :list_queues
|
1813
1829
|
@list_queues = ::Gapic::Config::Method.new list_queues_config
|
1814
|
-
get_queue_config = parent_rpcs
|
1830
|
+
get_queue_config = parent_rpcs.get_queue if parent_rpcs.respond_to? :get_queue
|
1815
1831
|
@get_queue = ::Gapic::Config::Method.new get_queue_config
|
1816
|
-
create_queue_config = parent_rpcs
|
1832
|
+
create_queue_config = parent_rpcs.create_queue if parent_rpcs.respond_to? :create_queue
|
1817
1833
|
@create_queue = ::Gapic::Config::Method.new create_queue_config
|
1818
|
-
update_queue_config = parent_rpcs
|
1834
|
+
update_queue_config = parent_rpcs.update_queue if parent_rpcs.respond_to? :update_queue
|
1819
1835
|
@update_queue = ::Gapic::Config::Method.new update_queue_config
|
1820
|
-
delete_queue_config = parent_rpcs
|
1836
|
+
delete_queue_config = parent_rpcs.delete_queue if parent_rpcs.respond_to? :delete_queue
|
1821
1837
|
@delete_queue = ::Gapic::Config::Method.new delete_queue_config
|
1822
|
-
purge_queue_config = parent_rpcs
|
1838
|
+
purge_queue_config = parent_rpcs.purge_queue if parent_rpcs.respond_to? :purge_queue
|
1823
1839
|
@purge_queue = ::Gapic::Config::Method.new purge_queue_config
|
1824
|
-
pause_queue_config = parent_rpcs
|
1840
|
+
pause_queue_config = parent_rpcs.pause_queue if parent_rpcs.respond_to? :pause_queue
|
1825
1841
|
@pause_queue = ::Gapic::Config::Method.new pause_queue_config
|
1826
|
-
resume_queue_config = parent_rpcs
|
1842
|
+
resume_queue_config = parent_rpcs.resume_queue if parent_rpcs.respond_to? :resume_queue
|
1827
1843
|
@resume_queue = ::Gapic::Config::Method.new resume_queue_config
|
1828
|
-
get_iam_policy_config = parent_rpcs
|
1844
|
+
get_iam_policy_config = parent_rpcs.get_iam_policy if parent_rpcs.respond_to? :get_iam_policy
|
1829
1845
|
@get_iam_policy = ::Gapic::Config::Method.new get_iam_policy_config
|
1830
|
-
set_iam_policy_config = parent_rpcs
|
1846
|
+
set_iam_policy_config = parent_rpcs.set_iam_policy if parent_rpcs.respond_to? :set_iam_policy
|
1831
1847
|
@set_iam_policy = ::Gapic::Config::Method.new set_iam_policy_config
|
1832
|
-
test_iam_permissions_config = parent_rpcs
|
1848
|
+
test_iam_permissions_config = parent_rpcs.test_iam_permissions if parent_rpcs.respond_to? :test_iam_permissions
|
1833
1849
|
@test_iam_permissions = ::Gapic::Config::Method.new test_iam_permissions_config
|
1834
|
-
list_tasks_config = parent_rpcs
|
1850
|
+
list_tasks_config = parent_rpcs.list_tasks if parent_rpcs.respond_to? :list_tasks
|
1835
1851
|
@list_tasks = ::Gapic::Config::Method.new list_tasks_config
|
1836
|
-
get_task_config = parent_rpcs
|
1852
|
+
get_task_config = parent_rpcs.get_task if parent_rpcs.respond_to? :get_task
|
1837
1853
|
@get_task = ::Gapic::Config::Method.new get_task_config
|
1838
|
-
create_task_config = parent_rpcs
|
1854
|
+
create_task_config = parent_rpcs.create_task if parent_rpcs.respond_to? :create_task
|
1839
1855
|
@create_task = ::Gapic::Config::Method.new create_task_config
|
1840
|
-
delete_task_config = parent_rpcs
|
1856
|
+
delete_task_config = parent_rpcs.delete_task if parent_rpcs.respond_to? :delete_task
|
1841
1857
|
@delete_task = ::Gapic::Config::Method.new delete_task_config
|
1842
|
-
run_task_config = parent_rpcs
|
1858
|
+
run_task_config = parent_rpcs.run_task if parent_rpcs.respond_to? :run_task
|
1843
1859
|
@run_task = ::Gapic::Config::Method.new run_task_config
|
1844
1860
|
|
1845
1861
|
yield self if block_given?
|
@@ -20,6 +20,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
20
20
|
optional :filter, :string, 2
|
21
21
|
optional :page_size, :int32, 3
|
22
22
|
optional :page_token, :string, 4
|
23
|
+
optional :read_mask, :message, 5, "google.protobuf.FieldMask"
|
23
24
|
end
|
24
25
|
add_message "google.cloud.tasks.v2beta3.ListQueuesResponse" do
|
25
26
|
repeated :queues, :message, 1, "google.cloud.tasks.v2beta3.Queue"
|
@@ -27,6 +28,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
27
28
|
end
|
28
29
|
add_message "google.cloud.tasks.v2beta3.GetQueueRequest" do
|
29
30
|
optional :name, :string, 1
|
31
|
+
optional :read_mask, :message, 2, "google.protobuf.FieldMask"
|
30
32
|
end
|
31
33
|
add_message "google.cloud.tasks.v2beta3.CreateQueueRequest" do
|
32
34
|
optional :parent, :string, 1
|
@@ -37,9 +37,9 @@ module Google
|
|
37
37
|
# Lists queues.
|
38
38
|
#
|
39
39
|
# Queues are returned in lexicographical order.
|
40
|
-
rpc :ListQueues, Google::Cloud::Tasks::V2beta3::ListQueuesRequest, Google::Cloud::Tasks::V2beta3::ListQueuesResponse
|
40
|
+
rpc :ListQueues, ::Google::Cloud::Tasks::V2beta3::ListQueuesRequest, ::Google::Cloud::Tasks::V2beta3::ListQueuesResponse
|
41
41
|
# Gets a queue.
|
42
|
-
rpc :GetQueue, Google::Cloud::Tasks::V2beta3::GetQueueRequest, Google::Cloud::Tasks::V2beta3::Queue
|
42
|
+
rpc :GetQueue, ::Google::Cloud::Tasks::V2beta3::GetQueueRequest, ::Google::Cloud::Tasks::V2beta3::Queue
|
43
43
|
# Creates a queue.
|
44
44
|
#
|
45
45
|
# Queues created with this method allow tasks to live for a maximum of 31
|
@@ -52,7 +52,7 @@ module Google
|
|
52
52
|
# [Overview of Queue Management and
|
53
53
|
# queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
|
54
54
|
# this method.
|
55
|
-
rpc :CreateQueue, Google::Cloud::Tasks::V2beta3::CreateQueueRequest, Google::Cloud::Tasks::V2beta3::Queue
|
55
|
+
rpc :CreateQueue, ::Google::Cloud::Tasks::V2beta3::CreateQueueRequest, ::Google::Cloud::Tasks::V2beta3::Queue
|
56
56
|
# Updates a queue.
|
57
57
|
#
|
58
58
|
# This method creates the queue if it does not exist and updates
|
@@ -68,7 +68,7 @@ module Google
|
|
68
68
|
# [Overview of Queue Management and
|
69
69
|
# queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
|
70
70
|
# this method.
|
71
|
-
rpc :UpdateQueue, Google::Cloud::Tasks::V2beta3::UpdateQueueRequest, Google::Cloud::Tasks::V2beta3::Queue
|
71
|
+
rpc :UpdateQueue, ::Google::Cloud::Tasks::V2beta3::UpdateQueueRequest, ::Google::Cloud::Tasks::V2beta3::Queue
|
72
72
|
# Deletes a queue.
|
73
73
|
#
|
74
74
|
# This command will delete the queue even if it has tasks in it.
|
@@ -82,14 +82,14 @@ module Google
|
|
82
82
|
# [Overview of Queue Management and
|
83
83
|
# queue.yaml](https://cloud.google.com/tasks/docs/queue-yaml) before using
|
84
84
|
# this method.
|
85
|
-
rpc :DeleteQueue, Google::Cloud::Tasks::V2beta3::DeleteQueueRequest, Google::Protobuf::Empty
|
85
|
+
rpc :DeleteQueue, ::Google::Cloud::Tasks::V2beta3::DeleteQueueRequest, ::Google::Protobuf::Empty
|
86
86
|
# Purges a queue by deleting all of its tasks.
|
87
87
|
#
|
88
88
|
# All tasks created before this method is called are permanently deleted.
|
89
89
|
#
|
90
90
|
# Purge operations can take up to one minute to take effect. Tasks
|
91
91
|
# might be dispatched before the purge takes effect. A purge is irreversible.
|
92
|
-
rpc :PurgeQueue, Google::Cloud::Tasks::V2beta3::PurgeQueueRequest, Google::Cloud::Tasks::V2beta3::Queue
|
92
|
+
rpc :PurgeQueue, ::Google::Cloud::Tasks::V2beta3::PurgeQueueRequest, ::Google::Cloud::Tasks::V2beta3::Queue
|
93
93
|
# Pauses the queue.
|
94
94
|
#
|
95
95
|
# If a queue is paused then the system will stop dispatching tasks
|
@@ -97,7 +97,7 @@ module Google
|
|
97
97
|
# [ResumeQueue][google.cloud.tasks.v2beta3.CloudTasks.ResumeQueue]. Tasks can still be added
|
98
98
|
# when the queue is paused. A queue is paused if its
|
99
99
|
# [state][google.cloud.tasks.v2beta3.Queue.state] is [PAUSED][google.cloud.tasks.v2beta3.Queue.State.PAUSED].
|
100
|
-
rpc :PauseQueue, Google::Cloud::Tasks::V2beta3::PauseQueueRequest, Google::Cloud::Tasks::V2beta3::Queue
|
100
|
+
rpc :PauseQueue, ::Google::Cloud::Tasks::V2beta3::PauseQueueRequest, ::Google::Cloud::Tasks::V2beta3::Queue
|
101
101
|
# Resume a queue.
|
102
102
|
#
|
103
103
|
# This method resumes a queue after it has been
|
@@ -111,7 +111,7 @@ module Google
|
|
111
111
|
# queues, follow the 500/50/5 pattern described in
|
112
112
|
# [Managing Cloud Tasks Scaling
|
113
113
|
# Risks](https://cloud.google.com/tasks/docs/manage-cloud-task-scaling).
|
114
|
-
rpc :ResumeQueue, Google::Cloud::Tasks::V2beta3::ResumeQueueRequest, Google::Cloud::Tasks::V2beta3::Queue
|
114
|
+
rpc :ResumeQueue, ::Google::Cloud::Tasks::V2beta3::ResumeQueueRequest, ::Google::Cloud::Tasks::V2beta3::Queue
|
115
115
|
# Gets the access control policy for a [Queue][google.cloud.tasks.v2beta3.Queue].
|
116
116
|
# Returns an empty policy if the resource exists and does not have a policy
|
117
117
|
# set.
|
@@ -121,7 +121,7 @@ module Google
|
|
121
121
|
# resource parent:
|
122
122
|
#
|
123
123
|
# * `cloudtasks.queues.getIamPolicy`
|
124
|
-
rpc :GetIamPolicy, Google::Iam::V1::GetIamPolicyRequest, Google::Iam::V1::Policy
|
124
|
+
rpc :GetIamPolicy, ::Google::Iam::V1::GetIamPolicyRequest, ::Google::Iam::V1::Policy
|
125
125
|
# Sets the access control policy for a [Queue][google.cloud.tasks.v2beta3.Queue]. Replaces any existing
|
126
126
|
# policy.
|
127
127
|
#
|
@@ -133,7 +133,7 @@ module Google
|
|
133
133
|
# resource parent:
|
134
134
|
#
|
135
135
|
# * `cloudtasks.queues.setIamPolicy`
|
136
|
-
rpc :SetIamPolicy, Google::Iam::V1::SetIamPolicyRequest, Google::Iam::V1::Policy
|
136
|
+
rpc :SetIamPolicy, ::Google::Iam::V1::SetIamPolicyRequest, ::Google::Iam::V1::Policy
|
137
137
|
# Returns permissions that a caller has on a [Queue][google.cloud.tasks.v2beta3.Queue].
|
138
138
|
# If the resource does not exist, this will return an empty set of
|
139
139
|
# permissions, not a [NOT_FOUND][google.rpc.Code.NOT_FOUND] error.
|
@@ -141,7 +141,7 @@ module Google
|
|
141
141
|
# Note: This operation is designed to be used for building permission-aware
|
142
142
|
# UIs and command-line tools, not for authorization checking. This operation
|
143
143
|
# may "fail open" without warning.
|
144
|
-
rpc :TestIamPermissions, Google::Iam::V1::TestIamPermissionsRequest, Google::Iam::V1::TestIamPermissionsResponse
|
144
|
+
rpc :TestIamPermissions, ::Google::Iam::V1::TestIamPermissionsRequest, ::Google::Iam::V1::TestIamPermissionsResponse
|
145
145
|
# Lists the tasks in a queue.
|
146
146
|
#
|
147
147
|
# By default, only the [BASIC][google.cloud.tasks.v2beta3.Task.View.BASIC] view is retrieved
|
@@ -151,21 +151,21 @@ module Google
|
|
151
151
|
#
|
152
152
|
# The tasks may be returned in any order. The ordering may change at any
|
153
153
|
# time.
|
154
|
-
rpc :ListTasks, Google::Cloud::Tasks::V2beta3::ListTasksRequest, Google::Cloud::Tasks::V2beta3::ListTasksResponse
|
154
|
+
rpc :ListTasks, ::Google::Cloud::Tasks::V2beta3::ListTasksRequest, ::Google::Cloud::Tasks::V2beta3::ListTasksResponse
|
155
155
|
# Gets a task.
|
156
|
-
rpc :GetTask, Google::Cloud::Tasks::V2beta3::GetTaskRequest, Google::Cloud::Tasks::V2beta3::Task
|
156
|
+
rpc :GetTask, ::Google::Cloud::Tasks::V2beta3::GetTaskRequest, ::Google::Cloud::Tasks::V2beta3::Task
|
157
157
|
# Creates a task and adds it to a queue.
|
158
158
|
#
|
159
159
|
# Tasks cannot be updated after creation; there is no UpdateTask command.
|
160
160
|
#
|
161
161
|
# * The maximum task size is 100KB.
|
162
|
-
rpc :CreateTask, Google::Cloud::Tasks::V2beta3::CreateTaskRequest, Google::Cloud::Tasks::V2beta3::Task
|
162
|
+
rpc :CreateTask, ::Google::Cloud::Tasks::V2beta3::CreateTaskRequest, ::Google::Cloud::Tasks::V2beta3::Task
|
163
163
|
# Deletes a task.
|
164
164
|
#
|
165
165
|
# A task can be deleted if it is scheduled or dispatched. A task
|
166
166
|
# cannot be deleted if it has executed successfully or permanently
|
167
167
|
# failed.
|
168
|
-
rpc :DeleteTask, Google::Cloud::Tasks::V2beta3::DeleteTaskRequest, Google::Protobuf::Empty
|
168
|
+
rpc :DeleteTask, ::Google::Cloud::Tasks::V2beta3::DeleteTaskRequest, ::Google::Protobuf::Empty
|
169
169
|
# Forces a task to run now.
|
170
170
|
#
|
171
171
|
# When this method is called, Cloud Tasks will dispatch the task, even if
|
@@ -190,7 +190,7 @@ module Google
|
|
190
190
|
# [RunTask][google.cloud.tasks.v2beta3.CloudTasks.RunTask] returns
|
191
191
|
# [NOT_FOUND][google.rpc.Code.NOT_FOUND] when it is called on a
|
192
192
|
# task that has already succeeded or permanently failed.
|
193
|
-
rpc :RunTask, Google::Cloud::Tasks::V2beta3::RunTaskRequest, Google::Cloud::Tasks::V2beta3::Task
|
193
|
+
rpc :RunTask, ::Google::Cloud::Tasks::V2beta3::RunTaskRequest, ::Google::Cloud::Tasks::V2beta3::Task
|
194
194
|
end
|
195
195
|
|
196
196
|
Stub = Service.rpc_stub_class
|
@@ -17,8 +17,11 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
17
17
|
optional :retry_config, :message, 5, "google.cloud.tasks.v2beta3.RetryConfig"
|
18
18
|
optional :state, :enum, 6, "google.cloud.tasks.v2beta3.Queue.State"
|
19
19
|
optional :purge_time, :message, 7, "google.protobuf.Timestamp"
|
20
|
+
optional :task_ttl, :message, 8, "google.protobuf.Duration"
|
21
|
+
optional :tombstone_ttl, :message, 9, "google.protobuf.Duration"
|
20
22
|
optional :stackdriver_logging_config, :message, 10, "google.cloud.tasks.v2beta3.StackdriverLoggingConfig"
|
21
23
|
optional :type, :enum, 11, "google.cloud.tasks.v2beta3.Queue.Type"
|
24
|
+
optional :stats, :message, 12, "google.cloud.tasks.v2beta3.QueueStats"
|
22
25
|
oneof :queue_type do
|
23
26
|
optional :app_engine_http_queue, :message, 3, "google.cloud.tasks.v2beta3.AppEngineHttpQueue"
|
24
27
|
end
|
@@ -49,6 +52,13 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
49
52
|
add_message "google.cloud.tasks.v2beta3.StackdriverLoggingConfig" do
|
50
53
|
optional :sampling_ratio, :double, 1
|
51
54
|
end
|
55
|
+
add_message "google.cloud.tasks.v2beta3.QueueStats" do
|
56
|
+
optional :tasks_count, :int64, 1
|
57
|
+
optional :oldest_estimated_arrival_time, :message, 2, "google.protobuf.Timestamp"
|
58
|
+
optional :executed_last_minute_count, :int64, 3
|
59
|
+
optional :concurrent_dispatches_count, :int64, 4
|
60
|
+
optional :effective_execution_rate, :double, 5
|
61
|
+
end
|
52
62
|
end
|
53
63
|
end
|
54
64
|
|
@@ -62,6 +72,7 @@ module Google
|
|
62
72
|
RateLimits = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.tasks.v2beta3.RateLimits").msgclass
|
63
73
|
RetryConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.tasks.v2beta3.RetryConfig").msgclass
|
64
74
|
StackdriverLoggingConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.tasks.v2beta3.StackdriverLoggingConfig").msgclass
|
75
|
+
QueueStats = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.tasks.v2beta3.QueueStats").msgclass
|
65
76
|
end
|
66
77
|
end
|
67
78
|
end
|