google-cloud-tasks-v2 0.8.1 → 0.9.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d19c1d16ce46fdff9efe4e09da41713dfc4688a7765c1b9ef616e15aaad1c1ce
4
- data.tar.gz: a9edcb064ffd9563abf463e59d725bde83f25185df206f97c1c5d65f1446bbb5
3
+ metadata.gz: 4609c324323ef5da39a20b7e7badaf67d4c10729d08dde1cce9147d5dd96a070
4
+ data.tar.gz: b1ea7e746c8cfa67676c4753997a99da6f4ef2d1edde3a9803ce61299e440e77
5
5
  SHA512:
6
- metadata.gz: cdd6ccf2e6853eef6b6519a251932cbf1402c3f48f62d30a43e1024ec31d46d7d7684a68fdea3a4bacc0d723aa31bcbda4414a610bd8024a6f823621bce7a183
7
- data.tar.gz: b777245c9a50419ad47852b2f63fc9284feb66fd5bb832ffb38c56f466ff31a1b12c6fdd5406681301ad47b97893e21d2674bf96155e394f45c3166d2db5dd59
6
+ metadata.gz: 9b3a436272c5c31399e847de2cf6b6a6ca52c5a38e39754427eecee8c44a9588b3811cfc619e4387f7f0bad76f470dcdd302a54e4b917aae11970b652da68f30
7
+ data.tar.gz: e26fb942b05db20d0430c7c9984c1fbcf16d13a779644c3c2df1ac8da22b9a0afd449a9e817912fb2af422f1be657d57293f77362e3a1b9c1687a9874a26e87a
@@ -0,0 +1,102 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2023 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+ require "gapic/config"
20
+
21
+ module Google
22
+ module Cloud
23
+ module Tasks
24
+ ##
25
+ # @example Loading just the REST part of this package, including all its services, and instantiating a REST client
26
+ #
27
+ # require "google/cloud/tasks/v2/rest"
28
+ # client = ::Google::Cloud::Tasks::V2::CloudTasks::Rest::Client.new
29
+ #
30
+ module V2
31
+ ##
32
+ # @private
33
+ # Initialize the mixin bindings configuration
34
+ #
35
+ def self.configure
36
+ @configure ||= begin
37
+ namespace = ["Google", "Cloud", "Tasks"]
38
+ parent_config = while namespace.any?
39
+ parent_name = namespace.join "::"
40
+ parent_const = const_get parent_name
41
+ break parent_const.configure if parent_const.respond_to? :configure
42
+ namespace.pop
43
+ end
44
+
45
+ default_config = Configuration.new parent_config
46
+ default_config.bindings_override["google.cloud.location.Locations.GetLocation"] = [
47
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
48
+ uri_method: :get,
49
+ uri_template: "/v2/{name}",
50
+ matches: [
51
+ ["name", %r{^projects/[^/]+/locations/[^/]+/?$}, false]
52
+ ],
53
+ body: nil
54
+ )
55
+ ]
56
+ default_config.bindings_override["google.cloud.location.Locations.ListLocations"] = [
57
+
58
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
59
+ uri_method: :get,
60
+ uri_template: "/v2/{name}/locations",
61
+ matches: [
62
+ ["name", %r{^projects/[^/]+/?$}, false]
63
+ ],
64
+ body: nil
65
+ )
66
+ ]
67
+ default_config
68
+ end
69
+ yield @configure if block_given?
70
+ @configure
71
+ end
72
+
73
+ ##
74
+ # @private
75
+ # Configuration class for the google.cloud.tasks.v2 package.
76
+ #
77
+ # This class contains common configuration for all services
78
+ # of the google.cloud.tasks.v2 package.
79
+ #
80
+ # This configuration is for internal use of the client library classes,
81
+ # and it is not intended that the end-users will read or change it.
82
+ #
83
+ class Configuration
84
+ extend ::Gapic::Config
85
+
86
+ # @private
87
+ # Overrides for http bindings for the RPC of the mixins for this package.
88
+ # Services in this package should use these when creating clients for the mixin services.
89
+ # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
90
+ config_attr :bindings_override, {}, ::Hash, nil
91
+
92
+ # @private
93
+ def initialize parent_config = nil
94
+ @parent_config = parent_config unless parent_config.nil?
95
+
96
+ yield self if block_given?
97
+ end
98
+ end
99
+ end
100
+ end
101
+ end
102
+ end
@@ -18,6 +18,7 @@
18
18
 
19
19
  require "google/cloud/errors"
20
20
  require "google/cloud/tasks/v2/cloudtasks_pb"
21
+ require "google/cloud/location"
21
22
 
22
23
  module Google
23
24
  module Cloud
@@ -65,61 +66,61 @@ module Google
65
66
  end
66
67
  default_config = Client::Configuration.new parent_config
67
68
 
68
- default_config.rpcs.list_queues.timeout = 10.0
69
+ default_config.rpcs.list_queues.timeout = 20.0
69
70
  default_config.rpcs.list_queues.retry_policy = {
70
71
  initial_delay: 0.1, max_delay: 10.0, multiplier: 1.3, retry_codes: [4, 14]
71
72
  }
72
73
 
73
- default_config.rpcs.get_queue.timeout = 10.0
74
+ default_config.rpcs.get_queue.timeout = 20.0
74
75
  default_config.rpcs.get_queue.retry_policy = {
75
76
  initial_delay: 0.1, max_delay: 10.0, multiplier: 1.3, retry_codes: [4, 14]
76
77
  }
77
78
 
78
- default_config.rpcs.create_queue.timeout = 10.0
79
+ default_config.rpcs.create_queue.timeout = 20.0
79
80
 
80
- default_config.rpcs.update_queue.timeout = 10.0
81
+ default_config.rpcs.update_queue.timeout = 20.0
81
82
 
82
- default_config.rpcs.delete_queue.timeout = 10.0
83
+ default_config.rpcs.delete_queue.timeout = 20.0
83
84
  default_config.rpcs.delete_queue.retry_policy = {
84
85
  initial_delay: 0.1, max_delay: 10.0, multiplier: 1.3, retry_codes: [4, 14]
85
86
  }
86
87
 
87
- default_config.rpcs.purge_queue.timeout = 10.0
88
+ default_config.rpcs.purge_queue.timeout = 20.0
88
89
 
89
- default_config.rpcs.pause_queue.timeout = 10.0
90
+ default_config.rpcs.pause_queue.timeout = 20.0
90
91
 
91
- default_config.rpcs.resume_queue.timeout = 10.0
92
+ default_config.rpcs.resume_queue.timeout = 20.0
92
93
 
93
- default_config.rpcs.get_iam_policy.timeout = 10.0
94
+ default_config.rpcs.get_iam_policy.timeout = 20.0
94
95
  default_config.rpcs.get_iam_policy.retry_policy = {
95
96
  initial_delay: 0.1, max_delay: 10.0, multiplier: 1.3, retry_codes: [4, 14]
96
97
  }
97
98
 
98
- default_config.rpcs.set_iam_policy.timeout = 10.0
99
+ default_config.rpcs.set_iam_policy.timeout = 20.0
99
100
 
100
- default_config.rpcs.test_iam_permissions.timeout = 10.0
101
+ default_config.rpcs.test_iam_permissions.timeout = 20.0
101
102
  default_config.rpcs.test_iam_permissions.retry_policy = {
102
103
  initial_delay: 0.1, max_delay: 10.0, multiplier: 1.3, retry_codes: [4, 14]
103
104
  }
104
105
 
105
- default_config.rpcs.list_tasks.timeout = 10.0
106
+ default_config.rpcs.list_tasks.timeout = 20.0
106
107
  default_config.rpcs.list_tasks.retry_policy = {
107
108
  initial_delay: 0.1, max_delay: 10.0, multiplier: 1.3, retry_codes: [4, 14]
108
109
  }
109
110
 
110
- default_config.rpcs.get_task.timeout = 10.0
111
+ default_config.rpcs.get_task.timeout = 20.0
111
112
  default_config.rpcs.get_task.retry_policy = {
112
113
  initial_delay: 0.1, max_delay: 10.0, multiplier: 1.3, retry_codes: [4, 14]
113
114
  }
114
115
 
115
- default_config.rpcs.create_task.timeout = 10.0
116
+ default_config.rpcs.create_task.timeout = 20.0
116
117
 
117
- default_config.rpcs.delete_task.timeout = 10.0
118
+ default_config.rpcs.delete_task.timeout = 20.0
118
119
  default_config.rpcs.delete_task.retry_policy = {
119
120
  initial_delay: 0.1, max_delay: 10.0, multiplier: 1.3, retry_codes: [4, 14]
120
121
  }
121
122
 
122
- default_config.rpcs.run_task.timeout = 10.0
123
+ default_config.rpcs.run_task.timeout = 20.0
123
124
 
124
125
  default_config
125
126
  end
@@ -190,15 +191,29 @@ module Google
190
191
  @quota_project_id = @config.quota_project
191
192
  @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
192
193
 
194
+ @location_client = Google::Cloud::Location::Locations::Client.new do |config|
195
+ config.credentials = credentials
196
+ config.quota_project = @quota_project_id
197
+ config.endpoint = @config.endpoint
198
+ end
199
+
193
200
  @cloud_tasks_stub = ::Gapic::ServiceStub.new(
194
201
  ::Google::Cloud::Tasks::V2::CloudTasks::Stub,
195
202
  credentials: credentials,
196
203
  endpoint: @config.endpoint,
197
204
  channel_args: @config.channel_args,
198
- interceptors: @config.interceptors
205
+ interceptors: @config.interceptors,
206
+ channel_pool_config: @config.channel_pool
199
207
  )
200
208
  end
201
209
 
210
+ ##
211
+ # Get the associated client for mix-in of the Locations.
212
+ #
213
+ # @return [Google::Cloud::Location::Locations::Client]
214
+ #
215
+ attr_reader :location_client
216
+
202
217
  # Service calls
203
218
 
204
219
  ##
@@ -225,11 +240,10 @@ module Google
225
240
  # Required. The location name.
226
241
  # For example: `projects/PROJECT_ID/locations/LOCATION_ID`
227
242
  # @param filter [::String]
228
- # `filter` can be used to specify a subset of queues. Any {::Google::Cloud::Tasks::V2::Queue Queue}
229
- # field can be used as a filter and several operators as supported.
230
- # For example: `<=, <, >=, >, !=, =, :`. The filter syntax is the same as
231
- # described in
232
- # [Stackdriver's Advanced Logs
243
+ # `filter` can be used to specify a subset of queues. Any
244
+ # {::Google::Cloud::Tasks::V2::Queue Queue} field can be used as a filter and
245
+ # several operators as supported. For example: `<=, <, >=, >, !=, =, :`. The
246
+ # filter syntax is the same as described in [Stackdriver's Advanced Logs
233
247
  # Filters](https://cloud.google.com/logging/docs/view/advanced_filters).
234
248
  #
235
249
  # Sample filter "state: PAUSED".
@@ -242,17 +256,19 @@ module Google
242
256
  # The maximum page size is 9800. If unspecified, the page size will
243
257
  # be the maximum. Fewer queues than requested might be returned,
244
258
  # even if more queues exist; use the
245
- # {::Google::Cloud::Tasks::V2::ListQueuesResponse#next_page_token next_page_token} in the
246
- # response to determine if more queues exist.
259
+ # {::Google::Cloud::Tasks::V2::ListQueuesResponse#next_page_token next_page_token}
260
+ # in the response to determine if more queues exist.
247
261
  # @param page_token [::String]
248
262
  # A token identifying the page of results to return.
249
263
  #
250
264
  # To request the first page results, page_token must be empty. To
251
265
  # request the next page of results, page_token must be the value of
252
- # {::Google::Cloud::Tasks::V2::ListQueuesResponse#next_page_token next_page_token} returned
253
- # from the previous call to {::Google::Cloud::Tasks::V2::CloudTasks::Client#list_queues ListQueues}
254
- # method. It is an error to switch the value of the
255
- # {::Google::Cloud::Tasks::V2::ListQueuesRequest#filter filter} while iterating through pages.
266
+ # {::Google::Cloud::Tasks::V2::ListQueuesResponse#next_page_token next_page_token}
267
+ # returned from the previous call to
268
+ # {::Google::Cloud::Tasks::V2::CloudTasks::Client#list_queues ListQueues} method. It is an
269
+ # error to switch the value of the
270
+ # {::Google::Cloud::Tasks::V2::ListQueuesRequest#filter filter} while iterating
271
+ # through pages.
256
272
  #
257
273
  # @yield [response, operation] Access the result along with the RPC operation
258
274
  # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::Tasks::V2::Queue>]
@@ -413,8 +429,8 @@ module Google
413
429
  # Creates a queue.
414
430
  #
415
431
  # Queues created with this method allow tasks to live for a maximum of 31
416
- # days. After a task is 31 days old, the task will be deleted regardless of whether
417
- # it was dispatched or not.
432
+ # days. After a task is 31 days old, the task will be deleted regardless of
433
+ # whether it was dispatched or not.
418
434
  #
419
435
  # WARNING: Using this method may have unintended side effects if you are
420
436
  # using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
@@ -444,11 +460,12 @@ module Google
444
460
  #
445
461
  # The list of allowed locations can be obtained by calling Cloud
446
462
  # Tasks' implementation of
447
- # [ListLocations][google.cloud.location.Locations.ListLocations].
463
+ # `::Google::Cloud::Location::Locations::Client#list_locations`.
448
464
  # @param queue [::Google::Cloud::Tasks::V2::Queue, ::Hash]
449
465
  # Required. The queue to create.
450
466
  #
451
- # [Queue's name][google.cloud.tasks.v2.Queue.name] cannot be the same as an existing queue.
467
+ # [Queue's name][google.cloud.tasks.v2.Queue.name] cannot be the same as an
468
+ # existing queue.
452
469
  #
453
470
  # @yield [response, operation] Access the result along with the RPC operation
454
471
  # @yieldparam response [::Google::Cloud::Tasks::V2::Queue]
@@ -521,8 +538,8 @@ module Google
521
538
  # the queue if it does exist.
522
539
  #
523
540
  # Queues created with this method allow tasks to live for a maximum of 31
524
- # days. After a task is 31 days old, the task will be deleted regardless of whether
525
- # it was dispatched or not.
541
+ # days. After a task is 31 days old, the task will be deleted regardless of
542
+ # whether it was dispatched or not.
526
543
  #
527
544
  # WARNING: Using this method may have unintended side effects if you are
528
545
  # using an App Engine `queue.yaml` or `queue.xml` file to manage your queues.
@@ -817,9 +834,10 @@ module Google
817
834
  #
818
835
  # If a queue is paused then the system will stop dispatching tasks
819
836
  # until the queue is resumed via
820
- # {::Google::Cloud::Tasks::V2::CloudTasks::Client#resume_queue ResumeQueue}. Tasks can still be added
821
- # when the queue is paused. A queue is paused if its
822
- # {::Google::Cloud::Tasks::V2::Queue#state state} is {::Google::Cloud::Tasks::V2::Queue::State::PAUSED PAUSED}.
837
+ # {::Google::Cloud::Tasks::V2::CloudTasks::Client#resume_queue ResumeQueue}. Tasks can
838
+ # still be added when the queue is paused. A queue is paused if its
839
+ # {::Google::Cloud::Tasks::V2::Queue#state state} is
840
+ # {::Google::Cloud::Tasks::V2::Queue::State::PAUSED PAUSED}.
823
841
  #
824
842
  # @overload pause_queue(request, options = nil)
825
843
  # Pass arguments to `pause_queue` via a request object, either of type
@@ -909,9 +927,10 @@ module Google
909
927
  #
910
928
  # This method resumes a queue after it has been
911
929
  # {::Google::Cloud::Tasks::V2::Queue::State::PAUSED PAUSED} or
912
- # {::Google::Cloud::Tasks::V2::Queue::State::DISABLED DISABLED}. The state of a queue is stored
913
- # in the queue's {::Google::Cloud::Tasks::V2::Queue#state state}; after calling this method it
914
- # will be set to {::Google::Cloud::Tasks::V2::Queue::State::RUNNING RUNNING}.
930
+ # {::Google::Cloud::Tasks::V2::Queue::State::DISABLED DISABLED}. The state of a
931
+ # queue is stored in the queue's {::Google::Cloud::Tasks::V2::Queue#state state};
932
+ # after calling this method it will be set to
933
+ # {::Google::Cloud::Tasks::V2::Queue::State::RUNNING RUNNING}.
915
934
  #
916
935
  # WARNING: Resuming many high-QPS queues at the same time can
917
936
  # lead to target overloading. If you are resuming high-QPS
@@ -1100,8 +1119,8 @@ module Google
1100
1119
  end
1101
1120
 
1102
1121
  ##
1103
- # Sets the access control policy for a {::Google::Cloud::Tasks::V2::Queue Queue}. Replaces any existing
1104
- # policy.
1122
+ # Sets the access control policy for a {::Google::Cloud::Tasks::V2::Queue Queue}.
1123
+ # Replaces any existing policy.
1105
1124
  #
1106
1125
  # Note: The Cloud Console does not check queue-level IAM permissions yet.
1107
1126
  # Project-level permissions are required to use the Cloud Console.
@@ -1207,9 +1226,10 @@ module Google
1207
1226
  end
1208
1227
 
1209
1228
  ##
1210
- # Returns permissions that a caller has on a {::Google::Cloud::Tasks::V2::Queue Queue}.
1211
- # If the resource does not exist, this will return an empty set of
1212
- # permissions, not a [NOT_FOUND][google.rpc.Code.NOT_FOUND] error.
1229
+ # Returns permissions that a caller has on a
1230
+ # {::Google::Cloud::Tasks::V2::Queue Queue}. If the resource does not exist, this
1231
+ # will return an empty set of permissions, not a
1232
+ # [NOT_FOUND][google.rpc.Code.NOT_FOUND] error.
1213
1233
  #
1214
1234
  # Note: This operation is designed to be used for building permission-aware
1215
1235
  # UIs and command-line tools, not for authorization checking. This operation
@@ -1306,10 +1326,10 @@ module Google
1306
1326
  ##
1307
1327
  # Lists the tasks in a queue.
1308
1328
  #
1309
- # By default, only the {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC} view is retrieved
1310
- # due to performance considerations;
1311
- # {::Google::Cloud::Tasks::V2::ListTasksRequest#response_view response_view} controls the
1312
- # subset of information which is returned.
1329
+ # By default, only the {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC} view is
1330
+ # retrieved due to performance considerations;
1331
+ # {::Google::Cloud::Tasks::V2::ListTasksRequest#response_view response_view}
1332
+ # controls the subset of information which is returned.
1313
1333
  #
1314
1334
  # The tasks may be returned in any order. The ordering may change at any
1315
1335
  # time.
@@ -1333,11 +1353,11 @@ module Google
1333
1353
  # Required. The queue name. For example:
1334
1354
  # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID`
1335
1355
  # @param response_view [::Google::Cloud::Tasks::V2::Task::View]
1336
- # The response_view specifies which subset of the {::Google::Cloud::Tasks::V2::Task Task} will be
1337
- # returned.
1356
+ # The response_view specifies which subset of the
1357
+ # {::Google::Cloud::Tasks::V2::Task Task} will be returned.
1338
1358
  #
1339
- # By default response_view is {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC}; not all
1340
- # information is retrieved by default because some data, such as
1359
+ # By default response_view is {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC};
1360
+ # not all information is retrieved by default because some data, such as
1341
1361
  # payloads, might be desirable to return only when needed because
1342
1362
  # of its large size or because of the sensitivity of data that it
1343
1363
  # contains.
@@ -1349,8 +1369,8 @@ module Google
1349
1369
  # Maximum page size.
1350
1370
  #
1351
1371
  # Fewer tasks than requested might be returned, even if more tasks exist; use
1352
- # {::Google::Cloud::Tasks::V2::ListTasksResponse#next_page_token next_page_token} in the response to
1353
- # determine if more tasks exist.
1372
+ # {::Google::Cloud::Tasks::V2::ListTasksResponse#next_page_token next_page_token}
1373
+ # in the response to determine if more tasks exist.
1354
1374
  #
1355
1375
  # The maximum page size is 1000. If unspecified, the page size will be the
1356
1376
  # maximum.
@@ -1359,9 +1379,9 @@ module Google
1359
1379
  #
1360
1380
  # To request the first page results, page_token must be empty. To
1361
1381
  # request the next page of results, page_token must be the value of
1362
- # {::Google::Cloud::Tasks::V2::ListTasksResponse#next_page_token next_page_token} returned
1363
- # from the previous call to {::Google::Cloud::Tasks::V2::CloudTasks::Client#list_tasks ListTasks}
1364
- # method.
1382
+ # {::Google::Cloud::Tasks::V2::ListTasksResponse#next_page_token next_page_token}
1383
+ # returned from the previous call to
1384
+ # {::Google::Cloud::Tasks::V2::CloudTasks::Client#list_tasks ListTasks} method.
1365
1385
  #
1366
1386
  # The page token is valid for only 2 hours.
1367
1387
  #
@@ -1456,11 +1476,11 @@ module Google
1456
1476
  # Required. The task name. For example:
1457
1477
  # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`
1458
1478
  # @param response_view [::Google::Cloud::Tasks::V2::Task::View]
1459
- # The response_view specifies which subset of the {::Google::Cloud::Tasks::V2::Task Task} will be
1460
- # returned.
1479
+ # The response_view specifies which subset of the
1480
+ # {::Google::Cloud::Tasks::V2::Task Task} will be returned.
1461
1481
  #
1462
- # By default response_view is {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC}; not all
1463
- # information is retrieved by default because some data, such as
1482
+ # By default response_view is {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC};
1483
+ # not all information is retrieved by default because some data, such as
1464
1484
  # payloads, might be desirable to return only when needed because
1465
1485
  # of its large size or because of the sensitivity of data that it
1466
1486
  # contains.
@@ -1565,13 +1585,13 @@ module Google
1565
1585
  #
1566
1586
  # Task names have the following format:
1567
1587
  # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`.
1568
- # The user can optionally specify a task {::Google::Cloud::Tasks::V2::Task#name name}. If a
1569
- # name is not specified then the system will generate a random
1570
- # unique task id, which will be set in the task returned in the
1571
- # {::Google::Cloud::Tasks::V2::Task#name response}.
1588
+ # The user can optionally specify a task
1589
+ # {::Google::Cloud::Tasks::V2::Task#name name}. If a name is not specified then
1590
+ # the system will generate a random unique task id, which will be set in the
1591
+ # task returned in the {::Google::Cloud::Tasks::V2::Task#name response}.
1572
1592
  #
1573
- # If {::Google::Cloud::Tasks::V2::Task#schedule_time schedule_time} is not set or is in the
1574
- # past then Cloud Tasks will set it to the current time.
1593
+ # If {::Google::Cloud::Tasks::V2::Task#schedule_time schedule_time} is not set or
1594
+ # is in the past then Cloud Tasks will set it to the current time.
1575
1595
  #
1576
1596
  # Task De-duplication:
1577
1597
  #
@@ -1586,20 +1606,20 @@ module Google
1586
1606
  # for ~9days after the original task was deleted or executed.
1587
1607
  #
1588
1608
  # Because there is an extra lookup cost to identify duplicate task
1589
- # names, these {::Google::Cloud::Tasks::V2::CloudTasks::Client#create_task CreateTask} calls have significantly
1590
- # increased latency. Using hashed strings for the task id or for
1591
- # the prefix of the task id is recommended. Choosing task ids that
1592
- # are sequential or have sequential prefixes, for example using a
1609
+ # names, these {::Google::Cloud::Tasks::V2::CloudTasks::Client#create_task CreateTask}
1610
+ # calls have significantly increased latency. Using hashed strings for the
1611
+ # task id or for the prefix of the task id is recommended. Choosing task ids
1612
+ # that are sequential or have sequential prefixes, for example using a
1593
1613
  # timestamp, causes an increase in latency and error rates in all
1594
1614
  # task commands. The infrastructure relies on an approximately
1595
1615
  # uniform distribution of task ids to store and serve tasks
1596
1616
  # efficiently.
1597
1617
  # @param response_view [::Google::Cloud::Tasks::V2::Task::View]
1598
- # The response_view specifies which subset of the {::Google::Cloud::Tasks::V2::Task Task} will be
1599
- # returned.
1618
+ # The response_view specifies which subset of the
1619
+ # {::Google::Cloud::Tasks::V2::Task Task} will be returned.
1600
1620
  #
1601
- # By default response_view is {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC}; not all
1602
- # information is retrieved by default because some data, such as
1621
+ # By default response_view is {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC};
1622
+ # not all information is retrieved by default because some data, such as
1603
1623
  # payloads, might be desirable to return only when needed because
1604
1624
  # of its large size or because of the sensitivity of data that it
1605
1625
  # contains.
@@ -1766,13 +1786,14 @@ module Google
1766
1786
  # Forces a task to run now.
1767
1787
  #
1768
1788
  # When this method is called, Cloud Tasks will dispatch the task, even if
1769
- # the task is already running, the queue has reached its {::Google::Cloud::Tasks::V2::RateLimits RateLimits} or
1770
- # is {::Google::Cloud::Tasks::V2::Queue::State::PAUSED PAUSED}.
1789
+ # the task is already running, the queue has reached its
1790
+ # {::Google::Cloud::Tasks::V2::RateLimits RateLimits} or is
1791
+ # {::Google::Cloud::Tasks::V2::Queue::State::PAUSED PAUSED}.
1771
1792
  #
1772
1793
  # This command is meant to be used for manual debugging. For
1773
- # example, {::Google::Cloud::Tasks::V2::CloudTasks::Client#run_task RunTask} can be used to retry a failed
1774
- # task after a fix has been made or to manually force a task to be
1775
- # dispatched now.
1794
+ # example, {::Google::Cloud::Tasks::V2::CloudTasks::Client#run_task RunTask} can be used to
1795
+ # retry a failed task after a fix has been made or to manually force a task
1796
+ # to be dispatched now.
1776
1797
  #
1777
1798
  # The dispatched task is returned. That is, the task that is returned
1778
1799
  # contains the [status][Task.status] after the task is dispatched but
@@ -1780,9 +1801,10 @@ module Google
1780
1801
  #
1781
1802
  # If Cloud Tasks receives a successful response from the task's
1782
1803
  # target, then the task will be deleted; otherwise the task's
1783
- # {::Google::Cloud::Tasks::V2::Task#schedule_time schedule_time} will be reset to the time that
1784
- # {::Google::Cloud::Tasks::V2::CloudTasks::Client#run_task RunTask} was called plus the retry delay specified
1785
- # in the queue's {::Google::Cloud::Tasks::V2::RetryConfig RetryConfig}.
1804
+ # {::Google::Cloud::Tasks::V2::Task#schedule_time schedule_time} will be reset to
1805
+ # the time that {::Google::Cloud::Tasks::V2::CloudTasks::Client#run_task RunTask} was
1806
+ # called plus the retry delay specified in the queue's
1807
+ # {::Google::Cloud::Tasks::V2::RetryConfig RetryConfig}.
1786
1808
  #
1787
1809
  # {::Google::Cloud::Tasks::V2::CloudTasks::Client#run_task RunTask} returns
1788
1810
  # [NOT_FOUND][google.rpc.Code.NOT_FOUND] when it is called on a
@@ -1807,11 +1829,11 @@ module Google
1807
1829
  # Required. The task name. For example:
1808
1830
  # `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`
1809
1831
  # @param response_view [::Google::Cloud::Tasks::V2::Task::View]
1810
- # The response_view specifies which subset of the {::Google::Cloud::Tasks::V2::Task Task} will be
1811
- # returned.
1832
+ # The response_view specifies which subset of the
1833
+ # {::Google::Cloud::Tasks::V2::Task Task} will be returned.
1812
1834
  #
1813
- # By default response_view is {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC}; not all
1814
- # information is retrieved by default because some data, such as
1835
+ # By default response_view is {::Google::Cloud::Tasks::V2::Task::View::BASIC BASIC};
1836
+ # not all information is retrieved by default because some data, such as
1815
1837
  # payloads, might be desirable to return only when needed because
1816
1838
  # of its large size or because of the sensitivity of data that it
1817
1839
  # contains.
@@ -2003,6 +2025,14 @@ module Google
2003
2025
  end
2004
2026
  end
2005
2027
 
2028
+ ##
2029
+ # Configuration for the channel pool
2030
+ # @return [::Gapic::ServiceStub::ChannelPool::Configuration]
2031
+ #
2032
+ def channel_pool
2033
+ @channel_pool ||= ::Gapic::ServiceStub::ChannelPool::Configuration.new
2034
+ end
2035
+
2006
2036
  ##
2007
2037
  # Configuration RPC class for the CloudTasks API.
2008
2038
  #