google-apis-tpu_v2 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,28 @@
1
+ # Copyright 2020 Google LLC
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
+ module Google
16
+ module Apis
17
+ module TpuV2
18
+ # Version of the google-apis-tpu_v2 gem
19
+ GEM_VERSION = "0.1.0"
20
+
21
+ # Version of the code generator used to generate this client
22
+ GENERATOR_VERSION = "0.11.0"
23
+
24
+ # Revision of the discovery document this client was generated from
25
+ REVISION = "20221004"
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,504 @@
1
+ # Copyright 2020 Google LLC
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 TpuV2
24
+
25
+ class AcceleratorType
26
+ class Representation < Google::Apis::Core::JsonRepresentation; end
27
+
28
+ include Google::Apis::Core::JsonObjectSupport
29
+ end
30
+
31
+ class AccessConfig
32
+ class Representation < Google::Apis::Core::JsonRepresentation; end
33
+
34
+ include Google::Apis::Core::JsonObjectSupport
35
+ end
36
+
37
+ class AttachedDisk
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 GenerateServiceIdentityRequest
50
+ class Representation < Google::Apis::Core::JsonRepresentation; end
51
+
52
+ include Google::Apis::Core::JsonObjectSupport
53
+ end
54
+
55
+ class GenerateServiceIdentityResponse
56
+ class Representation < Google::Apis::Core::JsonRepresentation; end
57
+
58
+ include Google::Apis::Core::JsonObjectSupport
59
+ end
60
+
61
+ class GetGuestAttributesRequest
62
+ class Representation < Google::Apis::Core::JsonRepresentation; end
63
+
64
+ include Google::Apis::Core::JsonObjectSupport
65
+ end
66
+
67
+ class GetGuestAttributesResponse
68
+ class Representation < Google::Apis::Core::JsonRepresentation; end
69
+
70
+ include Google::Apis::Core::JsonObjectSupport
71
+ end
72
+
73
+ class GuestAttributes
74
+ class Representation < Google::Apis::Core::JsonRepresentation; end
75
+
76
+ include Google::Apis::Core::JsonObjectSupport
77
+ end
78
+
79
+ class GuestAttributesEntry
80
+ class Representation < Google::Apis::Core::JsonRepresentation; end
81
+
82
+ include Google::Apis::Core::JsonObjectSupport
83
+ end
84
+
85
+ class GuestAttributesValue
86
+ class Representation < Google::Apis::Core::JsonRepresentation; end
87
+
88
+ include Google::Apis::Core::JsonObjectSupport
89
+ end
90
+
91
+ class ListAcceleratorTypesResponse
92
+ class Representation < Google::Apis::Core::JsonRepresentation; end
93
+
94
+ include Google::Apis::Core::JsonObjectSupport
95
+ end
96
+
97
+ class ListLocationsResponse
98
+ class Representation < Google::Apis::Core::JsonRepresentation; end
99
+
100
+ include Google::Apis::Core::JsonObjectSupport
101
+ end
102
+
103
+ class ListNodesResponse
104
+ class Representation < Google::Apis::Core::JsonRepresentation; end
105
+
106
+ include Google::Apis::Core::JsonObjectSupport
107
+ end
108
+
109
+ class ListOperationsResponse
110
+ class Representation < Google::Apis::Core::JsonRepresentation; end
111
+
112
+ include Google::Apis::Core::JsonObjectSupport
113
+ end
114
+
115
+ class ListRuntimeVersionsResponse
116
+ class Representation < Google::Apis::Core::JsonRepresentation; end
117
+
118
+ include Google::Apis::Core::JsonObjectSupport
119
+ end
120
+
121
+ class Location
122
+ class Representation < Google::Apis::Core::JsonRepresentation; end
123
+
124
+ include Google::Apis::Core::JsonObjectSupport
125
+ end
126
+
127
+ class NetworkConfig
128
+ class Representation < Google::Apis::Core::JsonRepresentation; end
129
+
130
+ include Google::Apis::Core::JsonObjectSupport
131
+ end
132
+
133
+ class NetworkEndpoint
134
+ class Representation < Google::Apis::Core::JsonRepresentation; end
135
+
136
+ include Google::Apis::Core::JsonObjectSupport
137
+ end
138
+
139
+ class Node
140
+ class Representation < Google::Apis::Core::JsonRepresentation; end
141
+
142
+ include Google::Apis::Core::JsonObjectSupport
143
+ end
144
+
145
+ class Operation
146
+ class Representation < Google::Apis::Core::JsonRepresentation; end
147
+
148
+ include Google::Apis::Core::JsonObjectSupport
149
+ end
150
+
151
+ class OperationMetadata
152
+ class Representation < Google::Apis::Core::JsonRepresentation; end
153
+
154
+ include Google::Apis::Core::JsonObjectSupport
155
+ end
156
+
157
+ class RuntimeVersion
158
+ class Representation < Google::Apis::Core::JsonRepresentation; end
159
+
160
+ include Google::Apis::Core::JsonObjectSupport
161
+ end
162
+
163
+ class SchedulingConfig
164
+ class Representation < Google::Apis::Core::JsonRepresentation; end
165
+
166
+ include Google::Apis::Core::JsonObjectSupport
167
+ end
168
+
169
+ class ServiceAccount
170
+ class Representation < Google::Apis::Core::JsonRepresentation; end
171
+
172
+ include Google::Apis::Core::JsonObjectSupport
173
+ end
174
+
175
+ class ServiceIdentity
176
+ class Representation < Google::Apis::Core::JsonRepresentation; end
177
+
178
+ include Google::Apis::Core::JsonObjectSupport
179
+ end
180
+
181
+ class ShieldedInstanceConfig
182
+ class Representation < Google::Apis::Core::JsonRepresentation; end
183
+
184
+ include Google::Apis::Core::JsonObjectSupport
185
+ end
186
+
187
+ class StartNodeRequest
188
+ class Representation < Google::Apis::Core::JsonRepresentation; end
189
+
190
+ include Google::Apis::Core::JsonObjectSupport
191
+ end
192
+
193
+ class Status
194
+ class Representation < Google::Apis::Core::JsonRepresentation; end
195
+
196
+ include Google::Apis::Core::JsonObjectSupport
197
+ end
198
+
199
+ class StopNodeRequest
200
+ class Representation < Google::Apis::Core::JsonRepresentation; end
201
+
202
+ include Google::Apis::Core::JsonObjectSupport
203
+ end
204
+
205
+ class Symptom
206
+ class Representation < Google::Apis::Core::JsonRepresentation; end
207
+
208
+ include Google::Apis::Core::JsonObjectSupport
209
+ end
210
+
211
+ class AcceleratorType
212
+ # @private
213
+ class Representation < Google::Apis::Core::JsonRepresentation
214
+ property :name, as: 'name'
215
+ property :type, as: 'type'
216
+ end
217
+ end
218
+
219
+ class AccessConfig
220
+ # @private
221
+ class Representation < Google::Apis::Core::JsonRepresentation
222
+ property :external_ip, as: 'externalIp'
223
+ end
224
+ end
225
+
226
+ class AttachedDisk
227
+ # @private
228
+ class Representation < Google::Apis::Core::JsonRepresentation
229
+ property :mode, as: 'mode'
230
+ property :source_disk, as: 'sourceDisk'
231
+ end
232
+ end
233
+
234
+ class Empty
235
+ # @private
236
+ class Representation < Google::Apis::Core::JsonRepresentation
237
+ end
238
+ end
239
+
240
+ class GenerateServiceIdentityRequest
241
+ # @private
242
+ class Representation < Google::Apis::Core::JsonRepresentation
243
+ end
244
+ end
245
+
246
+ class GenerateServiceIdentityResponse
247
+ # @private
248
+ class Representation < Google::Apis::Core::JsonRepresentation
249
+ property :identity, as: 'identity', class: Google::Apis::TpuV2::ServiceIdentity, decorator: Google::Apis::TpuV2::ServiceIdentity::Representation
250
+
251
+ end
252
+ end
253
+
254
+ class GetGuestAttributesRequest
255
+ # @private
256
+ class Representation < Google::Apis::Core::JsonRepresentation
257
+ property :query_path, as: 'queryPath'
258
+ collection :worker_ids, as: 'workerIds'
259
+ end
260
+ end
261
+
262
+ class GetGuestAttributesResponse
263
+ # @private
264
+ class Representation < Google::Apis::Core::JsonRepresentation
265
+ collection :guest_attributes, as: 'guestAttributes', class: Google::Apis::TpuV2::GuestAttributes, decorator: Google::Apis::TpuV2::GuestAttributes::Representation
266
+
267
+ end
268
+ end
269
+
270
+ class GuestAttributes
271
+ # @private
272
+ class Representation < Google::Apis::Core::JsonRepresentation
273
+ property :query_path, as: 'queryPath'
274
+ property :query_value, as: 'queryValue', class: Google::Apis::TpuV2::GuestAttributesValue, decorator: Google::Apis::TpuV2::GuestAttributesValue::Representation
275
+
276
+ end
277
+ end
278
+
279
+ class GuestAttributesEntry
280
+ # @private
281
+ class Representation < Google::Apis::Core::JsonRepresentation
282
+ property :key, as: 'key'
283
+ property :namespace, as: 'namespace'
284
+ property :value, as: 'value'
285
+ end
286
+ end
287
+
288
+ class GuestAttributesValue
289
+ # @private
290
+ class Representation < Google::Apis::Core::JsonRepresentation
291
+ collection :items, as: 'items', class: Google::Apis::TpuV2::GuestAttributesEntry, decorator: Google::Apis::TpuV2::GuestAttributesEntry::Representation
292
+
293
+ end
294
+ end
295
+
296
+ class ListAcceleratorTypesResponse
297
+ # @private
298
+ class Representation < Google::Apis::Core::JsonRepresentation
299
+ collection :accelerator_types, as: 'acceleratorTypes', class: Google::Apis::TpuV2::AcceleratorType, decorator: Google::Apis::TpuV2::AcceleratorType::Representation
300
+
301
+ property :next_page_token, as: 'nextPageToken'
302
+ collection :unreachable, as: 'unreachable'
303
+ end
304
+ end
305
+
306
+ class ListLocationsResponse
307
+ # @private
308
+ class Representation < Google::Apis::Core::JsonRepresentation
309
+ collection :locations, as: 'locations', class: Google::Apis::TpuV2::Location, decorator: Google::Apis::TpuV2::Location::Representation
310
+
311
+ property :next_page_token, as: 'nextPageToken'
312
+ end
313
+ end
314
+
315
+ class ListNodesResponse
316
+ # @private
317
+ class Representation < Google::Apis::Core::JsonRepresentation
318
+ property :next_page_token, as: 'nextPageToken'
319
+ collection :nodes, as: 'nodes', class: Google::Apis::TpuV2::Node, decorator: Google::Apis::TpuV2::Node::Representation
320
+
321
+ collection :unreachable, as: 'unreachable'
322
+ end
323
+ end
324
+
325
+ class ListOperationsResponse
326
+ # @private
327
+ class Representation < Google::Apis::Core::JsonRepresentation
328
+ property :next_page_token, as: 'nextPageToken'
329
+ collection :operations, as: 'operations', class: Google::Apis::TpuV2::Operation, decorator: Google::Apis::TpuV2::Operation::Representation
330
+
331
+ end
332
+ end
333
+
334
+ class ListRuntimeVersionsResponse
335
+ # @private
336
+ class Representation < Google::Apis::Core::JsonRepresentation
337
+ property :next_page_token, as: 'nextPageToken'
338
+ collection :runtime_versions, as: 'runtimeVersions', class: Google::Apis::TpuV2::RuntimeVersion, decorator: Google::Apis::TpuV2::RuntimeVersion::Representation
339
+
340
+ collection :unreachable, as: 'unreachable'
341
+ end
342
+ end
343
+
344
+ class Location
345
+ # @private
346
+ class Representation < Google::Apis::Core::JsonRepresentation
347
+ property :display_name, as: 'displayName'
348
+ hash :labels, as: 'labels'
349
+ property :location_id, as: 'locationId'
350
+ hash :metadata, as: 'metadata'
351
+ property :name, as: 'name'
352
+ end
353
+ end
354
+
355
+ class NetworkConfig
356
+ # @private
357
+ class Representation < Google::Apis::Core::JsonRepresentation
358
+ property :can_ip_forward, as: 'canIpForward'
359
+ property :enable_external_ips, as: 'enableExternalIps'
360
+ property :network, as: 'network'
361
+ property :subnetwork, as: 'subnetwork'
362
+ end
363
+ end
364
+
365
+ class NetworkEndpoint
366
+ # @private
367
+ class Representation < Google::Apis::Core::JsonRepresentation
368
+ property :access_config, as: 'accessConfig', class: Google::Apis::TpuV2::AccessConfig, decorator: Google::Apis::TpuV2::AccessConfig::Representation
369
+
370
+ property :ip_address, as: 'ipAddress'
371
+ property :port, as: 'port'
372
+ end
373
+ end
374
+
375
+ class Node
376
+ # @private
377
+ class Representation < Google::Apis::Core::JsonRepresentation
378
+ property :accelerator_type, as: 'acceleratorType'
379
+ property :api_version, as: 'apiVersion'
380
+ property :cidr_block, as: 'cidrBlock'
381
+ property :create_time, as: 'createTime'
382
+ collection :data_disks, as: 'dataDisks', class: Google::Apis::TpuV2::AttachedDisk, decorator: Google::Apis::TpuV2::AttachedDisk::Representation
383
+
384
+ property :description, as: 'description'
385
+ property :health, as: 'health'
386
+ property :health_description, as: 'healthDescription'
387
+ property :id, :numeric_string => true, as: 'id'
388
+ hash :labels, as: 'labels'
389
+ hash :metadata, as: 'metadata'
390
+ property :name, as: 'name'
391
+ property :network_config, as: 'networkConfig', class: Google::Apis::TpuV2::NetworkConfig, decorator: Google::Apis::TpuV2::NetworkConfig::Representation
392
+
393
+ collection :network_endpoints, as: 'networkEndpoints', class: Google::Apis::TpuV2::NetworkEndpoint, decorator: Google::Apis::TpuV2::NetworkEndpoint::Representation
394
+
395
+ property :runtime_version, as: 'runtimeVersion'
396
+ property :scheduling_config, as: 'schedulingConfig', class: Google::Apis::TpuV2::SchedulingConfig, decorator: Google::Apis::TpuV2::SchedulingConfig::Representation
397
+
398
+ property :service_account, as: 'serviceAccount', class: Google::Apis::TpuV2::ServiceAccount, decorator: Google::Apis::TpuV2::ServiceAccount::Representation
399
+
400
+ property :shielded_instance_config, as: 'shieldedInstanceConfig', class: Google::Apis::TpuV2::ShieldedInstanceConfig, decorator: Google::Apis::TpuV2::ShieldedInstanceConfig::Representation
401
+
402
+ property :state, as: 'state'
403
+ collection :symptoms, as: 'symptoms', class: Google::Apis::TpuV2::Symptom, decorator: Google::Apis::TpuV2::Symptom::Representation
404
+
405
+ collection :tags, as: 'tags'
406
+ end
407
+ end
408
+
409
+ class Operation
410
+ # @private
411
+ class Representation < Google::Apis::Core::JsonRepresentation
412
+ property :done, as: 'done'
413
+ property :error, as: 'error', class: Google::Apis::TpuV2::Status, decorator: Google::Apis::TpuV2::Status::Representation
414
+
415
+ hash :metadata, as: 'metadata'
416
+ property :name, as: 'name'
417
+ hash :response, as: 'response'
418
+ end
419
+ end
420
+
421
+ class OperationMetadata
422
+ # @private
423
+ class Representation < Google::Apis::Core::JsonRepresentation
424
+ property :api_version, as: 'apiVersion'
425
+ property :cancel_requested, as: 'cancelRequested'
426
+ property :create_time, as: 'createTime'
427
+ property :end_time, as: 'endTime'
428
+ property :status_detail, as: 'statusDetail'
429
+ property :target, as: 'target'
430
+ property :verb, as: 'verb'
431
+ end
432
+ end
433
+
434
+ class RuntimeVersion
435
+ # @private
436
+ class Representation < Google::Apis::Core::JsonRepresentation
437
+ property :name, as: 'name'
438
+ property :version, as: 'version'
439
+ end
440
+ end
441
+
442
+ class SchedulingConfig
443
+ # @private
444
+ class Representation < Google::Apis::Core::JsonRepresentation
445
+ property :preemptible, as: 'preemptible'
446
+ property :reserved, as: 'reserved'
447
+ end
448
+ end
449
+
450
+ class ServiceAccount
451
+ # @private
452
+ class Representation < Google::Apis::Core::JsonRepresentation
453
+ property :email, as: 'email'
454
+ collection :scope, as: 'scope'
455
+ end
456
+ end
457
+
458
+ class ServiceIdentity
459
+ # @private
460
+ class Representation < Google::Apis::Core::JsonRepresentation
461
+ property :email, as: 'email'
462
+ end
463
+ end
464
+
465
+ class ShieldedInstanceConfig
466
+ # @private
467
+ class Representation < Google::Apis::Core::JsonRepresentation
468
+ property :enable_secure_boot, as: 'enableSecureBoot'
469
+ end
470
+ end
471
+
472
+ class StartNodeRequest
473
+ # @private
474
+ class Representation < Google::Apis::Core::JsonRepresentation
475
+ end
476
+ end
477
+
478
+ class Status
479
+ # @private
480
+ class Representation < Google::Apis::Core::JsonRepresentation
481
+ property :code, as: 'code'
482
+ collection :details, as: 'details'
483
+ property :message, as: 'message'
484
+ end
485
+ end
486
+
487
+ class StopNodeRequest
488
+ # @private
489
+ class Representation < Google::Apis::Core::JsonRepresentation
490
+ end
491
+ end
492
+
493
+ class Symptom
494
+ # @private
495
+ class Representation < Google::Apis::Core::JsonRepresentation
496
+ property :create_time, as: 'createTime'
497
+ property :details, as: 'details'
498
+ property :symptom_type, as: 'symptomType'
499
+ property :worker_id, as: 'workerId'
500
+ end
501
+ end
502
+ end
503
+ end
504
+ end