google-cloud-dataproc-v1 0.16.0 → 0.18.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (58) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +2 -2
  3. data/lib/google/cloud/dataproc/v1/autoscaling_policies_pb.rb +25 -51
  4. data/lib/google/cloud/dataproc/v1/autoscaling_policy_service/client.rb +6 -4
  5. data/lib/google/cloud/dataproc/v1/autoscaling_policy_service/rest/client.rb +713 -0
  6. data/lib/google/cloud/dataproc/v1/autoscaling_policy_service/rest/service_stub.rb +382 -0
  7. data/lib/google/cloud/dataproc/v1/autoscaling_policy_service/rest.rb +54 -0
  8. data/lib/google/cloud/dataproc/v1/autoscaling_policy_service.rb +6 -0
  9. data/lib/google/cloud/dataproc/v1/batch_controller/client.rb +6 -4
  10. data/lib/google/cloud/dataproc/v1/batch_controller/operations.rb +5 -3
  11. data/lib/google/cloud/dataproc/v1/batch_controller/rest/client.rb +642 -0
  12. data/lib/google/cloud/dataproc/v1/batch_controller/rest/operations.rb +822 -0
  13. data/lib/google/cloud/dataproc/v1/batch_controller/rest/service_stub.rb +285 -0
  14. data/lib/google/cloud/dataproc/v1/batch_controller/rest.rb +54 -0
  15. data/lib/google/cloud/dataproc/v1/batch_controller.rb +6 -0
  16. data/lib/google/cloud/dataproc/v1/batches_pb.rb +26 -88
  17. data/lib/google/cloud/dataproc/v1/bindings_override.rb +257 -0
  18. data/lib/google/cloud/dataproc/v1/cluster_controller/client.rb +6 -4
  19. data/lib/google/cloud/dataproc/v1/cluster_controller/operations.rb +5 -3
  20. data/lib/google/cloud/dataproc/v1/cluster_controller/rest/client.rb +1119 -0
  21. data/lib/google/cloud/dataproc/v1/cluster_controller/rest/operations.rb +822 -0
  22. data/lib/google/cloud/dataproc/v1/cluster_controller/rest/service_stub.rb +539 -0
  23. data/lib/google/cloud/dataproc/v1/cluster_controller/rest.rb +55 -0
  24. data/lib/google/cloud/dataproc/v1/cluster_controller.rb +6 -0
  25. data/lib/google/cloud/dataproc/v1/clusters_pb.rb +28 -289
  26. data/lib/google/cloud/dataproc/v1/job_controller/client.rb +6 -4
  27. data/lib/google/cloud/dataproc/v1/job_controller/operations.rb +5 -3
  28. data/lib/google/cloud/dataproc/v1/job_controller/rest/client.rb +931 -0
  29. data/lib/google/cloud/dataproc/v1/job_controller/rest/operations.rb +822 -0
  30. data/lib/google/cloud/dataproc/v1/job_controller/rest/service_stub.rb +476 -0
  31. data/lib/google/cloud/dataproc/v1/job_controller/rest.rb +53 -0
  32. data/lib/google/cloud/dataproc/v1/job_controller.rb +6 -0
  33. data/lib/google/cloud/dataproc/v1/jobs_pb.rb +26 -248
  34. data/lib/google/cloud/dataproc/v1/node_group_controller/client.rb +6 -4
  35. data/lib/google/cloud/dataproc/v1/node_group_controller/operations.rb +5 -3
  36. data/lib/google/cloud/dataproc/v1/node_group_controller/rest/client.rb +583 -0
  37. data/lib/google/cloud/dataproc/v1/node_group_controller/rest/operations.rb +822 -0
  38. data/lib/google/cloud/dataproc/v1/node_group_controller/rest/service_stub.rb +227 -0
  39. data/lib/google/cloud/dataproc/v1/node_group_controller/rest.rb +55 -0
  40. data/lib/google/cloud/dataproc/v1/node_group_controller.rb +6 -0
  41. data/lib/google/cloud/dataproc/v1/node_groups_pb.rb +26 -16
  42. data/lib/google/cloud/dataproc/v1/operations_pb.rb +25 -55
  43. data/lib/google/cloud/dataproc/v1/rest.rb +43 -0
  44. data/lib/google/cloud/dataproc/v1/shared_pb.rb +26 -116
  45. data/lib/google/cloud/dataproc/v1/version.rb +1 -1
  46. data/lib/google/cloud/dataproc/v1/workflow_template_service/client.rb +6 -4
  47. data/lib/google/cloud/dataproc/v1/workflow_template_service/operations.rb +5 -3
  48. data/lib/google/cloud/dataproc/v1/workflow_template_service/rest/client.rb +985 -0
  49. data/lib/google/cloud/dataproc/v1/workflow_template_service/rest/operations.rb +822 -0
  50. data/lib/google/cloud/dataproc/v1/workflow_template_service/rest/service_stub.rb +518 -0
  51. data/lib/google/cloud/dataproc/v1/workflow_template_service/rest.rb +55 -0
  52. data/lib/google/cloud/dataproc/v1/workflow_template_service.rb +6 -0
  53. data/lib/google/cloud/dataproc/v1/workflow_templates_pb.rb +28 -142
  54. data/lib/google/cloud/dataproc/v1.rb +5 -0
  55. data/proto_docs/google/api/client.rb +67 -4
  56. data/proto_docs/google/protobuf/any.rb +7 -4
  57. data/proto_docs/google/protobuf/timestamp.rb +1 -3
  58. metadata +30 -5
@@ -0,0 +1,257 @@
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 Dataproc
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/dataproc/v1/rest"
28
+ # client = ::Google::Cloud::Dataproc::V1::AutoscalingPolicyService::Rest::Client.new
29
+ #
30
+ module V1
31
+ ##
32
+ # @private
33
+ # Initialize the mixin bindings configuration
34
+ #
35
+ def self.configure
36
+ @configure ||= begin
37
+ namespace = ["Google", "Cloud", "Dataproc"]
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.iam.v1.IAMPolicy.GetIamPolicy"] = [
47
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
48
+ uri_method: :post,
49
+ uri_template: "/v1/{resource}:getIamPolicy",
50
+ matches: [
51
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/clusters/[^/]+/?$}, false]
52
+ ],
53
+ body: "*"
54
+ ),
55
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
56
+ uri_method: :post,
57
+ uri_template: "/v1/{resource}:getIamPolicy",
58
+ matches: [
59
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/jobs/[^/]+/?$}, false]
60
+ ],
61
+ body: "*"
62
+ ),
63
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
64
+ uri_method: :post,
65
+ uri_template: "/v1/{resource}:getIamPolicy",
66
+ matches: [
67
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/operations/[^/]+/?$}, false]
68
+ ],
69
+ body: "*"
70
+ ),
71
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
72
+ uri_method: :post,
73
+ uri_template: "/v1/{resource}:getIamPolicy",
74
+ matches: [
75
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/workflowTemplates/[^/]+/?$}, false]
76
+ ],
77
+ body: "*"
78
+ ),
79
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
80
+ uri_method: :post,
81
+ uri_template: "/v1/{resource}:getIamPolicy",
82
+ matches: [
83
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/workflowTemplates/[^/]+/?$}, false]
84
+ ],
85
+ body: "*"
86
+ ),
87
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
88
+ uri_method: :post,
89
+ uri_template: "/v1/{resource}:getIamPolicy",
90
+ matches: [
91
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/autoscalingPolicies/[^/]+/?$}, false]
92
+ ],
93
+ body: "*"
94
+ ),
95
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
96
+ uri_method: :post,
97
+ uri_template: "/v1/{resource}:getIamPolicy",
98
+ matches: [
99
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/autoscalingPolicies/[^/]+/?$}, false]
100
+ ],
101
+ body: "*"
102
+ )
103
+ ]
104
+ default_config.bindings_override["google.iam.v1.IAMPolicy.SetIamPolicy"] = [
105
+
106
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
107
+ uri_method: :post,
108
+ uri_template: "/v1/{resource}:setIamPolicy",
109
+ matches: [
110
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/clusters/[^/]+/?$}, false]
111
+ ],
112
+ body: "*"
113
+ ),
114
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
115
+ uri_method: :post,
116
+ uri_template: "/v1/{resource}:setIamPolicy",
117
+ matches: [
118
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/jobs/[^/]+/?$}, false]
119
+ ],
120
+ body: "*"
121
+ ),
122
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
123
+ uri_method: :post,
124
+ uri_template: "/v1/{resource}:setIamPolicy",
125
+ matches: [
126
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/operations/[^/]+/?$}, false]
127
+ ],
128
+ body: "*"
129
+ ),
130
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
131
+ uri_method: :post,
132
+ uri_template: "/v1/{resource}:setIamPolicy",
133
+ matches: [
134
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/workflowTemplates/[^/]+/?$}, false]
135
+ ],
136
+ body: "*"
137
+ ),
138
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
139
+ uri_method: :post,
140
+ uri_template: "/v1/{resource}:setIamPolicy",
141
+ matches: [
142
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/workflowTemplates/[^/]+/?$}, false]
143
+ ],
144
+ body: "*"
145
+ ),
146
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
147
+ uri_method: :post,
148
+ uri_template: "/v1/{resource}:setIamPolicy",
149
+ matches: [
150
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/autoscalingPolicies/[^/]+/?$}, false]
151
+ ],
152
+ body: "*"
153
+ ),
154
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
155
+ uri_method: :post,
156
+ uri_template: "/v1/{resource}:setIamPolicy",
157
+ matches: [
158
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/autoscalingPolicies/[^/]+/?$}, false]
159
+ ],
160
+ body: "*"
161
+ )
162
+ ]
163
+ default_config.bindings_override["google.iam.v1.IAMPolicy.TestIamPermissions"] = [
164
+
165
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
166
+ uri_method: :post,
167
+ uri_template: "/v1/{resource}:testIamPermissions",
168
+ matches: [
169
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/clusters/[^/]+/?$}, false]
170
+ ],
171
+ body: "*"
172
+ ),
173
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
174
+ uri_method: :post,
175
+ uri_template: "/v1/{resource}:testIamPermissions",
176
+ matches: [
177
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/jobs/[^/]+/?$}, false]
178
+ ],
179
+ body: "*"
180
+ ),
181
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
182
+ uri_method: :post,
183
+ uri_template: "/v1/{resource}:testIamPermissions",
184
+ matches: [
185
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/operations/[^/]+/?$}, false]
186
+ ],
187
+ body: "*"
188
+ ),
189
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
190
+ uri_method: :post,
191
+ uri_template: "/v1/{resource}:testIamPermissions",
192
+ matches: [
193
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/workflowTemplates/[^/]+/?$}, false]
194
+ ],
195
+ body: "*"
196
+ ),
197
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
198
+ uri_method: :post,
199
+ uri_template: "/v1/{resource}:testIamPermissions",
200
+ matches: [
201
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/workflowTemplates/[^/]+/?$}, false]
202
+ ],
203
+ body: "*"
204
+ ),
205
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
206
+ uri_method: :post,
207
+ uri_template: "/v1/{resource}:testIamPermissions",
208
+ matches: [
209
+ ["resource", %r{^projects/[^/]+/regions/[^/]+/autoscalingPolicies/[^/]+/?$}, false]
210
+ ],
211
+ body: "*"
212
+ ),
213
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
214
+ uri_method: :post,
215
+ uri_template: "/v1/{resource}:testIamPermissions",
216
+ matches: [
217
+ ["resource", %r{^projects/[^/]+/locations/[^/]+/autoscalingPolicies/[^/]+/?$}, false]
218
+ ],
219
+ body: "*"
220
+ )
221
+ ]
222
+ default_config
223
+ end
224
+ yield @configure if block_given?
225
+ @configure
226
+ end
227
+
228
+ ##
229
+ # @private
230
+ # Configuration class for the google.cloud.dataproc.v1 package.
231
+ #
232
+ # This class contains common configuration for all services
233
+ # of the google.cloud.dataproc.v1 package.
234
+ #
235
+ # This configuration is for internal use of the client library classes,
236
+ # and it is not intended that the end-users will read or change it.
237
+ #
238
+ class Configuration
239
+ extend ::Gapic::Config
240
+
241
+ # @private
242
+ # Overrides for http bindings for the RPC of the mixins for this package.
243
+ # Services in this package should use these when creating clients for the mixin services.
244
+ # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
245
+ config_attr :bindings_override, {}, ::Hash, nil
246
+
247
+ # @private
248
+ def initialize parent_config = nil
249
+ @parent_config = parent_config unless parent_config.nil?
250
+
251
+ yield self if block_given?
252
+ end
253
+ end
254
+ end
255
+ end
256
+ end
257
+ end
@@ -155,7 +155,7 @@ module Google
155
155
  credentials = @config.credentials
156
156
  # Use self-signed JWT if the endpoint is unchanged from default,
157
157
  # but only if the default endpoint does not have a region prefix.
158
- enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
158
+ enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
159
159
  !@config.endpoint.split(".").first.include?("-")
160
160
  credentials ||= Credentials.default scope: @config.scope,
161
161
  enable_self_signed_jwt: enable_self_signed_jwt
@@ -1232,9 +1232,9 @@ module Google
1232
1232
  # * (`String`) The path to a service account key file in JSON format
1233
1233
  # * (`Hash`) A service account key as a Hash
1234
1234
  # * (`Google::Auth::Credentials`) A googleauth credentials object
1235
- # (see the [googleauth docs](https://googleapis.dev/ruby/googleauth/latest/index.html))
1235
+ # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
1236
1236
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
1237
- # (see the [signet docs](https://googleapis.dev/ruby/signet/latest/Signet/OAuth2/Client.html))
1237
+ # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
1238
1238
  # * (`GRPC::Core::Channel`) a gRPC channel with included credentials
1239
1239
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
1240
1240
  # * (`nil`) indicating no credentials
@@ -1276,7 +1276,9 @@ module Google
1276
1276
  class Configuration
1277
1277
  extend ::Gapic::Config
1278
1278
 
1279
- config_attr :endpoint, "dataproc.googleapis.com", ::String
1279
+ DEFAULT_ENDPOINT = "dataproc.googleapis.com"
1280
+
1281
+ config_attr :endpoint, DEFAULT_ENDPOINT, ::String
1280
1282
  config_attr :credentials, nil do |value|
1281
1283
  allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
1282
1284
  allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
@@ -620,9 +620,9 @@ module Google
620
620
  # * (`String`) The path to a service account key file in JSON format
621
621
  # * (`Hash`) A service account key as a Hash
622
622
  # * (`Google::Auth::Credentials`) A googleauth credentials object
623
- # (see the [googleauth docs](https://googleapis.dev/ruby/googleauth/latest/index.html))
623
+ # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
624
624
  # * (`Signet::OAuth2::Client`) A signet oauth2 client object
625
- # (see the [signet docs](https://googleapis.dev/ruby/signet/latest/Signet/OAuth2/Client.html))
625
+ # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
626
626
  # * (`GRPC::Core::Channel`) a gRPC channel with included credentials
627
627
  # * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
628
628
  # * (`nil`) indicating no credentials
@@ -664,7 +664,9 @@ module Google
664
664
  class Configuration
665
665
  extend ::Gapic::Config
666
666
 
667
- config_attr :endpoint, "dataproc.googleapis.com", ::String
667
+ DEFAULT_ENDPOINT = "dataproc.googleapis.com"
668
+
669
+ config_attr :endpoint, DEFAULT_ENDPOINT, ::String
668
670
  config_attr :credentials, nil do |value|
669
671
  allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
670
672
  allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC