google-cloud-app_engine-v1 0.2.0 → 0.3.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (30) hide show
  1. checksums.yaml +4 -4
  2. data/AUTHENTICATION.md +8 -8
  3. data/README.md +1 -1
  4. data/lib/google/appengine/v1/instance_pb.rb +15 -0
  5. data/lib/google/appengine/v1/location_pb.rb +2 -0
  6. data/lib/google/appengine/v1/network_settings_pb.rb +11 -0
  7. data/lib/google/appengine/v1/operation_pb.rb +1 -0
  8. data/lib/google/appengine/v1/service_pb.rb +2 -0
  9. data/lib/google/appengine/v1/version_pb.rb +4 -0
  10. data/lib/google/cloud/app_engine/v1/applications/client.rb +42 -41
  11. data/lib/google/cloud/app_engine/v1/applications/operations.rb +34 -25
  12. data/lib/google/cloud/app_engine/v1/authorized_certificates/client.rb +45 -42
  13. data/lib/google/cloud/app_engine/v1/authorized_domains/client.rb +33 -38
  14. data/lib/google/cloud/app_engine/v1/domain_mappings/client.rb +45 -42
  15. data/lib/google/cloud/app_engine/v1/domain_mappings/operations.rb +34 -25
  16. data/lib/google/cloud/app_engine/v1/firewall/client.rb +48 -43
  17. data/lib/google/cloud/app_engine/v1/instances/client.rb +42 -41
  18. data/lib/google/cloud/app_engine/v1/instances/operations.rb +34 -25
  19. data/lib/google/cloud/app_engine/v1/services/client.rb +42 -41
  20. data/lib/google/cloud/app_engine/v1/services/operations.rb +34 -25
  21. data/lib/google/cloud/app_engine/v1/version.rb +1 -1
  22. data/lib/google/cloud/app_engine/v1/versions/client.rb +45 -42
  23. data/lib/google/cloud/app_engine/v1/versions/operations.rb +34 -25
  24. data/proto_docs/google/api/field_behavior.rb +71 -0
  25. data/proto_docs/google/appengine/v1/instance.rb +71 -32
  26. data/proto_docs/google/appengine/v1/location.rb +4 -0
  27. data/proto_docs/google/appengine/v1/network_settings.rb +51 -0
  28. data/proto_docs/google/appengine/v1/service.rb +3 -0
  29. data/proto_docs/google/appengine/v1/version.rb +26 -1
  30. metadata +15 -7
@@ -82,7 +82,7 @@ module Google
82
82
  # Create credentials
83
83
  credentials = @config.credentials
84
84
  credentials ||= Credentials.default scope: @config.scope
85
- if credentials.is_a?(String) || credentials.is_a?(Hash)
85
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
86
86
  credentials = Credentials.new credentials, scope: @config.scope
87
87
  end
88
88
  @quota_project_id = @config.quota_project
@@ -169,7 +169,9 @@ module Google
169
169
  options.apply_defaults timeout: @config.rpcs.list_operations.timeout,
170
170
  metadata: metadata,
171
171
  retry_policy: @config.rpcs.list_operations.retry_policy
172
- options.apply_defaults metadata: @config.metadata,
172
+
173
+ options.apply_defaults timeout: @config.timeout,
174
+ metadata: @config.metadata,
173
175
  retry_policy: @config.retry_policy
174
176
 
175
177
  @operations_stub.call_rpc :list_operations, request, options: options do |response, operation|
@@ -239,7 +241,9 @@ module Google
239
241
  options.apply_defaults timeout: @config.rpcs.get_operation.timeout,
240
242
  metadata: metadata,
241
243
  retry_policy: @config.rpcs.get_operation.retry_policy
242
- options.apply_defaults metadata: @config.metadata,
244
+
245
+ options.apply_defaults timeout: @config.timeout,
246
+ metadata: @config.metadata,
243
247
  retry_policy: @config.retry_policy
244
248
 
245
249
  @operations_stub.call_rpc :get_operation, request, options: options do |response, operation|
@@ -309,7 +313,9 @@ module Google
309
313
  options.apply_defaults timeout: @config.rpcs.delete_operation.timeout,
310
314
  metadata: metadata,
311
315
  retry_policy: @config.rpcs.delete_operation.retry_policy
312
- options.apply_defaults metadata: @config.metadata,
316
+
317
+ options.apply_defaults timeout: @config.timeout,
318
+ metadata: @config.metadata,
313
319
  retry_policy: @config.retry_policy
314
320
 
315
321
  @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation|
@@ -384,7 +390,9 @@ module Google
384
390
  options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout,
385
391
  metadata: metadata,
386
392
  retry_policy: @config.rpcs.cancel_operation.retry_policy
387
- options.apply_defaults metadata: @config.metadata,
393
+
394
+ options.apply_defaults timeout: @config.timeout,
395
+ metadata: @config.metadata,
388
396
  retry_policy: @config.retry_policy
389
397
 
390
398
  @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation|
@@ -396,9 +404,9 @@ module Google
396
404
  end
397
405
 
398
406
  ##
399
- # Waits for the specified long-running operation until it is done or reaches
400
- # at most a specified timeout, returning the latest state. If the operation
401
- # is already done, the latest state is immediately returned. If the timeout
407
+ # Waits until the specified long-running operation is done or reaches at most
408
+ # a specified timeout, returning the latest state. If the operation is
409
+ # already done, the latest state is immediately returned. If the timeout
402
410
  # specified is greater than the default HTTP/RPC timeout, the HTTP/RPC
403
411
  # timeout is used. If the server does not support this method, it returns
404
412
  # `google.rpc.Code.UNIMPLEMENTED`.
@@ -456,7 +464,9 @@ module Google
456
464
  options.apply_defaults timeout: @config.rpcs.wait_operation.timeout,
457
465
  metadata: metadata,
458
466
  retry_policy: @config.rpcs.wait_operation.retry_policy
459
- options.apply_defaults metadata: @config.metadata,
467
+
468
+ options.apply_defaults timeout: @config.timeout,
469
+ metadata: @config.metadata,
460
470
  retry_policy: @config.retry_policy
461
471
 
462
472
  @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation|
@@ -481,22 +491,21 @@ module Google
481
491
  # Configuration can be applied globally to all clients, or to a single client
482
492
  # on construction.
483
493
  #
484
- # # Examples
485
- #
486
- # To modify the global config, setting the timeout for list_operations
487
- # to 20 seconds, and all remaining timeouts to 10 seconds:
488
- #
489
- # ::Google::Longrunning::Operations::Client.configure do |config|
490
- # config.timeout = 10.0
491
- # config.rpcs.list_operations.timeout = 20.0
492
- # end
493
- #
494
- # To apply the above configuration only to a new client:
495
- #
496
- # client = ::Google::Longrunning::Operations::Client.new do |config|
497
- # config.timeout = 10.0
498
- # config.rpcs.list_operations.timeout = 20.0
499
- # end
494
+ # @example
495
+ #
496
+ # # Modify the global config, setting the timeout for
497
+ # # list_operations to 20 seconds,
498
+ # # and all remaining timeouts to 10 seconds.
499
+ # ::Google::Longrunning::Operations::Client.configure do |config|
500
+ # config.timeout = 10.0
501
+ # config.rpcs.list_operations.timeout = 20.0
502
+ # end
503
+ #
504
+ # # Apply the above configuration only to a new client.
505
+ # client = ::Google::Longrunning::Operations::Client.new do |config|
506
+ # config.timeout = 10.0
507
+ # config.rpcs.list_operations.timeout = 20.0
508
+ # end
500
509
  #
501
510
  # @!attribute [rw] endpoint
502
511
  # The hostname or hostname:port of the service endpoint.
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module AppEngine
23
23
  module V1
24
- VERSION = "0.2.0"
24
+ VERSION = "0.3.3"
25
25
  end
26
26
  end
27
27
  end
@@ -39,13 +39,12 @@ module Google
39
39
  # See {::Google::Cloud::AppEngine::V1::Versions::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 Versions clients:
45
- #
46
- # ::Google::Cloud::AppEngine::V1::Versions::Client.configure do |config|
47
- # config.timeout = 10.0
48
- # end
44
+ # # Modify the configuration for all Versions clients
45
+ # ::Google::Cloud::AppEngine::V1::Versions::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]
@@ -92,19 +91,15 @@ module Google
92
91
  ##
93
92
  # Create a new Versions client object.
94
93
  #
95
- # ## Examples
96
- #
97
- # To create a new Versions client with the default
98
- # configuration:
99
- #
100
- # client = ::Google::Cloud::AppEngine::V1::Versions::Client.new
94
+ # @example
101
95
  #
102
- # To create a new Versions client with a custom
103
- # configuration:
96
+ # # Create a client using the default configuration
97
+ # client = ::Google::Cloud::AppEngine::V1::Versions::Client.new
104
98
  #
105
- # client = ::Google::Cloud::AppEngine::V1::Versions::Client.new do |config|
106
- # config.timeout = 10.0
107
- # end
99
+ # # Create a client using a custom configuration
100
+ # client = ::Google::Cloud::AppEngine::V1::Versions::Client.new do |config|
101
+ # config.timeout = 10.0
102
+ # end
108
103
  #
109
104
  # @yield [config] Configure the Versions client.
110
105
  # @yieldparam config [Client::Configuration]
@@ -124,14 +119,13 @@ module Google
124
119
 
125
120
  # Create credentials
126
121
  credentials = @config.credentials
127
- # Use self-signed JWT if the scope and endpoint are unchanged from default,
122
+ # Use self-signed JWT if the endpoint is unchanged from default,
128
123
  # but only if the default endpoint does not have a region prefix.
129
- enable_self_signed_jwt = @config.scope == Client.configure.scope &&
130
- @config.endpoint == Client.configure.endpoint &&
124
+ enable_self_signed_jwt = @config.endpoint == Client.configure.endpoint &&
131
125
  !@config.endpoint.split(".").first.include?("-")
132
126
  credentials ||= Credentials.default scope: @config.scope,
133
127
  enable_self_signed_jwt: enable_self_signed_jwt
134
- if credentials.is_a?(String) || credentials.is_a?(Hash)
128
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
135
129
  credentials = Credentials.new credentials, scope: @config.scope
136
130
  end
137
131
  @quota_project_id = @config.quota_project
@@ -222,7 +216,9 @@ module Google
222
216
  options.apply_defaults timeout: @config.rpcs.list_versions.timeout,
223
217
  metadata: metadata,
224
218
  retry_policy: @config.rpcs.list_versions.retry_policy
225
- options.apply_defaults metadata: @config.metadata,
219
+
220
+ options.apply_defaults timeout: @config.timeout,
221
+ metadata: @config.metadata,
226
222
  retry_policy: @config.retry_policy
227
223
 
228
224
  @versions_stub.call_rpc :list_versions, request, options: options do |response, operation|
@@ -294,7 +290,9 @@ module Google
294
290
  options.apply_defaults timeout: @config.rpcs.get_version.timeout,
295
291
  metadata: metadata,
296
292
  retry_policy: @config.rpcs.get_version.retry_policy
297
- options.apply_defaults metadata: @config.metadata,
293
+
294
+ options.apply_defaults timeout: @config.timeout,
295
+ metadata: @config.metadata,
298
296
  retry_policy: @config.retry_policy
299
297
 
300
298
  @versions_stub.call_rpc :get_version, request, options: options do |response, operation|
@@ -363,7 +361,9 @@ module Google
363
361
  options.apply_defaults timeout: @config.rpcs.create_version.timeout,
364
362
  metadata: metadata,
365
363
  retry_policy: @config.rpcs.create_version.retry_policy
366
- options.apply_defaults metadata: @config.metadata,
364
+
365
+ options.apply_defaults timeout: @config.timeout,
366
+ metadata: @config.metadata,
367
367
  retry_policy: @config.retry_policy
368
368
 
369
369
  @versions_stub.call_rpc :create_version, request, options: options do |response, operation|
@@ -471,7 +471,9 @@ module Google
471
471
  options.apply_defaults timeout: @config.rpcs.update_version.timeout,
472
472
  metadata: metadata,
473
473
  retry_policy: @config.rpcs.update_version.retry_policy
474
- options.apply_defaults metadata: @config.metadata,
474
+
475
+ options.apply_defaults timeout: @config.timeout,
476
+ metadata: @config.metadata,
475
477
  retry_policy: @config.retry_policy
476
478
 
477
479
  @versions_stub.call_rpc :update_version, request, options: options do |response, operation|
@@ -539,7 +541,9 @@ module Google
539
541
  options.apply_defaults timeout: @config.rpcs.delete_version.timeout,
540
542
  metadata: metadata,
541
543
  retry_policy: @config.rpcs.delete_version.retry_policy
542
- options.apply_defaults metadata: @config.metadata,
544
+
545
+ options.apply_defaults timeout: @config.timeout,
546
+ metadata: @config.metadata,
543
547
  retry_policy: @config.retry_policy
544
548
 
545
549
  @versions_stub.call_rpc :delete_version, request, options: options do |response, operation|
@@ -564,22 +568,21 @@ module Google
564
568
  # Configuration can be applied globally to all clients, or to a single client
565
569
  # on construction.
566
570
  #
567
- # # Examples
568
- #
569
- # To modify the global config, setting the timeout for list_versions
570
- # to 20 seconds, and all remaining timeouts to 10 seconds:
571
- #
572
- # ::Google::Cloud::AppEngine::V1::Versions::Client.configure do |config|
573
- # config.timeout = 10.0
574
- # config.rpcs.list_versions.timeout = 20.0
575
- # end
576
- #
577
- # To apply the above configuration only to a new client:
578
- #
579
- # client = ::Google::Cloud::AppEngine::V1::Versions::Client.new do |config|
580
- # config.timeout = 10.0
581
- # config.rpcs.list_versions.timeout = 20.0
582
- # end
571
+ # @example
572
+ #
573
+ # # Modify the global config, setting the timeout for
574
+ # # list_versions to 20 seconds,
575
+ # # and all remaining timeouts to 10 seconds.
576
+ # ::Google::Cloud::AppEngine::V1::Versions::Client.configure do |config|
577
+ # config.timeout = 10.0
578
+ # config.rpcs.list_versions.timeout = 20.0
579
+ # end
580
+ #
581
+ # # Apply the above configuration only to a new client.
582
+ # client = ::Google::Cloud::AppEngine::V1::Versions::Client.new do |config|
583
+ # config.timeout = 10.0
584
+ # config.rpcs.list_versions.timeout = 20.0
585
+ # end
583
586
  #
584
587
  # @!attribute [rw] endpoint
585
588
  # The hostname or hostname:port of the service endpoint.
@@ -82,7 +82,7 @@ module Google
82
82
  # Create credentials
83
83
  credentials = @config.credentials
84
84
  credentials ||= Credentials.default scope: @config.scope
85
- if credentials.is_a?(String) || credentials.is_a?(Hash)
85
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
86
86
  credentials = Credentials.new credentials, scope: @config.scope
87
87
  end
88
88
  @quota_project_id = @config.quota_project
@@ -169,7 +169,9 @@ module Google
169
169
  options.apply_defaults timeout: @config.rpcs.list_operations.timeout,
170
170
  metadata: metadata,
171
171
  retry_policy: @config.rpcs.list_operations.retry_policy
172
- options.apply_defaults metadata: @config.metadata,
172
+
173
+ options.apply_defaults timeout: @config.timeout,
174
+ metadata: @config.metadata,
173
175
  retry_policy: @config.retry_policy
174
176
 
175
177
  @operations_stub.call_rpc :list_operations, request, options: options do |response, operation|
@@ -239,7 +241,9 @@ module Google
239
241
  options.apply_defaults timeout: @config.rpcs.get_operation.timeout,
240
242
  metadata: metadata,
241
243
  retry_policy: @config.rpcs.get_operation.retry_policy
242
- options.apply_defaults metadata: @config.metadata,
244
+
245
+ options.apply_defaults timeout: @config.timeout,
246
+ metadata: @config.metadata,
243
247
  retry_policy: @config.retry_policy
244
248
 
245
249
  @operations_stub.call_rpc :get_operation, request, options: options do |response, operation|
@@ -309,7 +313,9 @@ module Google
309
313
  options.apply_defaults timeout: @config.rpcs.delete_operation.timeout,
310
314
  metadata: metadata,
311
315
  retry_policy: @config.rpcs.delete_operation.retry_policy
312
- options.apply_defaults metadata: @config.metadata,
316
+
317
+ options.apply_defaults timeout: @config.timeout,
318
+ metadata: @config.metadata,
313
319
  retry_policy: @config.retry_policy
314
320
 
315
321
  @operations_stub.call_rpc :delete_operation, request, options: options do |response, operation|
@@ -384,7 +390,9 @@ module Google
384
390
  options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout,
385
391
  metadata: metadata,
386
392
  retry_policy: @config.rpcs.cancel_operation.retry_policy
387
- options.apply_defaults metadata: @config.metadata,
393
+
394
+ options.apply_defaults timeout: @config.timeout,
395
+ metadata: @config.metadata,
388
396
  retry_policy: @config.retry_policy
389
397
 
390
398
  @operations_stub.call_rpc :cancel_operation, request, options: options do |response, operation|
@@ -396,9 +404,9 @@ module Google
396
404
  end
397
405
 
398
406
  ##
399
- # Waits for the specified long-running operation until it is done or reaches
400
- # at most a specified timeout, returning the latest state. If the operation
401
- # is already done, the latest state is immediately returned. If the timeout
407
+ # Waits until the specified long-running operation is done or reaches at most
408
+ # a specified timeout, returning the latest state. If the operation is
409
+ # already done, the latest state is immediately returned. If the timeout
402
410
  # specified is greater than the default HTTP/RPC timeout, the HTTP/RPC
403
411
  # timeout is used. If the server does not support this method, it returns
404
412
  # `google.rpc.Code.UNIMPLEMENTED`.
@@ -456,7 +464,9 @@ module Google
456
464
  options.apply_defaults timeout: @config.rpcs.wait_operation.timeout,
457
465
  metadata: metadata,
458
466
  retry_policy: @config.rpcs.wait_operation.retry_policy
459
- options.apply_defaults metadata: @config.metadata,
467
+
468
+ options.apply_defaults timeout: @config.timeout,
469
+ metadata: @config.metadata,
460
470
  retry_policy: @config.retry_policy
461
471
 
462
472
  @operations_stub.call_rpc :wait_operation, request, options: options do |response, operation|
@@ -481,22 +491,21 @@ module Google
481
491
  # Configuration can be applied globally to all clients, or to a single client
482
492
  # on construction.
483
493
  #
484
- # # Examples
485
- #
486
- # To modify the global config, setting the timeout for list_operations
487
- # to 20 seconds, and all remaining timeouts to 10 seconds:
488
- #
489
- # ::Google::Longrunning::Operations::Client.configure do |config|
490
- # config.timeout = 10.0
491
- # config.rpcs.list_operations.timeout = 20.0
492
- # end
493
- #
494
- # To apply the above configuration only to a new client:
495
- #
496
- # client = ::Google::Longrunning::Operations::Client.new do |config|
497
- # config.timeout = 10.0
498
- # config.rpcs.list_operations.timeout = 20.0
499
- # end
494
+ # @example
495
+ #
496
+ # # Modify the global config, setting the timeout for
497
+ # # list_operations to 20 seconds,
498
+ # # and all remaining timeouts to 10 seconds.
499
+ # ::Google::Longrunning::Operations::Client.configure do |config|
500
+ # config.timeout = 10.0
501
+ # config.rpcs.list_operations.timeout = 20.0
502
+ # end
503
+ #
504
+ # # Apply the above configuration only to a new client.
505
+ # client = ::Google::Longrunning::Operations::Client.new do |config|
506
+ # config.timeout = 10.0
507
+ # config.rpcs.list_operations.timeout = 20.0
508
+ # end
500
509
  #
501
510
  # @!attribute [rw] endpoint
502
511
  # The hostname or hostname:port of the service endpoint.
@@ -0,0 +1,71 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 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
+
20
+ module Google
21
+ module Api
22
+ # An indicator of the behavior of a given field (for example, that a field
23
+ # is required in requests, or given as output but ignored as input).
24
+ # This **does not** change the behavior in protocol buffers itself; it only
25
+ # denotes the behavior and may affect how API tooling handles the field.
26
+ #
27
+ # Note: This enum **may** receive new values in the future.
28
+ module FieldBehavior
29
+ # Conventional default for enums. Do not use this.
30
+ FIELD_BEHAVIOR_UNSPECIFIED = 0
31
+
32
+ # Specifically denotes a field as optional.
33
+ # While all fields in protocol buffers are optional, this may be specified
34
+ # for emphasis if appropriate.
35
+ OPTIONAL = 1
36
+
37
+ # Denotes a field as required.
38
+ # This indicates that the field **must** be provided as part of the request,
39
+ # and failure to do so will cause an error (usually `INVALID_ARGUMENT`).
40
+ REQUIRED = 2
41
+
42
+ # Denotes a field as output only.
43
+ # This indicates that the field is provided in responses, but including the
44
+ # field in a request does nothing (the server *must* ignore it and
45
+ # *must not* throw an error as a result of the field's presence).
46
+ OUTPUT_ONLY = 3
47
+
48
+ # Denotes a field as input only.
49
+ # This indicates that the field is provided in requests, and the
50
+ # corresponding field is not included in output.
51
+ INPUT_ONLY = 4
52
+
53
+ # Denotes a field as immutable.
54
+ # This indicates that the field may be set once in a request to create a
55
+ # resource, but may not be changed thereafter.
56
+ IMMUTABLE = 5
57
+
58
+ # Denotes that a (repeated) field is an unordered list.
59
+ # This indicates that the service may provide the elements of the list
60
+ # in any arbitrary order, rather than the order the user originally
61
+ # provided. Additionally, the list's order may or may not be stable.
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
69
+ end
70
+ end
71
+ end