google-cloud-app_engine-v1 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.yardopts +12 -0
- data/AUTHENTICATION.md +169 -0
- data/LICENSE.md +201 -0
- data/README.md +139 -0
- data/lib/google-cloud-app_engine-v1.rb +21 -0
- data/lib/google/appengine/v1/app_yaml_pb.rb +137 -0
- data/lib/google/appengine/v1/appengine_pb.rb +261 -0
- data/lib/google/appengine/v1/appengine_services_pb.rb +313 -0
- data/lib/google/appengine/v1/application_pb.rb +69 -0
- data/lib/google/appengine/v1/audit_data_pb.rb +35 -0
- data/lib/google/appengine/v1/certificate_pb.rb +52 -0
- data/lib/google/appengine/v1/deploy_pb.rb +47 -0
- data/lib/google/appengine/v1/deployed_files_pb.rb +19 -0
- data/lib/google/appengine/v1/domain_mapping_pb.rb +51 -0
- data/lib/google/appengine/v1/domain_pb.rb +24 -0
- data/lib/google/appengine/v1/firewall_pb.rb +32 -0
- data/lib/google/appengine/v1/instance_pb.rb +45 -0
- data/lib/google/appengine/v1/location_pb.rb +24 -0
- data/lib/google/appengine/v1/network_settings_pb.rb +19 -0
- data/lib/google/appengine/v1/operation_pb.rb +37 -0
- data/lib/google/appengine/v1/service_pb.rb +37 -0
- data/lib/google/appengine/v1/version_pb.rb +183 -0
- data/lib/google/cloud/app_engine/v1.rb +45 -0
- data/lib/google/cloud/app_engine/v1/applications.rb +49 -0
- data/lib/google/cloud/app_engine/v1/applications/client.rb +624 -0
- data/lib/google/cloud/app_engine/v1/applications/credentials.rb +53 -0
- data/lib/google/cloud/app_engine/v1/applications/operations.rb +655 -0
- data/lib/google/cloud/app_engine/v1/authorized_certificates.rb +49 -0
- data/lib/google/cloud/app_engine/v1/authorized_certificates/client.rb +690 -0
- data/lib/google/cloud/app_engine/v1/authorized_certificates/credentials.rb +53 -0
- data/lib/google/cloud/app_engine/v1/authorized_domains.rb +50 -0
- data/lib/google/cloud/app_engine/v1/authorized_domains/client.rb +380 -0
- data/lib/google/cloud/app_engine/v1/authorized_domains/credentials.rb +53 -0
- data/lib/google/cloud/app_engine/v1/domain_mappings.rb +49 -0
- data/lib/google/cloud/app_engine/v1/domain_mappings/client.rb +705 -0
- data/lib/google/cloud/app_engine/v1/domain_mappings/credentials.rb +53 -0
- data/lib/google/cloud/app_engine/v1/domain_mappings/operations.rb +655 -0
- data/lib/google/cloud/app_engine/v1/firewall.rb +57 -0
- data/lib/google/cloud/app_engine/v1/firewall/client.rb +783 -0
- data/lib/google/cloud/app_engine/v1/firewall/credentials.rb +53 -0
- data/lib/google/cloud/app_engine/v1/instances.rb +49 -0
- data/lib/google/cloud/app_engine/v1/instances/client.rb +644 -0
- data/lib/google/cloud/app_engine/v1/instances/credentials.rb +53 -0
- data/lib/google/cloud/app_engine/v1/instances/operations.rb +655 -0
- data/lib/google/cloud/app_engine/v1/services.rb +49 -0
- data/lib/google/cloud/app_engine/v1/services/client.rb +629 -0
- data/lib/google/cloud/app_engine/v1/services/credentials.rb +53 -0
- data/lib/google/cloud/app_engine/v1/services/operations.rb +655 -0
- data/lib/google/cloud/app_engine/v1/version.rb +28 -0
- data/lib/google/cloud/app_engine/v1/versions.rb +49 -0
- data/lib/google/cloud/app_engine/v1/versions/client.rb +738 -0
- data/lib/google/cloud/app_engine/v1/versions/credentials.rb +53 -0
- data/lib/google/cloud/app_engine/v1/versions/operations.rb +655 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/resource.rb +283 -0
- data/proto_docs/google/appengine/v1/app_yaml.rb +379 -0
- data/proto_docs/google/appengine/v1/appengine.rb +639 -0
- data/proto_docs/google/appengine/v1/application.rb +192 -0
- data/proto_docs/google/appengine/v1/audit_data.rb +56 -0
- data/proto_docs/google/appengine/v1/certificate.rb +161 -0
- data/proto_docs/google/appengine/v1/deploy.rb +130 -0
- data/proto_docs/google/appengine/v1/domain.rb +42 -0
- data/proto_docs/google/appengine/v1/domain_mapping.rb +127 -0
- data/proto_docs/google/appengine/v1/firewall.rb +72 -0
- data/proto_docs/google/appengine/v1/instance.rb +98 -0
- data/proto_docs/google/appengine/v1/location.rb +38 -0
- data/proto_docs/google/appengine/v1/operation.rb +67 -0
- data/proto_docs/google/appengine/v1/service.rb +100 -0
- data/proto_docs/google/appengine/v1/version.rb +597 -0
- data/proto_docs/google/longrunning/operations.rb +164 -0
- data/proto_docs/google/protobuf/any.rb +141 -0
- data/proto_docs/google/protobuf/duration.rb +98 -0
- data/proto_docs/google/protobuf/empty.rb +36 -0
- data/proto_docs/google/protobuf/field_mask.rb +229 -0
- data/proto_docs/google/protobuf/timestamp.rb +129 -0
- data/proto_docs/google/rpc/status.rb +46 -0
- metadata +261 -0
@@ -0,0 +1,53 @@
|
|
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
|
+
require "googleauth"
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Cloud
|
23
|
+
module AppEngine
|
24
|
+
module V1
|
25
|
+
module AuthorizedCertificates
|
26
|
+
# Credentials for the AuthorizedCertificates API.
|
27
|
+
class Credentials < ::Google::Auth::Credentials
|
28
|
+
self.scope = [
|
29
|
+
"https://www.googleapis.com/auth/appengine.admin",
|
30
|
+
"https://www.googleapis.com/auth/cloud-platform",
|
31
|
+
"https://www.googleapis.com/auth/cloud-platform.read-only"
|
32
|
+
]
|
33
|
+
self.env_vars = [
|
34
|
+
"APP_ENGINE_CREDENTIALS",
|
35
|
+
"APP_ENGINE_KEYFILE",
|
36
|
+
"GOOGLE_CLOUD_CREDENTIALS",
|
37
|
+
"GOOGLE_CLOUD_KEYFILE",
|
38
|
+
"GCLOUD_KEYFILE",
|
39
|
+
"APP_ENGINE_CREDENTIALS_JSON",
|
40
|
+
"APP_ENGINE_KEYFILE_JSON",
|
41
|
+
"GOOGLE_CLOUD_CREDENTIALS_JSON",
|
42
|
+
"GOOGLE_CLOUD_KEYFILE_JSON",
|
43
|
+
"GCLOUD_KEYFILE_JSON"
|
44
|
+
]
|
45
|
+
self.paths = [
|
46
|
+
"~/.config/google_cloud/application_default_credentials.json"
|
47
|
+
]
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
@@ -0,0 +1,50 @@
|
|
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
|
+
require "gapic/common"
|
20
|
+
require "gapic/config"
|
21
|
+
require "gapic/config/method"
|
22
|
+
|
23
|
+
require "google/cloud/app_engine/v1/version"
|
24
|
+
|
25
|
+
require "google/cloud/app_engine/v1/authorized_domains/credentials"
|
26
|
+
require "google/cloud/app_engine/v1/authorized_domains/client"
|
27
|
+
|
28
|
+
module Google
|
29
|
+
module Cloud
|
30
|
+
module AppEngine
|
31
|
+
module V1
|
32
|
+
##
|
33
|
+
# Manages domains a user is authorized to administer. To authorize use of a
|
34
|
+
# domain, verify ownership via
|
35
|
+
# [Webmaster Central](https://www.google.com/webmasters/verification/home).
|
36
|
+
#
|
37
|
+
# To load this service and instantiate a client:
|
38
|
+
#
|
39
|
+
# require "google/cloud/app_engine/v1/authorized_domains"
|
40
|
+
# client = ::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client.new
|
41
|
+
#
|
42
|
+
module AuthorizedDomains
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
helper_path = ::File.join __dir__, "authorized_domains", "helpers.rb"
|
50
|
+
require "google/cloud/app_engine/v1/authorized_domains/helpers" if ::File.file? helper_path
|
@@ -0,0 +1,380 @@
|
|
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
|
+
require "google/cloud/errors"
|
20
|
+
require "google/appengine/v1/appengine_pb"
|
21
|
+
|
22
|
+
module Google
|
23
|
+
module Cloud
|
24
|
+
module AppEngine
|
25
|
+
module V1
|
26
|
+
module AuthorizedDomains
|
27
|
+
##
|
28
|
+
# Client for the AuthorizedDomains service.
|
29
|
+
#
|
30
|
+
# Manages domains a user is authorized to administer. To authorize use of a
|
31
|
+
# domain, verify ownership via
|
32
|
+
# [Webmaster Central](https://www.google.com/webmasters/verification/home).
|
33
|
+
#
|
34
|
+
class Client
|
35
|
+
# @private
|
36
|
+
attr_reader :authorized_domains_stub
|
37
|
+
|
38
|
+
##
|
39
|
+
# Configure the AuthorizedDomains Client class.
|
40
|
+
#
|
41
|
+
# See {::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client::Configuration}
|
42
|
+
# for a description of the configuration fields.
|
43
|
+
#
|
44
|
+
# ## Example
|
45
|
+
#
|
46
|
+
# To modify the configuration for all AuthorizedDomains clients:
|
47
|
+
#
|
48
|
+
# ::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client.configure do |config|
|
49
|
+
# config.timeout = 10.0
|
50
|
+
# end
|
51
|
+
#
|
52
|
+
# @yield [config] Configure the Client client.
|
53
|
+
# @yieldparam config [Client::Configuration]
|
54
|
+
#
|
55
|
+
# @return [Client::Configuration]
|
56
|
+
#
|
57
|
+
def self.configure
|
58
|
+
@configure ||= begin
|
59
|
+
namespace = ["Google", "Cloud", "AppEngine", "V1"]
|
60
|
+
parent_config = while namespace.any?
|
61
|
+
parent_name = namespace.join "::"
|
62
|
+
parent_const = const_get parent_name
|
63
|
+
break parent_const.configure if parent_const&.respond_to? :configure
|
64
|
+
namespace.pop
|
65
|
+
end
|
66
|
+
default_config = Client::Configuration.new parent_config
|
67
|
+
|
68
|
+
default_config
|
69
|
+
end
|
70
|
+
yield @configure if block_given?
|
71
|
+
@configure
|
72
|
+
end
|
73
|
+
|
74
|
+
##
|
75
|
+
# Configure the AuthorizedDomains Client instance.
|
76
|
+
#
|
77
|
+
# The configuration is set to the derived mode, meaning that values can be changed,
|
78
|
+
# but structural changes (adding new fields, etc.) are not allowed. Structural changes
|
79
|
+
# should be made on {Client.configure}.
|
80
|
+
#
|
81
|
+
# See {::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client::Configuration}
|
82
|
+
# for a description of the configuration fields.
|
83
|
+
#
|
84
|
+
# @yield [config] Configure the Client client.
|
85
|
+
# @yieldparam config [Client::Configuration]
|
86
|
+
#
|
87
|
+
# @return [Client::Configuration]
|
88
|
+
#
|
89
|
+
def configure
|
90
|
+
yield @config if block_given?
|
91
|
+
@config
|
92
|
+
end
|
93
|
+
|
94
|
+
##
|
95
|
+
# Create a new AuthorizedDomains client object.
|
96
|
+
#
|
97
|
+
# ## Examples
|
98
|
+
#
|
99
|
+
# To create a new AuthorizedDomains client with the default
|
100
|
+
# configuration:
|
101
|
+
#
|
102
|
+
# client = ::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client.new
|
103
|
+
#
|
104
|
+
# To create a new AuthorizedDomains client with a custom
|
105
|
+
# configuration:
|
106
|
+
#
|
107
|
+
# client = ::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client.new do |config|
|
108
|
+
# config.timeout = 10.0
|
109
|
+
# end
|
110
|
+
#
|
111
|
+
# @yield [config] Configure the AuthorizedDomains client.
|
112
|
+
# @yieldparam config [Client::Configuration]
|
113
|
+
#
|
114
|
+
def initialize
|
115
|
+
# These require statements are intentionally placed here to initialize
|
116
|
+
# the gRPC module only when it's required.
|
117
|
+
# See https://github.com/googleapis/toolkit/issues/446
|
118
|
+
require "gapic/grpc"
|
119
|
+
require "google/appengine/v1/appengine_services_pb"
|
120
|
+
|
121
|
+
# Create the configuration object
|
122
|
+
@config = Configuration.new Client.configure
|
123
|
+
|
124
|
+
# Yield the configuration if needed
|
125
|
+
yield @config if block_given?
|
126
|
+
|
127
|
+
# Create credentials
|
128
|
+
credentials = @config.credentials
|
129
|
+
# Use self-signed JWT if the scope and endpoint are unchanged from default,
|
130
|
+
# 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 &&
|
133
|
+
!@config.endpoint.split(".").first.include?("-")
|
134
|
+
credentials ||= Credentials.default scope: @config.scope,
|
135
|
+
enable_self_signed_jwt: enable_self_signed_jwt
|
136
|
+
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
137
|
+
credentials = Credentials.new credentials, scope: @config.scope
|
138
|
+
end
|
139
|
+
@quota_project_id = @config.quota_project
|
140
|
+
@quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id
|
141
|
+
|
142
|
+
@authorized_domains_stub = ::Gapic::ServiceStub.new(
|
143
|
+
::Google::Cloud::AppEngine::V1::AuthorizedDomains::Stub,
|
144
|
+
credentials: credentials,
|
145
|
+
endpoint: @config.endpoint,
|
146
|
+
channel_args: @config.channel_args,
|
147
|
+
interceptors: @config.interceptors
|
148
|
+
)
|
149
|
+
end
|
150
|
+
|
151
|
+
# Service calls
|
152
|
+
|
153
|
+
##
|
154
|
+
# Lists all domains the user is authorized to administer.
|
155
|
+
#
|
156
|
+
# @overload list_authorized_domains(request, options = nil)
|
157
|
+
# Pass arguments to `list_authorized_domains` via a request object, either of type
|
158
|
+
# {::Google::Cloud::AppEngine::V1::ListAuthorizedDomainsRequest} or an equivalent Hash.
|
159
|
+
#
|
160
|
+
# @param request [::Google::Cloud::AppEngine::V1::ListAuthorizedDomainsRequest, ::Hash]
|
161
|
+
# A request object representing the call parameters. Required. To specify no
|
162
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
163
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
164
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
165
|
+
#
|
166
|
+
# @overload list_authorized_domains(parent: nil, page_size: nil, page_token: nil)
|
167
|
+
# Pass arguments to `list_authorized_domains` via keyword arguments. Note that at
|
168
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
169
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
170
|
+
#
|
171
|
+
# @param parent [::String]
|
172
|
+
# Name of the parent Application resource. Example: `apps/myapp`.
|
173
|
+
# @param page_size [::Integer]
|
174
|
+
# Maximum results to return per page.
|
175
|
+
# @param page_token [::String]
|
176
|
+
# Continuation token for fetching the next page of results.
|
177
|
+
#
|
178
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
179
|
+
# @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::AppEngine::V1::AuthorizedDomain>]
|
180
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
181
|
+
#
|
182
|
+
# @return [::Gapic::PagedEnumerable<::Google::Cloud::AppEngine::V1::AuthorizedDomain>]
|
183
|
+
#
|
184
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
185
|
+
#
|
186
|
+
def list_authorized_domains request, options = nil
|
187
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
188
|
+
|
189
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::AppEngine::V1::ListAuthorizedDomainsRequest
|
190
|
+
|
191
|
+
# Converts hash and nil to an options object
|
192
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
193
|
+
|
194
|
+
# Customize the options with defaults
|
195
|
+
metadata = @config.rpcs.list_authorized_domains.metadata.to_h
|
196
|
+
|
197
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
198
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
199
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
200
|
+
gapic_version: ::Google::Cloud::AppEngine::V1::VERSION
|
201
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
202
|
+
|
203
|
+
header_params = {
|
204
|
+
"parent" => request.parent
|
205
|
+
}
|
206
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
207
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
208
|
+
|
209
|
+
options.apply_defaults timeout: @config.rpcs.list_authorized_domains.timeout,
|
210
|
+
metadata: metadata,
|
211
|
+
retry_policy: @config.rpcs.list_authorized_domains.retry_policy
|
212
|
+
options.apply_defaults metadata: @config.metadata,
|
213
|
+
retry_policy: @config.retry_policy
|
214
|
+
|
215
|
+
@authorized_domains_stub.call_rpc :list_authorized_domains, request, options: options do |response, operation|
|
216
|
+
response = ::Gapic::PagedEnumerable.new @authorized_domains_stub, :list_authorized_domains, request, response, operation, options
|
217
|
+
yield response, operation if block_given?
|
218
|
+
return response
|
219
|
+
end
|
220
|
+
rescue ::GRPC::BadStatus => e
|
221
|
+
raise ::Google::Cloud::Error.from_error(e)
|
222
|
+
end
|
223
|
+
|
224
|
+
##
|
225
|
+
# Configuration class for the AuthorizedDomains API.
|
226
|
+
#
|
227
|
+
# This class represents the configuration for AuthorizedDomains,
|
228
|
+
# providing control over timeouts, retry behavior, logging, transport
|
229
|
+
# parameters, and other low-level controls. Certain parameters can also be
|
230
|
+
# applied individually to specific RPCs. See
|
231
|
+
# {::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client::Configuration::Rpcs}
|
232
|
+
# for a list of RPCs that can be configured independently.
|
233
|
+
#
|
234
|
+
# Configuration can be applied globally to all clients, or to a single client
|
235
|
+
# on construction.
|
236
|
+
#
|
237
|
+
# # Examples
|
238
|
+
#
|
239
|
+
# To modify the global config, setting the timeout for list_authorized_domains
|
240
|
+
# to 20 seconds, and all remaining timeouts to 10 seconds:
|
241
|
+
#
|
242
|
+
# ::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client.configure do |config|
|
243
|
+
# config.timeout = 10.0
|
244
|
+
# config.rpcs.list_authorized_domains.timeout = 20.0
|
245
|
+
# end
|
246
|
+
#
|
247
|
+
# To apply the above configuration only to a new client:
|
248
|
+
#
|
249
|
+
# client = ::Google::Cloud::AppEngine::V1::AuthorizedDomains::Client.new do |config|
|
250
|
+
# config.timeout = 10.0
|
251
|
+
# config.rpcs.list_authorized_domains.timeout = 20.0
|
252
|
+
# end
|
253
|
+
#
|
254
|
+
# @!attribute [rw] endpoint
|
255
|
+
# The hostname or hostname:port of the service endpoint.
|
256
|
+
# Defaults to `"appengine.googleapis.com"`.
|
257
|
+
# @return [::String]
|
258
|
+
# @!attribute [rw] credentials
|
259
|
+
# Credentials to send with calls. You may provide any of the following types:
|
260
|
+
# * (`String`) The path to a service account key file in JSON format
|
261
|
+
# * (`Hash`) A service account key as a Hash
|
262
|
+
# * (`Google::Auth::Credentials`) A googleauth credentials object
|
263
|
+
# (see the [googleauth docs](https://googleapis.dev/ruby/googleauth/latest/index.html))
|
264
|
+
# * (`Signet::OAuth2::Client`) A signet oauth2 client object
|
265
|
+
# (see the [signet docs](https://googleapis.dev/ruby/signet/latest/Signet/OAuth2/Client.html))
|
266
|
+
# * (`GRPC::Core::Channel`) a gRPC channel with included credentials
|
267
|
+
# * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
|
268
|
+
# * (`nil`) indicating no credentials
|
269
|
+
# @return [::Object]
|
270
|
+
# @!attribute [rw] scope
|
271
|
+
# The OAuth scopes
|
272
|
+
# @return [::Array<::String>]
|
273
|
+
# @!attribute [rw] lib_name
|
274
|
+
# The library name as recorded in instrumentation and logging
|
275
|
+
# @return [::String]
|
276
|
+
# @!attribute [rw] lib_version
|
277
|
+
# The library version as recorded in instrumentation and logging
|
278
|
+
# @return [::String]
|
279
|
+
# @!attribute [rw] channel_args
|
280
|
+
# Extra parameters passed to the gRPC channel. Note: this is ignored if a
|
281
|
+
# `GRPC::Core::Channel` object is provided as the credential.
|
282
|
+
# @return [::Hash]
|
283
|
+
# @!attribute [rw] interceptors
|
284
|
+
# An array of interceptors that are run before calls are executed.
|
285
|
+
# @return [::Array<::GRPC::ClientInterceptor>]
|
286
|
+
# @!attribute [rw] timeout
|
287
|
+
# The call timeout in seconds.
|
288
|
+
# @return [::Numeric]
|
289
|
+
# @!attribute [rw] metadata
|
290
|
+
# Additional gRPC headers to be sent with the call.
|
291
|
+
# @return [::Hash{::Symbol=>::String}]
|
292
|
+
# @!attribute [rw] retry_policy
|
293
|
+
# The retry policy. The value is a hash with the following keys:
|
294
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
295
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
296
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
297
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
298
|
+
# trigger a retry.
|
299
|
+
# @return [::Hash]
|
300
|
+
# @!attribute [rw] quota_project
|
301
|
+
# A separate project against which to charge quota.
|
302
|
+
# @return [::String]
|
303
|
+
#
|
304
|
+
class Configuration
|
305
|
+
extend ::Gapic::Config
|
306
|
+
|
307
|
+
config_attr :endpoint, "appengine.googleapis.com", ::String
|
308
|
+
config_attr :credentials, nil do |value|
|
309
|
+
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
310
|
+
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
311
|
+
allowed.any? { |klass| klass === value }
|
312
|
+
end
|
313
|
+
config_attr :scope, nil, ::String, ::Array, nil
|
314
|
+
config_attr :lib_name, nil, ::String, nil
|
315
|
+
config_attr :lib_version, nil, ::String, nil
|
316
|
+
config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil)
|
317
|
+
config_attr :interceptors, nil, ::Array, nil
|
318
|
+
config_attr :timeout, nil, ::Numeric, nil
|
319
|
+
config_attr :metadata, nil, ::Hash, nil
|
320
|
+
config_attr :retry_policy, nil, ::Hash, ::Proc, nil
|
321
|
+
config_attr :quota_project, nil, ::String, nil
|
322
|
+
|
323
|
+
# @private
|
324
|
+
def initialize parent_config = nil
|
325
|
+
@parent_config = parent_config unless parent_config.nil?
|
326
|
+
|
327
|
+
yield self if block_given?
|
328
|
+
end
|
329
|
+
|
330
|
+
##
|
331
|
+
# Configurations for individual RPCs
|
332
|
+
# @return [Rpcs]
|
333
|
+
#
|
334
|
+
def rpcs
|
335
|
+
@rpcs ||= begin
|
336
|
+
parent_rpcs = nil
|
337
|
+
parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config&.respond_to?(:rpcs)
|
338
|
+
Rpcs.new parent_rpcs
|
339
|
+
end
|
340
|
+
end
|
341
|
+
|
342
|
+
##
|
343
|
+
# Configuration RPC class for the AuthorizedDomains API.
|
344
|
+
#
|
345
|
+
# Includes fields providing the configuration for each RPC in this service.
|
346
|
+
# Each configuration object is of type `Gapic::Config::Method` and includes
|
347
|
+
# the following configuration fields:
|
348
|
+
#
|
349
|
+
# * `timeout` (*type:* `Numeric`) - The call timeout in seconds
|
350
|
+
# * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers
|
351
|
+
# * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
|
352
|
+
# include the following keys:
|
353
|
+
# * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds.
|
354
|
+
# * `:max_delay` (*type:* `Numeric`) - The max delay in seconds.
|
355
|
+
# * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier.
|
356
|
+
# * `:retry_codes` (*type:* `Array<String>`) - The error codes that should
|
357
|
+
# trigger a retry.
|
358
|
+
#
|
359
|
+
class Rpcs
|
360
|
+
##
|
361
|
+
# RPC-specific configuration for `list_authorized_domains`
|
362
|
+
# @return [::Gapic::Config::Method]
|
363
|
+
#
|
364
|
+
attr_reader :list_authorized_domains
|
365
|
+
|
366
|
+
# @private
|
367
|
+
def initialize parent_rpcs = nil
|
368
|
+
list_authorized_domains_config = parent_rpcs&.list_authorized_domains if parent_rpcs&.respond_to? :list_authorized_domains
|
369
|
+
@list_authorized_domains = ::Gapic::Config::Method.new list_authorized_domains_config
|
370
|
+
|
371
|
+
yield self if block_given?
|
372
|
+
end
|
373
|
+
end
|
374
|
+
end
|
375
|
+
end
|
376
|
+
end
|
377
|
+
end
|
378
|
+
end
|
379
|
+
end
|
380
|
+
end
|