rcloadenv 0.0.1.rc1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,280 @@
1
+ # Copyright 2015 Google Inc.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'date'
16
+ require 'google/apis/core/base_service'
17
+ require 'google/apis/core/json_representation'
18
+ require 'google/apis/core/hashable'
19
+ require 'google/apis/errors'
20
+
21
+ module Google
22
+ module Apis
23
+ module RuntimeconfigV1beta1
24
+
25
+ class SetIamPolicyRequest
26
+ class Representation < Google::Apis::Core::JsonRepresentation; end
27
+
28
+ include Google::Apis::Core::JsonObjectSupport
29
+ end
30
+
31
+ class Status
32
+ class Representation < Google::Apis::Core::JsonRepresentation; end
33
+
34
+ include Google::Apis::Core::JsonObjectSupport
35
+ end
36
+
37
+ class Binding
38
+ class Representation < Google::Apis::Core::JsonRepresentation; end
39
+
40
+ include Google::Apis::Core::JsonObjectSupport
41
+ end
42
+
43
+ class Empty
44
+ class Representation < Google::Apis::Core::JsonRepresentation; end
45
+
46
+ include Google::Apis::Core::JsonObjectSupport
47
+ end
48
+
49
+ class Cardinality
50
+ class Representation < Google::Apis::Core::JsonRepresentation; end
51
+
52
+ include Google::Apis::Core::JsonObjectSupport
53
+ end
54
+
55
+ class ListConfigsResponse
56
+ class Representation < Google::Apis::Core::JsonRepresentation; end
57
+
58
+ include Google::Apis::Core::JsonObjectSupport
59
+ end
60
+
61
+ class EndCondition
62
+ class Representation < Google::Apis::Core::JsonRepresentation; end
63
+
64
+ include Google::Apis::Core::JsonObjectSupport
65
+ end
66
+
67
+ class TestIamPermissionsResponse
68
+ class Representation < Google::Apis::Core::JsonRepresentation; end
69
+
70
+ include Google::Apis::Core::JsonObjectSupport
71
+ end
72
+
73
+ class ListVariablesResponse
74
+ class Representation < Google::Apis::Core::JsonRepresentation; end
75
+
76
+ include Google::Apis::Core::JsonObjectSupport
77
+ end
78
+
79
+ class RuntimeConfig
80
+ class Representation < Google::Apis::Core::JsonRepresentation; end
81
+
82
+ include Google::Apis::Core::JsonObjectSupport
83
+ end
84
+
85
+ class WatchVariableRequest
86
+ class Representation < Google::Apis::Core::JsonRepresentation; end
87
+
88
+ include Google::Apis::Core::JsonObjectSupport
89
+ end
90
+
91
+ class ListWaitersResponse
92
+ class Representation < Google::Apis::Core::JsonRepresentation; end
93
+
94
+ include Google::Apis::Core::JsonObjectSupport
95
+ end
96
+
97
+ class TestIamPermissionsRequest
98
+ class Representation < Google::Apis::Core::JsonRepresentation; end
99
+
100
+ include Google::Apis::Core::JsonObjectSupport
101
+ end
102
+
103
+ class Waiter
104
+ class Representation < Google::Apis::Core::JsonRepresentation; end
105
+
106
+ include Google::Apis::Core::JsonObjectSupport
107
+ end
108
+
109
+ class Policy
110
+ class Representation < Google::Apis::Core::JsonRepresentation; end
111
+
112
+ include Google::Apis::Core::JsonObjectSupport
113
+ end
114
+
115
+ class Variable
116
+ class Representation < Google::Apis::Core::JsonRepresentation; end
117
+
118
+ include Google::Apis::Core::JsonObjectSupport
119
+ end
120
+
121
+ class Operation
122
+ class Representation < Google::Apis::Core::JsonRepresentation; end
123
+
124
+ include Google::Apis::Core::JsonObjectSupport
125
+ end
126
+
127
+ class SetIamPolicyRequest
128
+ # @private
129
+ class Representation < Google::Apis::Core::JsonRepresentation
130
+ property :policy, as: 'policy', class: Google::Apis::RuntimeconfigV1beta1::Policy, decorator: Google::Apis::RuntimeconfigV1beta1::Policy::Representation
131
+
132
+ end
133
+ end
134
+
135
+ class Status
136
+ # @private
137
+ class Representation < Google::Apis::Core::JsonRepresentation
138
+ collection :details, as: 'details'
139
+ property :code, as: 'code'
140
+ property :message, as: 'message'
141
+ end
142
+ end
143
+
144
+ class Binding
145
+ # @private
146
+ class Representation < Google::Apis::Core::JsonRepresentation
147
+ collection :members, as: 'members'
148
+ property :role, as: 'role'
149
+ end
150
+ end
151
+
152
+ class Empty
153
+ # @private
154
+ class Representation < Google::Apis::Core::JsonRepresentation
155
+ end
156
+ end
157
+
158
+ class Cardinality
159
+ # @private
160
+ class Representation < Google::Apis::Core::JsonRepresentation
161
+ property :number, as: 'number'
162
+ property :path, as: 'path'
163
+ end
164
+ end
165
+
166
+ class ListConfigsResponse
167
+ # @private
168
+ class Representation < Google::Apis::Core::JsonRepresentation
169
+ collection :configs, as: 'configs', class: Google::Apis::RuntimeconfigV1beta1::RuntimeConfig, decorator: Google::Apis::RuntimeconfigV1beta1::RuntimeConfig::Representation
170
+
171
+ property :next_page_token, as: 'nextPageToken'
172
+ end
173
+ end
174
+
175
+ class EndCondition
176
+ # @private
177
+ class Representation < Google::Apis::Core::JsonRepresentation
178
+ property :cardinality, as: 'cardinality', class: Google::Apis::RuntimeconfigV1beta1::Cardinality, decorator: Google::Apis::RuntimeconfigV1beta1::Cardinality::Representation
179
+
180
+ end
181
+ end
182
+
183
+ class TestIamPermissionsResponse
184
+ # @private
185
+ class Representation < Google::Apis::Core::JsonRepresentation
186
+ collection :permissions, as: 'permissions'
187
+ end
188
+ end
189
+
190
+ class ListVariablesResponse
191
+ # @private
192
+ class Representation < Google::Apis::Core::JsonRepresentation
193
+ property :next_page_token, as: 'nextPageToken'
194
+ collection :variables, as: 'variables', class: Google::Apis::RuntimeconfigV1beta1::Variable, decorator: Google::Apis::RuntimeconfigV1beta1::Variable::Representation
195
+
196
+ end
197
+ end
198
+
199
+ class RuntimeConfig
200
+ # @private
201
+ class Representation < Google::Apis::Core::JsonRepresentation
202
+ property :name, as: 'name'
203
+ property :description, as: 'description'
204
+ end
205
+ end
206
+
207
+ class WatchVariableRequest
208
+ # @private
209
+ class Representation < Google::Apis::Core::JsonRepresentation
210
+ property :newer_than, as: 'newerThan'
211
+ end
212
+ end
213
+
214
+ class ListWaitersResponse
215
+ # @private
216
+ class Representation < Google::Apis::Core::JsonRepresentation
217
+ property :next_page_token, as: 'nextPageToken'
218
+ collection :waiters, as: 'waiters', class: Google::Apis::RuntimeconfigV1beta1::Waiter, decorator: Google::Apis::RuntimeconfigV1beta1::Waiter::Representation
219
+
220
+ end
221
+ end
222
+
223
+ class TestIamPermissionsRequest
224
+ # @private
225
+ class Representation < Google::Apis::Core::JsonRepresentation
226
+ collection :permissions, as: 'permissions'
227
+ end
228
+ end
229
+
230
+ class Waiter
231
+ # @private
232
+ class Representation < Google::Apis::Core::JsonRepresentation
233
+ property :error, as: 'error', class: Google::Apis::RuntimeconfigV1beta1::Status, decorator: Google::Apis::RuntimeconfigV1beta1::Status::Representation
234
+
235
+ property :failure, as: 'failure', class: Google::Apis::RuntimeconfigV1beta1::EndCondition, decorator: Google::Apis::RuntimeconfigV1beta1::EndCondition::Representation
236
+
237
+ property :success, as: 'success', class: Google::Apis::RuntimeconfigV1beta1::EndCondition, decorator: Google::Apis::RuntimeconfigV1beta1::EndCondition::Representation
238
+
239
+ property :done, as: 'done'
240
+ property :create_time, as: 'createTime'
241
+ property :timeout, as: 'timeout'
242
+ property :name, as: 'name'
243
+ end
244
+ end
245
+
246
+ class Policy
247
+ # @private
248
+ class Representation < Google::Apis::Core::JsonRepresentation
249
+ property :etag, :base64 => true, as: 'etag'
250
+ property :version, as: 'version'
251
+ collection :bindings, as: 'bindings', class: Google::Apis::RuntimeconfigV1beta1::Binding, decorator: Google::Apis::RuntimeconfigV1beta1::Binding::Representation
252
+
253
+ end
254
+ end
255
+
256
+ class Variable
257
+ # @private
258
+ class Representation < Google::Apis::Core::JsonRepresentation
259
+ property :value, :base64 => true, as: 'value'
260
+ property :state, as: 'state'
261
+ property :update_time, as: 'updateTime'
262
+ property :name, as: 'name'
263
+ property :text, as: 'text'
264
+ end
265
+ end
266
+
267
+ class Operation
268
+ # @private
269
+ class Representation < Google::Apis::Core::JsonRepresentation
270
+ hash :metadata, as: 'metadata'
271
+ property :done, as: 'done'
272
+ hash :response, as: 'response'
273
+ property :name, as: 'name'
274
+ property :error, as: 'error', class: Google::Apis::RuntimeconfigV1beta1::Status, decorator: Google::Apis::RuntimeconfigV1beta1::Status::Representation
275
+
276
+ end
277
+ end
278
+ end
279
+ end
280
+ end
@@ -0,0 +1,903 @@
1
+ # Copyright 2015 Google Inc.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'google/apis/core/base_service'
16
+ require 'google/apis/core/json_representation'
17
+ require 'google/apis/core/hashable'
18
+ require 'google/apis/errors'
19
+
20
+ module Google
21
+ module Apis
22
+ module RuntimeconfigV1beta1
23
+ # Google Cloud Runtime Configuration API
24
+ #
25
+ # The Runtime Configurator allows you to dynamically configure and expose
26
+ # variables through Google Cloud Platform. In addition, you can also set
27
+ # Watchers and Waiters that will watch for changes to your data and return based
28
+ # on certain conditions.
29
+ #
30
+ # @example
31
+ # require 'google/apis/runtimeconfig_v1beta1'
32
+ #
33
+ # Runtimeconfig = Google::Apis::RuntimeconfigV1beta1 # Alias the module
34
+ # service = Runtimeconfig::CloudRuntimeConfigService.new
35
+ #
36
+ # @see https://cloud.google.com/deployment-manager/runtime-configurator/
37
+ class CloudRuntimeConfigService < Google::Apis::Core::BaseService
38
+ # @return [String]
39
+ # API key. Your API key identifies your project and provides you with API access,
40
+ # quota, and reports. Required unless you provide an OAuth 2.0 token.
41
+ attr_accessor :key
42
+
43
+ # @return [String]
44
+ # Available to use for quota purposes for server-side applications. Can be any
45
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
46
+ attr_accessor :quota_user
47
+
48
+ def initialize
49
+ super('https://runtimeconfig.googleapis.com/', '')
50
+ @batch_path = 'batch'
51
+ end
52
+
53
+ # Deletes a RuntimeConfig resource.
54
+ # @param [String] name
55
+ # The RuntimeConfig resource to delete, in the format:
56
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`
57
+ # @param [String] fields
58
+ # Selector specifying which fields to include in a partial response.
59
+ # @param [String] quota_user
60
+ # Available to use for quota purposes for server-side applications. Can be any
61
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
62
+ # @param [Google::Apis::RequestOptions] options
63
+ # Request-specific options
64
+ #
65
+ # @yield [result, err] Result & error if block supplied
66
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Empty] parsed result object
67
+ # @yieldparam err [StandardError] error object if request failed
68
+ #
69
+ # @return [Google::Apis::RuntimeconfigV1beta1::Empty]
70
+ #
71
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
72
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
73
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
74
+ def delete_project_config(name, fields: nil, quota_user: nil, options: nil, &block)
75
+ command = make_simple_command(:delete, 'v1beta1/{+name}', options)
76
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Empty::Representation
77
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Empty
78
+ command.params['name'] = name unless name.nil?
79
+ command.query['fields'] = fields unless fields.nil?
80
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
81
+ execute_or_queue_command(command, &block)
82
+ end
83
+
84
+ # Lists all the RuntimeConfig resources within project.
85
+ # @param [String] parent
86
+ # The [project ID](https://support.google.com/cloud/answer/6158840?hl=en&
87
+ # ref_topic=6158848)
88
+ # for this request, in the format `projects/[PROJECT_ID]`.
89
+ # @param [String] page_token
90
+ # Specifies a page token to use. Set `pageToken` to a `nextPageToken`
91
+ # returned by a previous list request to get the next page of results.
92
+ # @param [Fixnum] page_size
93
+ # Specifies the number of results to return per page. If there are fewer
94
+ # elements than the specified number, returns all elements.
95
+ # @param [String] fields
96
+ # Selector specifying which fields to include in a partial response.
97
+ # @param [String] quota_user
98
+ # Available to use for quota purposes for server-side applications. Can be any
99
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
100
+ # @param [Google::Apis::RequestOptions] options
101
+ # Request-specific options
102
+ #
103
+ # @yield [result, err] Result & error if block supplied
104
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::ListConfigsResponse] parsed result object
105
+ # @yieldparam err [StandardError] error object if request failed
106
+ #
107
+ # @return [Google::Apis::RuntimeconfigV1beta1::ListConfigsResponse]
108
+ #
109
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
110
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
111
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
112
+ def list_project_configs(parent, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
113
+ command = make_simple_command(:get, 'v1beta1/{+parent}/configs', options)
114
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::ListConfigsResponse::Representation
115
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::ListConfigsResponse
116
+ command.params['parent'] = parent unless parent.nil?
117
+ command.query['pageToken'] = page_token unless page_token.nil?
118
+ command.query['pageSize'] = page_size unless page_size.nil?
119
+ command.query['fields'] = fields unless fields.nil?
120
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
121
+ execute_or_queue_command(command, &block)
122
+ end
123
+
124
+ # Sets the access control policy on the specified resource. Replaces any
125
+ # existing policy.
126
+ # @param [String] resource
127
+ # REQUIRED: The resource for which the policy is being specified.
128
+ # See the operation documentation for the appropriate value for this field.
129
+ # @param [Google::Apis::RuntimeconfigV1beta1::SetIamPolicyRequest] set_iam_policy_request_object
130
+ # @param [String] fields
131
+ # Selector specifying which fields to include in a partial response.
132
+ # @param [String] quota_user
133
+ # Available to use for quota purposes for server-side applications. Can be any
134
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
135
+ # @param [Google::Apis::RequestOptions] options
136
+ # Request-specific options
137
+ #
138
+ # @yield [result, err] Result & error if block supplied
139
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Policy] parsed result object
140
+ # @yieldparam err [StandardError] error object if request failed
141
+ #
142
+ # @return [Google::Apis::RuntimeconfigV1beta1::Policy]
143
+ #
144
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
145
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
146
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
147
+ def set_config_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
148
+ command = make_simple_command(:post, 'v1beta1/{+resource}:setIamPolicy', options)
149
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::SetIamPolicyRequest::Representation
150
+ command.request_object = set_iam_policy_request_object
151
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Policy::Representation
152
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Policy
153
+ command.params['resource'] = resource unless resource.nil?
154
+ command.query['fields'] = fields unless fields.nil?
155
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
156
+ execute_or_queue_command(command, &block)
157
+ end
158
+
159
+ # Creates a new RuntimeConfig resource. The configuration name must be
160
+ # unique within project.
161
+ # @param [String] parent
162
+ # The [project ID](https://support.google.com/cloud/answer/6158840?hl=en&
163
+ # ref_topic=6158848)
164
+ # for this request, in the format `projects/[PROJECT_ID]`.
165
+ # @param [Google::Apis::RuntimeconfigV1beta1::RuntimeConfig] runtime_config_object
166
+ # @param [String] request_id
167
+ # An optional but recommended unique `request_id`. If the server
168
+ # receives two `create()` requests with the same
169
+ # `request_id`, then the second request will be ignored and the
170
+ # first resource created and stored in the backend is returned.
171
+ # Empty `request_id` fields are ignored.
172
+ # It is responsibility of the client to ensure uniqueness of the
173
+ # `request_id` strings.
174
+ # `request_id` strings are limited to 64 characters.
175
+ # @param [String] fields
176
+ # Selector specifying which fields to include in a partial response.
177
+ # @param [String] quota_user
178
+ # Available to use for quota purposes for server-side applications. Can be any
179
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
180
+ # @param [Google::Apis::RequestOptions] options
181
+ # Request-specific options
182
+ #
183
+ # @yield [result, err] Result & error if block supplied
184
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::RuntimeConfig] parsed result object
185
+ # @yieldparam err [StandardError] error object if request failed
186
+ #
187
+ # @return [Google::Apis::RuntimeconfigV1beta1::RuntimeConfig]
188
+ #
189
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
190
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
191
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
192
+ def create_project_config(parent, runtime_config_object = nil, request_id: nil, fields: nil, quota_user: nil, options: nil, &block)
193
+ command = make_simple_command(:post, 'v1beta1/{+parent}/configs', options)
194
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::RuntimeConfig::Representation
195
+ command.request_object = runtime_config_object
196
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::RuntimeConfig::Representation
197
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::RuntimeConfig
198
+ command.params['parent'] = parent unless parent.nil?
199
+ command.query['requestId'] = request_id unless request_id.nil?
200
+ command.query['fields'] = fields unless fields.nil?
201
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
202
+ execute_or_queue_command(command, &block)
203
+ end
204
+
205
+ # Gets the access control policy for a resource.
206
+ # Returns an empty policy if the resource exists and does not have a policy
207
+ # set.
208
+ # @param [String] resource
209
+ # REQUIRED: The resource for which the policy is being requested.
210
+ # See the operation documentation for the appropriate value for this field.
211
+ # @param [String] fields
212
+ # Selector specifying which fields to include in a partial response.
213
+ # @param [String] quota_user
214
+ # Available to use for quota purposes for server-side applications. Can be any
215
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
216
+ # @param [Google::Apis::RequestOptions] options
217
+ # Request-specific options
218
+ #
219
+ # @yield [result, err] Result & error if block supplied
220
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Policy] parsed result object
221
+ # @yieldparam err [StandardError] error object if request failed
222
+ #
223
+ # @return [Google::Apis::RuntimeconfigV1beta1::Policy]
224
+ #
225
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
226
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
227
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
228
+ def get_project_config_iam_policy(resource, fields: nil, quota_user: nil, options: nil, &block)
229
+ command = make_simple_command(:get, 'v1beta1/{+resource}:getIamPolicy', options)
230
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Policy::Representation
231
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Policy
232
+ command.params['resource'] = resource unless resource.nil?
233
+ command.query['fields'] = fields unless fields.nil?
234
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
235
+ execute_or_queue_command(command, &block)
236
+ end
237
+
238
+ # Gets information about a RuntimeConfig resource.
239
+ # @param [String] name
240
+ # The name of the RuntimeConfig resource to retrieve, in the format:
241
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`
242
+ # @param [String] fields
243
+ # Selector specifying which fields to include in a partial response.
244
+ # @param [String] quota_user
245
+ # Available to use for quota purposes for server-side applications. Can be any
246
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
247
+ # @param [Google::Apis::RequestOptions] options
248
+ # Request-specific options
249
+ #
250
+ # @yield [result, err] Result & error if block supplied
251
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::RuntimeConfig] parsed result object
252
+ # @yieldparam err [StandardError] error object if request failed
253
+ #
254
+ # @return [Google::Apis::RuntimeconfigV1beta1::RuntimeConfig]
255
+ #
256
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
257
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
258
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
259
+ def get_project_config(name, fields: nil, quota_user: nil, options: nil, &block)
260
+ command = make_simple_command(:get, 'v1beta1/{+name}', options)
261
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::RuntimeConfig::Representation
262
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::RuntimeConfig
263
+ command.params['name'] = name unless name.nil?
264
+ command.query['fields'] = fields unless fields.nil?
265
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
266
+ execute_or_queue_command(command, &block)
267
+ end
268
+
269
+ # Updates a RuntimeConfig resource. The configuration must exist beforehand.
270
+ # @param [String] name
271
+ # The name of the RuntimeConfig resource to update, in the format:
272
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`
273
+ # @param [Google::Apis::RuntimeconfigV1beta1::RuntimeConfig] runtime_config_object
274
+ # @param [String] fields
275
+ # Selector specifying which fields to include in a partial response.
276
+ # @param [String] quota_user
277
+ # Available to use for quota purposes for server-side applications. Can be any
278
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
279
+ # @param [Google::Apis::RequestOptions] options
280
+ # Request-specific options
281
+ #
282
+ # @yield [result, err] Result & error if block supplied
283
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::RuntimeConfig] parsed result object
284
+ # @yieldparam err [StandardError] error object if request failed
285
+ #
286
+ # @return [Google::Apis::RuntimeconfigV1beta1::RuntimeConfig]
287
+ #
288
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
289
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
290
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
291
+ def update_project_config(name, runtime_config_object = nil, fields: nil, quota_user: nil, options: nil, &block)
292
+ command = make_simple_command(:put, 'v1beta1/{+name}', options)
293
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::RuntimeConfig::Representation
294
+ command.request_object = runtime_config_object
295
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::RuntimeConfig::Representation
296
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::RuntimeConfig
297
+ command.params['name'] = name unless name.nil?
298
+ command.query['fields'] = fields unless fields.nil?
299
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
300
+ execute_or_queue_command(command, &block)
301
+ end
302
+
303
+ # Returns permissions that a caller has on the specified resource.
304
+ # If the resource does not exist, this will return an empty set of
305
+ # permissions, not a NOT_FOUND error.
306
+ # Note: This operation is designed to be used for building permission-aware
307
+ # UIs and command-line tools, not for authorization checking. This operation
308
+ # may "fail open" without warning.
309
+ # @param [String] resource
310
+ # REQUIRED: The resource for which the policy detail is being requested.
311
+ # See the operation documentation for the appropriate value for this field.
312
+ # @param [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsRequest] test_iam_permissions_request_object
313
+ # @param [String] fields
314
+ # Selector specifying which fields to include in a partial response.
315
+ # @param [String] quota_user
316
+ # Available to use for quota purposes for server-side applications. Can be any
317
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
318
+ # @param [Google::Apis::RequestOptions] options
319
+ # Request-specific options
320
+ #
321
+ # @yield [result, err] Result & error if block supplied
322
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse] parsed result object
323
+ # @yieldparam err [StandardError] error object if request failed
324
+ #
325
+ # @return [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse]
326
+ #
327
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
328
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
329
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
330
+ def test_config_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
331
+ command = make_simple_command(:post, 'v1beta1/{+resource}:testIamPermissions', options)
332
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsRequest::Representation
333
+ command.request_object = test_iam_permissions_request_object
334
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse::Representation
335
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse
336
+ command.params['resource'] = resource unless resource.nil?
337
+ command.query['fields'] = fields unless fields.nil?
338
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
339
+ execute_or_queue_command(command, &block)
340
+ end
341
+
342
+ # Gets information about a single variable.
343
+ # @param [String] name
344
+ # The name of the variable to return, in the format:
345
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]/variables/[VARIBLE_NAME]`
346
+ # @param [String] fields
347
+ # Selector specifying which fields to include in a partial response.
348
+ # @param [String] quota_user
349
+ # Available to use for quota purposes for server-side applications. Can be any
350
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
351
+ # @param [Google::Apis::RequestOptions] options
352
+ # Request-specific options
353
+ #
354
+ # @yield [result, err] Result & error if block supplied
355
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Variable] parsed result object
356
+ # @yieldparam err [StandardError] error object if request failed
357
+ #
358
+ # @return [Google::Apis::RuntimeconfigV1beta1::Variable]
359
+ #
360
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
361
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
362
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
363
+ def get_project_config_variable(name, fields: nil, quota_user: nil, options: nil, &block)
364
+ command = make_simple_command(:get, 'v1beta1/{+name}', options)
365
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Variable::Representation
366
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Variable
367
+ command.params['name'] = name unless name.nil?
368
+ command.query['fields'] = fields unless fields.nil?
369
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
370
+ execute_or_queue_command(command, &block)
371
+ end
372
+
373
+ # Watches a specific variable and waits for a change in the variable's value.
374
+ # When there is a change, this method returns the new value or times out.
375
+ # If a variable is deleted while being watched, the `variableState` state is
376
+ # set to `DELETED` and the method returns the last known variable `value`.
377
+ # If you set the deadline for watching to a larger value than internal timeout
378
+ # (60 seconds), the current variable value is returned and the `variableState`
379
+ # will be `VARIABLE_STATE_UNSPECIFIED`.
380
+ # To learn more about creating a watcher, read the
381
+ # [Watching a Variable for Changes](/deployment-manager/runtime-configurator/
382
+ # watching-a-variable)
383
+ # documentation.
384
+ # @param [String] name
385
+ # The name of the variable to watch, in the format:
386
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`
387
+ # @param [Google::Apis::RuntimeconfigV1beta1::WatchVariableRequest] watch_variable_request_object
388
+ # @param [String] fields
389
+ # Selector specifying which fields to include in a partial response.
390
+ # @param [String] quota_user
391
+ # Available to use for quota purposes for server-side applications. Can be any
392
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
393
+ # @param [Google::Apis::RequestOptions] options
394
+ # Request-specific options
395
+ #
396
+ # @yield [result, err] Result & error if block supplied
397
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Variable] parsed result object
398
+ # @yieldparam err [StandardError] error object if request failed
399
+ #
400
+ # @return [Google::Apis::RuntimeconfigV1beta1::Variable]
401
+ #
402
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
403
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
404
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
405
+ def watch_variable(name, watch_variable_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
406
+ command = make_simple_command(:post, 'v1beta1/{+name}:watch', options)
407
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::WatchVariableRequest::Representation
408
+ command.request_object = watch_variable_request_object
409
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Variable::Representation
410
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Variable
411
+ command.params['name'] = name unless name.nil?
412
+ command.query['fields'] = fields unless fields.nil?
413
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
414
+ execute_or_queue_command(command, &block)
415
+ end
416
+
417
+ # Updates an existing variable with a new value.
418
+ # @param [String] name
419
+ # The name of the variable to update, in the format:
420
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]/variables/[VARIABLE_NAME]`
421
+ # @param [Google::Apis::RuntimeconfigV1beta1::Variable] variable_object
422
+ # @param [String] fields
423
+ # Selector specifying which fields to include in a partial response.
424
+ # @param [String] quota_user
425
+ # Available to use for quota purposes for server-side applications. Can be any
426
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
427
+ # @param [Google::Apis::RequestOptions] options
428
+ # Request-specific options
429
+ #
430
+ # @yield [result, err] Result & error if block supplied
431
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Variable] parsed result object
432
+ # @yieldparam err [StandardError] error object if request failed
433
+ #
434
+ # @return [Google::Apis::RuntimeconfigV1beta1::Variable]
435
+ #
436
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
437
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
438
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
439
+ def update_project_config_variable(name, variable_object = nil, fields: nil, quota_user: nil, options: nil, &block)
440
+ command = make_simple_command(:put, 'v1beta1/{+name}', options)
441
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::Variable::Representation
442
+ command.request_object = variable_object
443
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Variable::Representation
444
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Variable
445
+ command.params['name'] = name unless name.nil?
446
+ command.query['fields'] = fields unless fields.nil?
447
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
448
+ execute_or_queue_command(command, &block)
449
+ end
450
+
451
+ # Returns permissions that a caller has on the specified resource.
452
+ # If the resource does not exist, this will return an empty set of
453
+ # permissions, not a NOT_FOUND error.
454
+ # Note: This operation is designed to be used for building permission-aware
455
+ # UIs and command-line tools, not for authorization checking. This operation
456
+ # may "fail open" without warning.
457
+ # @param [String] resource
458
+ # REQUIRED: The resource for which the policy detail is being requested.
459
+ # See the operation documentation for the appropriate value for this field.
460
+ # @param [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsRequest] test_iam_permissions_request_object
461
+ # @param [String] fields
462
+ # Selector specifying which fields to include in a partial response.
463
+ # @param [String] quota_user
464
+ # Available to use for quota purposes for server-side applications. Can be any
465
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
466
+ # @param [Google::Apis::RequestOptions] options
467
+ # Request-specific options
468
+ #
469
+ # @yield [result, err] Result & error if block supplied
470
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse] parsed result object
471
+ # @yieldparam err [StandardError] error object if request failed
472
+ #
473
+ # @return [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse]
474
+ #
475
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
476
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
477
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
478
+ def test_variable_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
479
+ command = make_simple_command(:post, 'v1beta1/{+resource}:testIamPermissions', options)
480
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsRequest::Representation
481
+ command.request_object = test_iam_permissions_request_object
482
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse::Representation
483
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse
484
+ command.params['resource'] = resource unless resource.nil?
485
+ command.query['fields'] = fields unless fields.nil?
486
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
487
+ execute_or_queue_command(command, &block)
488
+ end
489
+
490
+ # Deletes a variable or multiple variables.
491
+ # If you specify a variable name, then that variable is deleted. If you
492
+ # specify a prefix and `recursive` is true, then all variables with that
493
+ # prefix are deleted. You must set a `recursive` to true if you delete
494
+ # variables by prefix.
495
+ # @param [String] name
496
+ # The name of the variable to delete, in the format:
497
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]/variables/[VARIABLE_NAME]`
498
+ # @param [Boolean] recursive
499
+ # Set to `true` to recursively delete multiple variables with the same
500
+ # prefix.
501
+ # @param [String] fields
502
+ # Selector specifying which fields to include in a partial response.
503
+ # @param [String] quota_user
504
+ # Available to use for quota purposes for server-side applications. Can be any
505
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
506
+ # @param [Google::Apis::RequestOptions] options
507
+ # Request-specific options
508
+ #
509
+ # @yield [result, err] Result & error if block supplied
510
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Empty] parsed result object
511
+ # @yieldparam err [StandardError] error object if request failed
512
+ #
513
+ # @return [Google::Apis::RuntimeconfigV1beta1::Empty]
514
+ #
515
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
516
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
517
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
518
+ def delete_project_config_variable(name, recursive: nil, fields: nil, quota_user: nil, options: nil, &block)
519
+ command = make_simple_command(:delete, 'v1beta1/{+name}', options)
520
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Empty::Representation
521
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Empty
522
+ command.params['name'] = name unless name.nil?
523
+ command.query['recursive'] = recursive unless recursive.nil?
524
+ command.query['fields'] = fields unless fields.nil?
525
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
526
+ execute_or_queue_command(command, &block)
527
+ end
528
+
529
+ # Lists variables within given a configuration, matching any provided filters.
530
+ # This only lists variable names, not the values, unless `return_values` is
531
+ # true, in which case only variables that user has IAM permission to GetVariable
532
+ # will be returned.
533
+ # @param [String] parent
534
+ # The path to the RuntimeConfig resource for which you want to list variables.
535
+ # The configuration must exist beforehand; the path must by in the format:
536
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`
537
+ # @param [String] filter
538
+ # Filters variables by matching the specified filter. For example:
539
+ # `projects/example-project/config/[CONFIG_NAME]/variables/example-variable`.
540
+ # @param [Boolean] return_values
541
+ # The flag indicates whether the user wants to return values of variables.
542
+ # If true, then only those variables that user has IAM GetVariable permission
543
+ # will be returned along with their values.
544
+ # @param [String] page_token
545
+ # Specifies a page token to use. Set `pageToken` to a `nextPageToken`
546
+ # returned by a previous list request to get the next page of results.
547
+ # @param [Fixnum] page_size
548
+ # Specifies the number of results to return per page. If there are fewer
549
+ # elements than the specified number, returns all elements.
550
+ # @param [String] fields
551
+ # Selector specifying which fields to include in a partial response.
552
+ # @param [String] quota_user
553
+ # Available to use for quota purposes for server-side applications. Can be any
554
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
555
+ # @param [Google::Apis::RequestOptions] options
556
+ # Request-specific options
557
+ #
558
+ # @yield [result, err] Result & error if block supplied
559
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::ListVariablesResponse] parsed result object
560
+ # @yieldparam err [StandardError] error object if request failed
561
+ #
562
+ # @return [Google::Apis::RuntimeconfigV1beta1::ListVariablesResponse]
563
+ #
564
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
565
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
566
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
567
+ def list_project_config_variables(parent, filter: nil, return_values: nil, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
568
+ command = make_simple_command(:get, 'v1beta1/{+parent}/variables', options)
569
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::ListVariablesResponse::Representation
570
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::ListVariablesResponse
571
+ command.params['parent'] = parent unless parent.nil?
572
+ command.query['filter'] = filter unless filter.nil?
573
+ command.query['returnValues'] = return_values unless return_values.nil?
574
+ command.query['pageToken'] = page_token unless page_token.nil?
575
+ command.query['pageSize'] = page_size unless page_size.nil?
576
+ command.query['fields'] = fields unless fields.nil?
577
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
578
+ execute_or_queue_command(command, &block)
579
+ end
580
+
581
+ # Creates a variable within the given configuration. You cannot create
582
+ # a variable with a name that is a prefix of an existing variable name, or a
583
+ # name that has an existing variable name as a prefix.
584
+ # To learn more about creating a variable, read the
585
+ # [Setting and Getting Data](/deployment-manager/runtime-configurator/set-and-
586
+ # get-variables)
587
+ # documentation.
588
+ # @param [String] parent
589
+ # The path to the RutimeConfig resource that this variable should belong to.
590
+ # The configuration must exist beforehand; the path must by in the format:
591
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`
592
+ # @param [Google::Apis::RuntimeconfigV1beta1::Variable] variable_object
593
+ # @param [String] request_id
594
+ # An optional but recommended unique `request_id`. If the server
595
+ # receives two `create()` requests with the same
596
+ # `request_id`, then the second request will be ignored and the
597
+ # first resource created and stored in the backend is returned.
598
+ # Empty `request_id` fields are ignored.
599
+ # It is responsibility of the client to ensure uniqueness of the
600
+ # `request_id` strings.
601
+ # `request_id` strings are limited to 64 characters.
602
+ # @param [String] fields
603
+ # Selector specifying which fields to include in a partial response.
604
+ # @param [String] quota_user
605
+ # Available to use for quota purposes for server-side applications. Can be any
606
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
607
+ # @param [Google::Apis::RequestOptions] options
608
+ # Request-specific options
609
+ #
610
+ # @yield [result, err] Result & error if block supplied
611
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Variable] parsed result object
612
+ # @yieldparam err [StandardError] error object if request failed
613
+ #
614
+ # @return [Google::Apis::RuntimeconfigV1beta1::Variable]
615
+ #
616
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
617
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
618
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
619
+ def create_project_config_variable(parent, variable_object = nil, request_id: nil, fields: nil, quota_user: nil, options: nil, &block)
620
+ command = make_simple_command(:post, 'v1beta1/{+parent}/variables', options)
621
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::Variable::Representation
622
+ command.request_object = variable_object
623
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Variable::Representation
624
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Variable
625
+ command.params['parent'] = parent unless parent.nil?
626
+ command.query['requestId'] = request_id unless request_id.nil?
627
+ command.query['fields'] = fields unless fields.nil?
628
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
629
+ execute_or_queue_command(command, &block)
630
+ end
631
+
632
+ # Creates a Waiter resource. This operation returns a long-running Operation
633
+ # resource which can be polled for completion. However, a waiter with the
634
+ # given name will exist (and can be retrieved) prior to the operation
635
+ # completing. If the operation fails, the failed Waiter resource will
636
+ # still exist and must be deleted prior to subsequent creation attempts.
637
+ # @param [String] parent
638
+ # The path to the configuration that will own the waiter.
639
+ # The configuration must exist beforehand; the path must by in the format:
640
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`.
641
+ # @param [Google::Apis::RuntimeconfigV1beta1::Waiter] waiter_object
642
+ # @param [String] request_id
643
+ # An optional but recommended unique `request_id`. If the server
644
+ # receives two `create()` requests with the same
645
+ # `request_id`, then the second request will be ignored and the
646
+ # first resource created and stored in the backend is returned.
647
+ # Empty `request_id` fields are ignored.
648
+ # It is responsibility of the client to ensure uniqueness of the
649
+ # `request_id` strings.
650
+ # `request_id` strings are limited to 64 characters.
651
+ # @param [String] fields
652
+ # Selector specifying which fields to include in a partial response.
653
+ # @param [String] quota_user
654
+ # Available to use for quota purposes for server-side applications. Can be any
655
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
656
+ # @param [Google::Apis::RequestOptions] options
657
+ # Request-specific options
658
+ #
659
+ # @yield [result, err] Result & error if block supplied
660
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Operation] parsed result object
661
+ # @yieldparam err [StandardError] error object if request failed
662
+ #
663
+ # @return [Google::Apis::RuntimeconfigV1beta1::Operation]
664
+ #
665
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
666
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
667
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
668
+ def create_project_config_waiter(parent, waiter_object = nil, request_id: nil, fields: nil, quota_user: nil, options: nil, &block)
669
+ command = make_simple_command(:post, 'v1beta1/{+parent}/waiters', options)
670
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::Waiter::Representation
671
+ command.request_object = waiter_object
672
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Operation::Representation
673
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Operation
674
+ command.params['parent'] = parent unless parent.nil?
675
+ command.query['requestId'] = request_id unless request_id.nil?
676
+ command.query['fields'] = fields unless fields.nil?
677
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
678
+ execute_or_queue_command(command, &block)
679
+ end
680
+
681
+ # Returns permissions that a caller has on the specified resource.
682
+ # If the resource does not exist, this will return an empty set of
683
+ # permissions, not a NOT_FOUND error.
684
+ # Note: This operation is designed to be used for building permission-aware
685
+ # UIs and command-line tools, not for authorization checking. This operation
686
+ # may "fail open" without warning.
687
+ # @param [String] resource
688
+ # REQUIRED: The resource for which the policy detail is being requested.
689
+ # See the operation documentation for the appropriate value for this field.
690
+ # @param [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsRequest] test_iam_permissions_request_object
691
+ # @param [String] fields
692
+ # Selector specifying which fields to include in a partial response.
693
+ # @param [String] quota_user
694
+ # Available to use for quota purposes for server-side applications. Can be any
695
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
696
+ # @param [Google::Apis::RequestOptions] options
697
+ # Request-specific options
698
+ #
699
+ # @yield [result, err] Result & error if block supplied
700
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse] parsed result object
701
+ # @yieldparam err [StandardError] error object if request failed
702
+ #
703
+ # @return [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse]
704
+ #
705
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
706
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
707
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
708
+ def test_waiter_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
709
+ command = make_simple_command(:post, 'v1beta1/{+resource}:testIamPermissions', options)
710
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsRequest::Representation
711
+ command.request_object = test_iam_permissions_request_object
712
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse::Representation
713
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse
714
+ command.params['resource'] = resource unless resource.nil?
715
+ command.query['fields'] = fields unless fields.nil?
716
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
717
+ execute_or_queue_command(command, &block)
718
+ end
719
+
720
+ # Deletes the waiter with the specified name.
721
+ # @param [String] name
722
+ # The Waiter resource to delete, in the format:
723
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]/waiters/[WAITER_NAME]`
724
+ # @param [String] fields
725
+ # Selector specifying which fields to include in a partial response.
726
+ # @param [String] quota_user
727
+ # Available to use for quota purposes for server-side applications. Can be any
728
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
729
+ # @param [Google::Apis::RequestOptions] options
730
+ # Request-specific options
731
+ #
732
+ # @yield [result, err] Result & error if block supplied
733
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Empty] parsed result object
734
+ # @yieldparam err [StandardError] error object if request failed
735
+ #
736
+ # @return [Google::Apis::RuntimeconfigV1beta1::Empty]
737
+ #
738
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
739
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
740
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
741
+ def delete_project_config_waiter(name, fields: nil, quota_user: nil, options: nil, &block)
742
+ command = make_simple_command(:delete, 'v1beta1/{+name}', options)
743
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Empty::Representation
744
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Empty
745
+ command.params['name'] = name unless name.nil?
746
+ command.query['fields'] = fields unless fields.nil?
747
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
748
+ execute_or_queue_command(command, &block)
749
+ end
750
+
751
+ # Gets information about a single waiter.
752
+ # @param [String] name
753
+ # The fully-qualified name of the Waiter resource object to retrieve, in the
754
+ # format:
755
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]/waiters/[WAITER_NAME]`
756
+ # @param [String] fields
757
+ # Selector specifying which fields to include in a partial response.
758
+ # @param [String] quota_user
759
+ # Available to use for quota purposes for server-side applications. Can be any
760
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
761
+ # @param [Google::Apis::RequestOptions] options
762
+ # Request-specific options
763
+ #
764
+ # @yield [result, err] Result & error if block supplied
765
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Waiter] parsed result object
766
+ # @yieldparam err [StandardError] error object if request failed
767
+ #
768
+ # @return [Google::Apis::RuntimeconfigV1beta1::Waiter]
769
+ #
770
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
771
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
772
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
773
+ def get_project_config_waiter(name, fields: nil, quota_user: nil, options: nil, &block)
774
+ command = make_simple_command(:get, 'v1beta1/{+name}', options)
775
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Waiter::Representation
776
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Waiter
777
+ command.params['name'] = name unless name.nil?
778
+ command.query['fields'] = fields unless fields.nil?
779
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
780
+ execute_or_queue_command(command, &block)
781
+ end
782
+
783
+ # List waiters within the given configuration.
784
+ # @param [String] parent
785
+ # The path to the configuration for which you want to get a list of waiters.
786
+ # The configuration must exist beforehand; the path must by in the format:
787
+ # `projects/[PROJECT_ID]/configs/[CONFIG_NAME]`
788
+ # @param [String] page_token
789
+ # Specifies a page token to use. Set `pageToken` to a `nextPageToken`
790
+ # returned by a previous list request to get the next page of results.
791
+ # @param [Fixnum] page_size
792
+ # Specifies the number of results to return per page. If there are fewer
793
+ # elements than the specified number, returns all elements.
794
+ # @param [String] fields
795
+ # Selector specifying which fields to include in a partial response.
796
+ # @param [String] quota_user
797
+ # Available to use for quota purposes for server-side applications. Can be any
798
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
799
+ # @param [Google::Apis::RequestOptions] options
800
+ # Request-specific options
801
+ #
802
+ # @yield [result, err] Result & error if block supplied
803
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::ListWaitersResponse] parsed result object
804
+ # @yieldparam err [StandardError] error object if request failed
805
+ #
806
+ # @return [Google::Apis::RuntimeconfigV1beta1::ListWaitersResponse]
807
+ #
808
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
809
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
810
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
811
+ def list_project_config_waiters(parent, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
812
+ command = make_simple_command(:get, 'v1beta1/{+parent}/waiters', options)
813
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::ListWaitersResponse::Representation
814
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::ListWaitersResponse
815
+ command.params['parent'] = parent unless parent.nil?
816
+ command.query['pageToken'] = page_token unless page_token.nil?
817
+ command.query['pageSize'] = page_size unless page_size.nil?
818
+ command.query['fields'] = fields unless fields.nil?
819
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
820
+ execute_or_queue_command(command, &block)
821
+ end
822
+
823
+ # Gets the latest state of a long-running operation. Clients can use this
824
+ # method to poll the operation result at intervals as recommended by the API
825
+ # service.
826
+ # @param [String] name
827
+ # The name of the operation resource.
828
+ # @param [String] fields
829
+ # Selector specifying which fields to include in a partial response.
830
+ # @param [String] quota_user
831
+ # Available to use for quota purposes for server-side applications. Can be any
832
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
833
+ # @param [Google::Apis::RequestOptions] options
834
+ # Request-specific options
835
+ #
836
+ # @yield [result, err] Result & error if block supplied
837
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::Operation] parsed result object
838
+ # @yieldparam err [StandardError] error object if request failed
839
+ #
840
+ # @return [Google::Apis::RuntimeconfigV1beta1::Operation]
841
+ #
842
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
843
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
844
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
845
+ def get_project_config_operation(name, fields: nil, quota_user: nil, options: nil, &block)
846
+ command = make_simple_command(:get, 'v1beta1/{+name}', options)
847
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::Operation::Representation
848
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::Operation
849
+ command.params['name'] = name unless name.nil?
850
+ command.query['fields'] = fields unless fields.nil?
851
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
852
+ execute_or_queue_command(command, &block)
853
+ end
854
+
855
+ # Returns permissions that a caller has on the specified resource.
856
+ # If the resource does not exist, this will return an empty set of
857
+ # permissions, not a NOT_FOUND error.
858
+ # Note: This operation is designed to be used for building permission-aware
859
+ # UIs and command-line tools, not for authorization checking. This operation
860
+ # may "fail open" without warning.
861
+ # @param [String] resource
862
+ # REQUIRED: The resource for which the policy detail is being requested.
863
+ # See the operation documentation for the appropriate value for this field.
864
+ # @param [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsRequest] test_iam_permissions_request_object
865
+ # @param [String] fields
866
+ # Selector specifying which fields to include in a partial response.
867
+ # @param [String] quota_user
868
+ # Available to use for quota purposes for server-side applications. Can be any
869
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
870
+ # @param [Google::Apis::RequestOptions] options
871
+ # Request-specific options
872
+ #
873
+ # @yield [result, err] Result & error if block supplied
874
+ # @yieldparam result [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse] parsed result object
875
+ # @yieldparam err [StandardError] error object if request failed
876
+ #
877
+ # @return [Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse]
878
+ #
879
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
880
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
881
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
882
+ def test_operation_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
883
+ command = make_simple_command(:post, 'v1beta1/{+resource}:testIamPermissions', options)
884
+ command.request_representation = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsRequest::Representation
885
+ command.request_object = test_iam_permissions_request_object
886
+ command.response_representation = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse::Representation
887
+ command.response_class = Google::Apis::RuntimeconfigV1beta1::TestIamPermissionsResponse
888
+ command.params['resource'] = resource unless resource.nil?
889
+ command.query['fields'] = fields unless fields.nil?
890
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
891
+ execute_or_queue_command(command, &block)
892
+ end
893
+
894
+ protected
895
+
896
+ def apply_command_defaults(command)
897
+ command.query['key'] = key unless key.nil?
898
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
899
+ end
900
+ end
901
+ end
902
+ end
903
+ end