google-cloud-dataflow-v1beta3 0.7.0 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (25) hide show
  1. checksums.yaml +4 -4
  2. data/AUTHENTICATION.md +72 -101
  3. data/lib/google/cloud/dataflow/v1beta3/flex_templates_service/client.rb +31 -8
  4. data/lib/google/cloud/dataflow/v1beta3/flex_templates_service/rest/client.rb +33 -7
  5. data/lib/google/cloud/dataflow/v1beta3/flex_templates_service/rest/service_stub.rb +14 -2
  6. data/lib/google/cloud/dataflow/v1beta3/jobs/client.rb +31 -8
  7. data/lib/google/cloud/dataflow/v1beta3/jobs/rest/client.rb +33 -7
  8. data/lib/google/cloud/dataflow/v1beta3/jobs/rest/service_stub.rb +14 -2
  9. data/lib/google/cloud/dataflow/v1beta3/messages/client.rb +31 -8
  10. data/lib/google/cloud/dataflow/v1beta3/messages/rest/client.rb +33 -7
  11. data/lib/google/cloud/dataflow/v1beta3/messages/rest/service_stub.rb +14 -2
  12. data/lib/google/cloud/dataflow/v1beta3/metrics/client.rb +31 -8
  13. data/lib/google/cloud/dataflow/v1beta3/metrics/rest/client.rb +33 -7
  14. data/lib/google/cloud/dataflow/v1beta3/metrics/rest/service_stub.rb +14 -2
  15. data/lib/google/cloud/dataflow/v1beta3/snapshots/client.rb +31 -8
  16. data/lib/google/cloud/dataflow/v1beta3/snapshots/rest/client.rb +33 -7
  17. data/lib/google/cloud/dataflow/v1beta3/snapshots/rest/service_stub.rb +14 -2
  18. data/lib/google/cloud/dataflow/v1beta3/templates_service/client.rb +31 -8
  19. data/lib/google/cloud/dataflow/v1beta3/templates_service/rest/client.rb +33 -7
  20. data/lib/google/cloud/dataflow/v1beta3/templates_service/rest/service_stub.rb +14 -2
  21. data/lib/google/cloud/dataflow/v1beta3/version.rb +1 -1
  22. data/proto_docs/google/api/client.rb +14 -0
  23. data/proto_docs/google/dataflow/v1beta3/jobs.rb +1 -0
  24. data/proto_docs/google/dataflow/v1beta3/streaming.rb +1 -0
  25. metadata +5 -5
@@ -30,16 +30,28 @@ module Google
30
30
  # including transcoding, making the REST call, and deserialing the response.
31
31
  #
32
32
  class ServiceStub
33
- def initialize endpoint:, credentials:
33
+ def initialize endpoint:, endpoint_template:, universe_domain:, credentials:
34
34
  # These require statements are intentionally placed here to initialize
35
35
  # the REST modules only when it's required.
36
36
  require "gapic/rest"
37
37
 
38
- @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, credentials: credentials,
38
+ @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
39
+ endpoint_template: endpoint_template,
40
+ universe_domain: universe_domain,
41
+ credentials: credentials,
39
42
  numeric_enums: true,
40
43
  raise_faraday_errors: false
41
44
  end
42
45
 
46
+ ##
47
+ # The effective universe domain
48
+ #
49
+ # @return [String]
50
+ #
51
+ def universe_domain
52
+ @client_stub.universe_domain
53
+ end
54
+
43
55
  ##
44
56
  # Baseline implementation for the get_snapshot REST call
45
57
  #
@@ -30,6 +30,9 @@ module Google
30
30
  # Provides a method to create Cloud Dataflow jobs from templates.
31
31
  #
32
32
  class Client
33
+ # @private
34
+ DEFAULT_ENDPOINT_TEMPLATE = "dataflow.$UNIVERSE_DOMAIN$"
35
+
33
36
  # @private
34
37
  attr_reader :templates_service_stub
35
38
 
@@ -90,6 +93,15 @@ module Google
90
93
  @config
91
94
  end
92
95
 
96
+ ##
97
+ # The effective universe domain
98
+ #
99
+ # @return [String]
100
+ #
101
+ def universe_domain
102
+ @templates_service_stub.universe_domain
103
+ end
104
+
93
105
  ##
94
106
  # Create a new TemplatesService client object.
95
107
  #
@@ -123,8 +135,9 @@ module Google
123
135
  credentials = @config.credentials
124
136
  # Use self-signed JWT if the endpoint is unchanged from default,
125
137
  # but only if the default endpoint does not have a region prefix.
126
- enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
127
- !@config.endpoint.split(".").first.include?("-")
138
+ enable_self_signed_jwt = @config.endpoint.nil? ||
139
+ (@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
140
+ !@config.endpoint.split(".").first.include?("-"))
128
141
  credentials ||= Credentials.default scope: @config.scope,
129
142
  enable_self_signed_jwt: enable_self_signed_jwt
130
143
  if credentials.is_a?(::String) || credentials.is_a?(::Hash)
@@ -135,8 +148,10 @@ module Google
135
148
 
136
149
  @templates_service_stub = ::Gapic::ServiceStub.new(
137
150
  ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Stub,
138
- credentials: credentials,
139
- endpoint: @config.endpoint,
151
+ credentials: credentials,
152
+ endpoint: @config.endpoint,
153
+ endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
154
+ universe_domain: @config.universe_domain,
140
155
  channel_args: @config.channel_args,
141
156
  interceptors: @config.interceptors,
142
157
  channel_pool_config: @config.channel_pool
@@ -479,9 +494,9 @@ module Google
479
494
  # end
480
495
  #
481
496
  # @!attribute [rw] endpoint
482
- # The hostname or hostname:port of the service endpoint.
483
- # Defaults to `"dataflow.googleapis.com"`.
484
- # @return [::String]
497
+ # A custom service endpoint, as a hostname or hostname:port. The default is
498
+ # nil, indicating to use the default endpoint in the current universe domain.
499
+ # @return [::String,nil]
485
500
  # @!attribute [rw] credentials
486
501
  # Credentials to send with calls. You may provide any of the following types:
487
502
  # * (`String`) The path to a service account key file in JSON format
@@ -527,13 +542,20 @@ module Google
527
542
  # @!attribute [rw] quota_project
528
543
  # A separate project against which to charge quota.
529
544
  # @return [::String]
545
+ # @!attribute [rw] universe_domain
546
+ # The universe domain within which to make requests. This determines the
547
+ # default endpoint URL. The default value of nil uses the environment
548
+ # universe (usually the default "googleapis.com" universe).
549
+ # @return [::String,nil]
530
550
  #
531
551
  class Configuration
532
552
  extend ::Gapic::Config
533
553
 
554
+ # @private
555
+ # The endpoint specific to the default "googleapis.com" universe. Deprecated.
534
556
  DEFAULT_ENDPOINT = "dataflow.googleapis.com"
535
557
 
536
- config_attr :endpoint, DEFAULT_ENDPOINT, ::String
558
+ config_attr :endpoint, nil, ::String, nil
537
559
  config_attr :credentials, nil do |value|
538
560
  allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
539
561
  allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
@@ -548,6 +570,7 @@ module Google
548
570
  config_attr :metadata, nil, ::Hash, nil
549
571
  config_attr :retry_policy, nil, ::Hash, ::Proc, nil
550
572
  config_attr :quota_project, nil, ::String, nil
573
+ config_attr :universe_domain, nil, ::String, nil
551
574
 
552
575
  # @private
553
576
  def initialize parent_config = nil
@@ -32,6 +32,9 @@ module Google
32
32
  # Provides a method to create Cloud Dataflow jobs from templates.
33
33
  #
34
34
  class Client
35
+ # @private
36
+ DEFAULT_ENDPOINT_TEMPLATE = "dataflow.$UNIVERSE_DOMAIN$"
37
+
35
38
  # @private
36
39
  attr_reader :templates_service_stub
37
40
 
@@ -92,6 +95,15 @@ module Google
92
95
  @config
93
96
  end
94
97
 
98
+ ##
99
+ # The effective universe domain
100
+ #
101
+ # @return [String]
102
+ #
103
+ def universe_domain
104
+ @templates_service_stub.universe_domain
105
+ end
106
+
95
107
  ##
96
108
  # Create a new TemplatesService REST client object.
97
109
  #
@@ -119,8 +131,9 @@ module Google
119
131
  credentials = @config.credentials
120
132
  # Use self-signed JWT if the endpoint is unchanged from default,
121
133
  # but only if the default endpoint does not have a region prefix.
122
- enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
123
- !@config.endpoint.split(".").first.include?("-")
134
+ enable_self_signed_jwt = @config.endpoint.nil? ||
135
+ (@config.endpoint == Configuration::DEFAULT_ENDPOINT &&
136
+ !@config.endpoint.split(".").first.include?("-"))
124
137
  credentials ||= Credentials.default scope: @config.scope,
125
138
  enable_self_signed_jwt: enable_self_signed_jwt
126
139
  if credentials.is_a?(::String) || credentials.is_a?(::Hash)
@@ -130,7 +143,12 @@ module Google
130
143
  @quota_project_id = @config.quota_project
131
144
  @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
132
145
 
133
- @templates_service_stub = ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials
146
+ @templates_service_stub = ::Google::Cloud::Dataflow::V1beta3::TemplatesService::Rest::ServiceStub.new(
147
+ endpoint: @config.endpoint,
148
+ endpoint_template: DEFAULT_ENDPOINT_TEMPLATE,
149
+ universe_domain: @config.universe_domain,
150
+ credentials: credentials
151
+ )
134
152
  end
135
153
 
136
154
  # Service calls
@@ -439,9 +457,9 @@ module Google
439
457
  # end
440
458
  #
441
459
  # @!attribute [rw] endpoint
442
- # The hostname or hostname:port of the service endpoint.
443
- # Defaults to `"dataflow.googleapis.com"`.
444
- # @return [::String]
460
+ # A custom service endpoint, as a hostname or hostname:port. The default is
461
+ # nil, indicating to use the default endpoint in the current universe domain.
462
+ # @return [::String,nil]
445
463
  # @!attribute [rw] credentials
446
464
  # Credentials to send with calls. You may provide any of the following types:
447
465
  # * (`String`) The path to a service account key file in JSON format
@@ -478,13 +496,20 @@ module Google
478
496
  # @!attribute [rw] quota_project
479
497
  # A separate project against which to charge quota.
480
498
  # @return [::String]
499
+ # @!attribute [rw] universe_domain
500
+ # The universe domain within which to make requests. This determines the
501
+ # default endpoint URL. The default value of nil uses the environment
502
+ # universe (usually the default "googleapis.com" universe).
503
+ # @return [::String,nil]
481
504
  #
482
505
  class Configuration
483
506
  extend ::Gapic::Config
484
507
 
508
+ # @private
509
+ # The endpoint specific to the default "googleapis.com" universe. Deprecated.
485
510
  DEFAULT_ENDPOINT = "dataflow.googleapis.com"
486
511
 
487
- config_attr :endpoint, DEFAULT_ENDPOINT, ::String
512
+ config_attr :endpoint, nil, ::String, nil
488
513
  config_attr :credentials, nil do |value|
489
514
  allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
490
515
  allowed.any? { |klass| klass === value }
@@ -496,6 +521,7 @@ module Google
496
521
  config_attr :metadata, nil, ::Hash, nil
497
522
  config_attr :retry_policy, nil, ::Hash, ::Proc, nil
498
523
  config_attr :quota_project, nil, ::String, nil
524
+ config_attr :universe_domain, nil, ::String, nil
499
525
 
500
526
  # @private
501
527
  def initialize parent_config = nil
@@ -30,16 +30,28 @@ module Google
30
30
  # including transcoding, making the REST call, and deserialing the response.
31
31
  #
32
32
  class ServiceStub
33
- def initialize endpoint:, credentials:
33
+ def initialize endpoint:, endpoint_template:, universe_domain:, credentials:
34
34
  # These require statements are intentionally placed here to initialize
35
35
  # the REST modules only when it's required.
36
36
  require "gapic/rest"
37
37
 
38
- @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, credentials: credentials,
38
+ @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
39
+ endpoint_template: endpoint_template,
40
+ universe_domain: universe_domain,
41
+ credentials: credentials,
39
42
  numeric_enums: true,
40
43
  raise_faraday_errors: false
41
44
  end
42
45
 
46
+ ##
47
+ # The effective universe domain
48
+ #
49
+ # @return [String]
50
+ #
51
+ def universe_domain
52
+ @client_stub.universe_domain
53
+ end
54
+
43
55
  ##
44
56
  # Baseline implementation for the create_job_from_template REST call
45
57
  #
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Dataflow
23
23
  module V1beta3
24
- VERSION = "0.7.0"
24
+ VERSION = "0.8.0"
25
25
  end
26
26
  end
27
27
  end
@@ -21,6 +21,7 @@ module Google
21
21
  module Api
22
22
  # Required information for every language.
23
23
  # @!attribute [rw] reference_docs_uri
24
+ # @deprecated This field is deprecated and may be removed in the next major version update.
24
25
  # @return [::String]
25
26
  # Link to automatically generated reference documentation. Example:
26
27
  # https://cloud.google.com/nodejs/docs/reference/asset/latest
@@ -304,6 +305,19 @@ module Google
304
305
  # seconds: 360 # 6 minutes
305
306
  # total_poll_timeout:
306
307
  # seconds: 54000 # 90 minutes
308
+ # @!attribute [rw] auto_populated_fields
309
+ # @return [::Array<::String>]
310
+ # List of top-level fields of the request message, that should be
311
+ # automatically populated by the client libraries based on their
312
+ # (google.api.field_info).format. Currently supported format: UUID4.
313
+ #
314
+ # Example of a YAML configuration:
315
+ #
316
+ # publishing:
317
+ # method_settings:
318
+ # - selector: google.example.v1.ExampleService.CreateExample
319
+ # auto_populated_fields:
320
+ # - request_id
307
321
  class MethodSettings
308
322
  include ::Google::Protobuf::MessageExts
309
323
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -678,6 +678,7 @@ module Google
678
678
  # @return [::String]
679
679
  # The project which owns the jobs.
680
680
  # @!attribute [rw] view
681
+ # @deprecated This field is deprecated and may be removed in the next major version update.
681
682
  # @return [::Google::Cloud::Dataflow::V1beta3::JobView]
682
683
  # Deprecated. ListJobs always returns summaries now.
683
684
  # Use GetJob for other JobViews.
@@ -193,6 +193,7 @@ module Google
193
193
  # identifies the disk within that project, for example
194
194
  # "myproject-1014-104817-4c2-harness-0-disk-1".
195
195
  # @!attribute [rw] deprecated_persistent_directory
196
+ # @deprecated This field is deprecated and may be removed in the next major version update.
196
197
  # @return [::String]
197
198
  # DEPRECATED. The location of the persistent state for this range, as a
198
199
  # persistent directory in the worker local filesystem.
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.7.0
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-09-12 00:00:00.000000000 Z
11
+ date: 2024-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.20.0
19
+ version: 0.21.1
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.20.0
29
+ version: 0.21.1
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
32
  version: 2.a
@@ -257,7 +257,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
257
257
  - !ruby/object:Gem::Version
258
258
  version: '0'
259
259
  requirements: []
260
- rubygems_version: 3.4.19
260
+ rubygems_version: 3.5.3
261
261
  signing_key:
262
262
  specification_version: 4
263
263
  summary: Manages Google Cloud Dataflow projects on Google Cloud Platform.