google-cloud-dataflow-v1beta3 0.1.0 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -39,13 +39,12 @@ module Google
39
39
  # See {::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client::Configuration}
40
40
  # for a description of the configuration fields.
41
41
  #
42
- # ## Example
42
+ # @example
43
43
  #
44
- # To modify the configuration for all TemplatesService clients:
45
- #
46
- # ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.configure do |config|
47
- # config.timeout = 10.0
48
- # end
44
+ # # Modify the configuration for all TemplatesService clients
45
+ # ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.configure do |config|
46
+ # config.timeout = 10.0
47
+ # end
49
48
  #
50
49
  # @yield [config] Configure the Client client.
51
50
  # @yieldparam config [Client::Configuration]
@@ -94,19 +93,15 @@ module Google
94
93
  ##
95
94
  # Create a new TemplatesService client object.
96
95
  #
97
- # ## Examples
98
- #
99
- # To create a new TemplatesService client with the default
100
- # configuration:
96
+ # @example
101
97
  #
102
- # client = ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new
98
+ # # Create a client using the default configuration
99
+ # client = ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new
103
100
  #
104
- # To create a new TemplatesService client with a custom
105
- # configuration:
106
- #
107
- # client = ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new do |config|
108
- # config.timeout = 10.0
109
- # end
101
+ # # Create a client using a custom configuration
102
+ # client = ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new do |config|
103
+ # config.timeout = 10.0
104
+ # end
110
105
  #
111
106
  # @yield [config] Configure the TemplatesService client.
112
107
  # @yieldparam config [Client::Configuration]
@@ -126,14 +121,13 @@ module Google
126
121
 
127
122
  # Create credentials
128
123
  credentials = @config.credentials
129
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
124
+ # Use self-signed JWT if the endpoint is unchanged from default,
130
125
  # but only if the default endpoint does not have a region prefix.
131
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
132
- @config.endpoint == Client.configure.endpoint &&
126
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
133
127
  !@config.endpoint.split(".").first.include?("-")
134
128
  credentials ||= Credentials.default scope: @config.scope,
135
129
  enable_self_signed_jwt: enable_self_signed_jwt
136
- if credentials.is_a?(String) || credentials.is_a?(Hash)
130
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
137
131
  credentials = Credentials.new credentials, scope: @config.scope
138
132
  end
139
133
  @quota_project_id = @config.quota_project
@@ -193,6 +187,21 @@ module Google
193
187
  #
194
188
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
195
189
  #
190
+ # @example Basic example
191
+ # require "google/cloud/dataflow/v1beta3"
192
+ #
193
+ # # Create a client object. The client can be reused for multiple calls.
194
+ # client = Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new
195
+ #
196
+ # # Create a request. To set request fields, pass in keyword arguments.
197
+ # request = Google::Cloud::Dataflow::V1beta3::CreateJobFromTemplateRequest.new
198
+ #
199
+ # # Call the create_job_from_template method.
200
+ # result = client.create_job_from_template request
201
+ #
202
+ # # The returned object is of type Google::Cloud::Dataflow::V1beta3::Job.
203
+ # p result
204
+ #
196
205
  def create_job_from_template request, options = nil
197
206
  raise ::ArgumentError, "request must be provided" if request.nil?
198
207
 
@@ -213,7 +222,9 @@ module Google
213
222
  options.apply_defaults timeout: @config.rpcs.create_job_from_template.timeout,
214
223
  metadata: metadata,
215
224
  retry_policy: @config.rpcs.create_job_from_template.retry_policy
216
- options.apply_defaults metadata: @config.metadata,
225
+
226
+ options.apply_defaults timeout: @config.timeout,
227
+ metadata: @config.metadata,
217
228
  retry_policy: @config.retry_policy
218
229
 
219
230
  @templates_service_stub.call_rpc :create_job_from_template, request, options: options do |response, operation|
@@ -269,6 +280,21 @@ module Google
269
280
  #
270
281
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
271
282
  #
283
+ # @example Basic example
284
+ # require "google/cloud/dataflow/v1beta3"
285
+ #
286
+ # # Create a client object. The client can be reused for multiple calls.
287
+ # client = Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new
288
+ #
289
+ # # Create a request. To set request fields, pass in keyword arguments.
290
+ # request = Google::Cloud::Dataflow::V1beta3::LaunchTemplateRequest.new
291
+ #
292
+ # # Call the launch_template method.
293
+ # result = client.launch_template request
294
+ #
295
+ # # The returned object is of type Google::Cloud::Dataflow::V1beta3::LaunchTemplateResponse.
296
+ # p result
297
+ #
272
298
  def launch_template request, options = nil
273
299
  raise ::ArgumentError, "request must be provided" if request.nil?
274
300
 
@@ -289,7 +315,9 @@ module Google
289
315
  options.apply_defaults timeout: @config.rpcs.launch_template.timeout,
290
316
  metadata: metadata,
291
317
  retry_policy: @config.rpcs.launch_template.retry_policy
292
- options.apply_defaults metadata: @config.metadata,
318
+
319
+ options.apply_defaults timeout: @config.timeout,
320
+ metadata: @config.metadata,
293
321
  retry_policy: @config.retry_policy
294
322
 
295
323
  @templates_service_stub.call_rpc :launch_template, request, options: options do |response, operation|
@@ -339,6 +367,21 @@ module Google
339
367
  #
340
368
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
341
369
  #
370
+ # @example Basic example
371
+ # require "google/cloud/dataflow/v1beta3"
372
+ #
373
+ # # Create a client object. The client can be reused for multiple calls.
374
+ # client = Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new
375
+ #
376
+ # # Create a request. To set request fields, pass in keyword arguments.
377
+ # request = Google::Cloud::Dataflow::V1beta3::GetTemplateRequest.new
378
+ #
379
+ # # Call the get_template method.
380
+ # result = client.get_template request
381
+ #
382
+ # # The returned object is of type Google::Cloud::Dataflow::V1beta3::GetTemplateResponse.
383
+ # p result
384
+ #
342
385
  def get_template request, options = nil
343
386
  raise ::ArgumentError, "request must be provided" if request.nil?
344
387
 
@@ -359,7 +402,9 @@ module Google
359
402
  options.apply_defaults timeout: @config.rpcs.get_template.timeout,
360
403
  metadata: metadata,
361
404
  retry_policy: @config.rpcs.get_template.retry_policy
362
- options.apply_defaults metadata: @config.metadata,
405
+
406
+ options.apply_defaults timeout: @config.timeout,
407
+ metadata: @config.metadata,
363
408
  retry_policy: @config.retry_policy
364
409
 
365
410
  @templates_service_stub.call_rpc :get_template, request, options: options do |response, operation|
@@ -383,22 +428,21 @@ module Google
383
428
  # Configuration can be applied globally to all clients, or to a single client
384
429
  # on construction.
385
430
  #
386
- # # Examples
387
- #
388
- # To modify the global config, setting the timeout for create_job_from_template
389
- # to 20 seconds, and all remaining timeouts to 10 seconds:
390
- #
391
- # ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.configure do |config|
392
- # config.timeout = 10.0
393
- # config.rpcs.create_job_from_template.timeout = 20.0
394
- # end
395
- #
396
- # To apply the above configuration only to a new client:
397
- #
398
- # client = ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new do |config|
399
- # config.timeout = 10.0
400
- # config.rpcs.create_job_from_template.timeout = 20.0
401
- # end
431
+ # @example
432
+ #
433
+ # # Modify the global config, setting the timeout for
434
+ # # create_job_from_template to 20 seconds,
435
+ # # and all remaining timeouts to 10 seconds.
436
+ # ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.configure do |config|
437
+ # config.timeout = 10.0
438
+ # config.rpcs.create_job_from_template.timeout = 20.0
439
+ # end
440
+ #
441
+ # # Apply the above configuration only to a new client.
442
+ # client = ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Client.new do |config|
443
+ # config.timeout = 10.0
444
+ # config.rpcs.create_job_from_template.timeout = 20.0
445
+ # end
402
446
  #
403
447
  # @!attribute [rw] endpoint
404
448
  # The hostname or hostname:port of the service endpoint.
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Dataflow
23
23
  module V1beta3
24
- VERSION = "0.1.0"
24
+ VERSION = "0.1.4"
25
25
  end
26
26
  end
27
27
  end
@@ -1,11 +1,11 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/dataflow/v1beta3/environment.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/field_behavior_pb'
7
5
  require 'google/protobuf/any_pb'
8
6
  require 'google/protobuf/struct_pb'
7
+ require 'google/protobuf'
8
+
9
9
  Google::Protobuf::DescriptorPool.generated_pool.build do
10
10
  add_file("google/dataflow/v1beta3/environment.proto", :syntax => :proto3) do
11
11
  add_message "google.dataflow.v1beta3.Environment" do
@@ -1,8 +1,6 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/dataflow/v1beta3/jobs.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/dataflow/v1beta3/environment_pb'
8
6
  require 'google/dataflow/v1beta3/snapshots_pb'
@@ -10,6 +8,8 @@ require 'google/protobuf/duration_pb'
10
8
  require 'google/protobuf/struct_pb'
11
9
  require 'google/protobuf/timestamp_pb'
12
10
  require 'google/api/client_pb'
11
+ require 'google/protobuf'
12
+
13
13
  Google::Protobuf::DescriptorPool.generated_pool.build do
14
14
  add_file("google/dataflow/v1beta3/jobs.proto", :syntax => :proto3) do
15
15
  add_message "google.dataflow.v1beta3.Job" do
@@ -28,7 +28,7 @@ module Google
28
28
  # A Job is a multi-stage computation graph run by the Cloud Dataflow service.
29
29
  class Service
30
30
 
31
- include GRPC::GenericService
31
+ include ::GRPC::GenericService
32
32
 
33
33
  self.marshal_class_method = :encode
34
34
  self.unmarshal_class_method = :decode
@@ -1,12 +1,12 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/dataflow/v1beta3/messages.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/protobuf/struct_pb'
8
6
  require 'google/protobuf/timestamp_pb'
9
7
  require 'google/api/client_pb'
8
+ require 'google/protobuf'
9
+
10
10
  Google::Protobuf::DescriptorPool.generated_pool.build do
11
11
  add_file("google/dataflow/v1beta3/messages.proto", :syntax => :proto3) do
12
12
  add_message "google.dataflow.v1beta3.JobMessage" do
@@ -28,7 +28,7 @@ module Google
28
28
  # Dataflow jobs.
29
29
  class Service
30
30
 
31
- include GRPC::GenericService
31
+ include ::GRPC::GenericService
32
32
 
33
33
  self.marshal_class_method = :encode
34
34
  self.unmarshal_class_method = :decode
@@ -1,12 +1,12 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/dataflow/v1beta3/metrics.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/protobuf/struct_pb'
8
6
  require 'google/protobuf/timestamp_pb'
9
7
  require 'google/api/client_pb'
8
+ require 'google/protobuf'
9
+
10
10
  Google::Protobuf::DescriptorPool.generated_pool.build do
11
11
  add_file("google/dataflow/v1beta3/metrics.proto", :syntax => :proto3) do
12
12
  add_message "google.dataflow.v1beta3.MetricStructuredName" do
@@ -28,7 +28,7 @@ module Google
28
28
  # jobs.
29
29
  class Service
30
30
 
31
- include GRPC::GenericService
31
+ include ::GRPC::GenericService
32
32
 
33
33
  self.marshal_class_method = :encode
34
34
  self.unmarshal_class_method = :decode
@@ -1,12 +1,12 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/dataflow/v1beta3/snapshots.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/protobuf/duration_pb'
8
6
  require 'google/protobuf/timestamp_pb'
9
7
  require 'google/api/client_pb'
8
+ require 'google/protobuf'
9
+
10
10
  Google::Protobuf::DescriptorPool.generated_pool.build do
11
11
  add_file("google/dataflow/v1beta3/snapshots.proto", :syntax => :proto3) do
12
12
  add_message "google.dataflow.v1beta3.PubsubSnapshotMetadata" do
@@ -27,7 +27,7 @@ module Google
27
27
  # Provides methods to manage snapshots of Google Cloud Dataflow jobs.
28
28
  class Service
29
29
 
30
- include GRPC::GenericService
30
+ include ::GRPC::GenericService
31
31
 
32
32
  self.marshal_class_method = :encode
33
33
  self.unmarshal_class_method = :decode
@@ -1,13 +1,13 @@
1
1
  # Generated by the protocol buffer compiler. DO NOT EDIT!
2
2
  # source: google/dataflow/v1beta3/templates.proto
3
3
 
4
- require 'google/protobuf'
5
-
6
4
  require 'google/api/annotations_pb'
7
5
  require 'google/dataflow/v1beta3/environment_pb'
8
6
  require 'google/dataflow/v1beta3/jobs_pb'
9
7
  require 'google/rpc/status_pb'
10
8
  require 'google/api/client_pb'
9
+ require 'google/protobuf'
10
+
11
11
  Google::Protobuf::DescriptorPool.generated_pool.build do
12
12
  add_file("google/dataflow/v1beta3/templates.proto", :syntax => :proto3) do
13
13
  add_message "google.dataflow.v1beta3.LaunchFlexTemplateResponse" do
@@ -27,7 +27,7 @@ module Google
27
27
  # Provides a method to create Cloud Dataflow jobs from templates.
28
28
  class Service
29
29
 
30
- include GRPC::GenericService
30
+ include ::GRPC::GenericService
31
31
 
32
32
  self.marshal_class_method = :encode
33
33
  self.unmarshal_class_method = :decode
@@ -47,7 +47,7 @@ module Google
47
47
  # Provides a service for Flex templates. This feature is not ready yet.
48
48
  class Service
49
49
 
50
- include GRPC::GenericService
50
+ include ::GRPC::GenericService
51
51
 
52
52
  self.marshal_class_method = :encode
53
53
  self.unmarshal_class_method = :decode
@@ -60,6 +60,12 @@ module Google
60
60
  # in any arbitrary order, rather than the order the user originally
61
61
  # provided. Additionally, the list's order may or may not be stable.
62
62
  UNORDERED_LIST = 6
63
+
64
+ # Denotes that this field returns a non-empty default value if not set.
65
+ # This indicates that if the user provides the empty value in a request,
66
+ # a non-empty value will be returned. The user will not be aware of what
67
+ # non-empty value to expect.
68
+ NON_EMPTY_DEFAULT = 7
63
69
  end
64
70
  end
65
71
  end
@@ -33,11 +33,7 @@ module Google
33
33
  # // For Kubernetes resources, the format is {api group}/{kind}.
34
34
  # option (google.api.resource) = {
35
35
  # type: "pubsub.googleapis.com/Topic"
36
- # name_descriptor: {
37
- # pattern: "projects/{project}/topics/{topic}"
38
- # parent_type: "cloudresourcemanager.googleapis.com/Project"
39
- # parent_name_extractor: "projects/{project}"
40
- # }
36
+ # pattern: "projects/{project}/topics/{topic}"
41
37
  # };
42
38
  # }
43
39
  #
@@ -45,10 +41,7 @@ module Google
45
41
  #
46
42
  # resources:
47
43
  # - type: "pubsub.googleapis.com/Topic"
48
- # name_descriptor:
49
- # - pattern: "projects/{project}/topics/{topic}"
50
- # parent_type: "cloudresourcemanager.googleapis.com/Project"
51
- # parent_name_extractor: "projects/{project}"
44
+ # pattern: "projects/{project}/topics/{topic}"
52
45
  #
53
46
  # Sometimes, resources have multiple patterns, typically because they can
54
47
  # live under multiple parents.
@@ -58,26 +51,10 @@ module Google
58
51
  # message LogEntry {
59
52
  # option (google.api.resource) = {
60
53
  # type: "logging.googleapis.com/LogEntry"
61
- # name_descriptor: {
62
- # pattern: "projects/{project}/logs/{log}"
63
- # parent_type: "cloudresourcemanager.googleapis.com/Project"
64
- # parent_name_extractor: "projects/{project}"
65
- # }
66
- # name_descriptor: {
67
- # pattern: "folders/{folder}/logs/{log}"
68
- # parent_type: "cloudresourcemanager.googleapis.com/Folder"
69
- # parent_name_extractor: "folders/{folder}"
70
- # }
71
- # name_descriptor: {
72
- # pattern: "organizations/{organization}/logs/{log}"
73
- # parent_type: "cloudresourcemanager.googleapis.com/Organization"
74
- # parent_name_extractor: "organizations/{organization}"
75
- # }
76
- # name_descriptor: {
77
- # pattern: "billingAccounts/{billing_account}/logs/{log}"
78
- # parent_type: "billing.googleapis.com/BillingAccount"
79
- # parent_name_extractor: "billingAccounts/{billing_account}"
80
- # }
54
+ # pattern: "projects/{project}/logs/{log}"
55
+ # pattern: "folders/{folder}/logs/{log}"
56
+ # pattern: "organizations/{organization}/logs/{log}"
57
+ # pattern: "billingAccounts/{billing_account}/logs/{log}"
81
58
  # };
82
59
  # }
83
60
  #
@@ -85,48 +62,10 @@ module Google
85
62
  #
86
63
  # resources:
87
64
  # - type: 'logging.googleapis.com/LogEntry'
88
- # name_descriptor:
89
- # - pattern: "projects/{project}/logs/{log}"
90
- # parent_type: "cloudresourcemanager.googleapis.com/Project"
91
- # parent_name_extractor: "projects/{project}"
92
- # - pattern: "folders/{folder}/logs/{log}"
93
- # parent_type: "cloudresourcemanager.googleapis.com/Folder"
94
- # parent_name_extractor: "folders/{folder}"
95
- # - pattern: "organizations/{organization}/logs/{log}"
96
- # parent_type: "cloudresourcemanager.googleapis.com/Organization"
97
- # parent_name_extractor: "organizations/{organization}"
98
- # - pattern: "billingAccounts/{billing_account}/logs/{log}"
99
- # parent_type: "billing.googleapis.com/BillingAccount"
100
- # parent_name_extractor: "billingAccounts/{billing_account}"
101
- #
102
- # For flexible resources, the resource name doesn't contain parent names, but
103
- # the resource itself has parents for policy evaluation.
104
- #
105
- # Example:
106
- #
107
- # message Shelf {
108
- # option (google.api.resource) = {
109
- # type: "library.googleapis.com/Shelf"
110
- # name_descriptor: {
111
- # pattern: "shelves/{shelf}"
112
- # parent_type: "cloudresourcemanager.googleapis.com/Project"
113
- # }
114
- # name_descriptor: {
115
- # pattern: "shelves/{shelf}"
116
- # parent_type: "cloudresourcemanager.googleapis.com/Folder"
117
- # }
118
- # };
119
- # }
120
- #
121
- # The ResourceDescriptor Yaml config will look like:
122
- #
123
- # resources:
124
- # - type: 'library.googleapis.com/Shelf'
125
- # name_descriptor:
126
- # - pattern: "shelves/{shelf}"
127
- # parent_type: "cloudresourcemanager.googleapis.com/Project"
128
- # - pattern: "shelves/{shelf}"
129
- # parent_type: "cloudresourcemanager.googleapis.com/Folder"
65
+ # pattern: "projects/{project}/logs/{log}"
66
+ # pattern: "folders/{folder}/logs/{log}"
67
+ # pattern: "organizations/{organization}/logs/{log}"
68
+ # pattern: "billingAccounts/{billing_account}/logs/{log}"
130
69
  # @!attribute [rw] type
131
70
  # @return [::String]
132
71
  # The resource type. It must be in the format of
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-dataflow-v1beta3
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-29 00:00:00.000000000 Z
11
+ date: 2022-01-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gapic-common
@@ -16,7 +16,7 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '0.5'
19
+ version: '0.7'
20
20
  - - "<"
21
21
  - !ruby/object:Gem::Version
22
22
  version: 2.a
@@ -26,7 +26,7 @@ dependencies:
26
26
  requirements:
27
27
  - - ">="
28
28
  - !ruby/object:Gem::Version
29
- version: '0.5'
29
+ version: '0.7'
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
32
  version: 2.a
@@ -236,7 +236,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
236
236
  - !ruby/object:Gem::Version
237
237
  version: '0'
238
238
  requirements: []
239
- rubygems_version: 3.2.17
239
+ rubygems_version: 3.3.4
240
240
  signing_key:
241
241
  specification_version: 4
242
242
  summary: API Client library for the Dataflow V1beta3 API