xclarity_client 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (47) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +1 -1
  3. data/Gemfile +2 -0
  4. data/README.md +57 -4
  5. data/bin/mock_server.ru +1 -1
  6. data/docs/apib/cabinet.apib +63 -0
  7. data/docs/apib/canister.apib +69 -0
  8. data/docs/apib/chassis.apib +65 -1428
  9. data/docs/apib/cmm.apib +1102 -0
  10. data/docs/apib/fan.apib +383 -0
  11. data/docs/apib/fan_mux.apib +13 -0
  12. data/docs/apib/fan_muxes.apib +245 -0
  13. data/docs/apib/node.apib +8989 -869
  14. data/docs/apib/power_supply.apib +519 -0
  15. data/docs/apib/scalable_complex.apib +91 -0
  16. data/docs/apib/squisher.rb +26 -0
  17. data/docs/apib/switches.apib +1596 -0
  18. data/example/simple.rb +12 -5
  19. data/lib/xclarity_client.rb +20 -0
  20. data/lib/xclarity_client/cabinet.rb +14 -0
  21. data/lib/xclarity_client/cabinet_management.rb +59 -0
  22. data/lib/xclarity_client/canister.rb +20 -0
  23. data/lib/xclarity_client/canister_management.rb +60 -0
  24. data/lib/xclarity_client/chassi.rb +24 -0
  25. data/lib/xclarity_client/chassi_management.rb +64 -0
  26. data/lib/xclarity_client/client.rb +77 -1
  27. data/lib/xclarity_client/cmm.rb +18 -0
  28. data/lib/xclarity_client/cmm_management.rb +61 -0
  29. data/lib/xclarity_client/configuration.rb +13 -3
  30. data/lib/xclarity_client/fan.rb +20 -0
  31. data/lib/xclarity_client/fan_management.rb +83 -0
  32. data/lib/xclarity_client/fan_mux.rb +18 -0
  33. data/lib/xclarity_client/fan_mux_management.rb +82 -0
  34. data/lib/xclarity_client/node.rb +15 -94
  35. data/lib/xclarity_client/node_management.rb +62 -0
  36. data/lib/xclarity_client/power_supply.rb +18 -0
  37. data/lib/xclarity_client/power_supply_management.rb +89 -0
  38. data/lib/xclarity_client/scalable_complex.rb +16 -0
  39. data/lib/xclarity_client/scalable_complex_management.rb +83 -0
  40. data/lib/xclarity_client/switch.rb +19 -0
  41. data/lib/xclarity_client/switch_management.rb +59 -0
  42. data/lib/xclarity_client/version.rb +1 -1
  43. data/lib/xclarity_client/xclarity_base.rb +26 -1
  44. data/lib/xclarity_client/xclarity_resource.rb +20 -0
  45. data/xclarity_client.gemspec +1 -2
  46. metadata +34 -5
  47. data/lib/xclarity_client/chassis.rb +0 -7
@@ -0,0 +1,519 @@
1
+ FORMAT: 1A
2
+
3
+ # Power Supplies
4
+
5
+ # GET /powerSupplies/735425074A8511E200FB00FB00FB00FB?includeAttributes=description,dataHandle
6
+
7
+ + Response 200 (application/json)
8
+ {
9
+ "description":"2100W Power Supply",
10
+ "parent":{
11
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
12
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
13
+ },
14
+ "uuid":"735425074A8511E200FB00FB00FB00FB",
15
+ "uri":"powerSupply/735425074A8511E200FB00FB00FB00FB",
16
+ "dataHandle":0
17
+ }
18
+ + Response 400
19
+ + Response 401
20
+ + Response 404
21
+ + Response 409
22
+ + Response 500
23
+
24
+ # GET /powerSupplies/735425074A8511E200FB00FB00FB00FB?excludeAttributes=description,dataHandle
25
+
26
+ + Response 200 (application/json)
27
+ {
28
+ "model":"",
29
+ "manufacturerId":"20301",
30
+ "serialNumber":"",
31
+ "inputVoltageIsAC":true,
32
+ "inputVoltageMin":200,
33
+ "type":"PowerSupply",
34
+ "cmmDisplayName":"Power Supply 01",
35
+ "leds":[
36
+ {
37
+ "color":"Green",
38
+ "location":"Planar",
39
+ "name":"IN",
40
+ "state":"On"
41
+ },
42
+ {
43
+ "color":"Green",
44
+ "location":"Planar",
45
+ "name":"OUT",
46
+ "state":"On"
47
+ },
48
+ {
49
+ "color":"Amber",
50
+ "location":"Planar",
51
+ "name":"FAULT",
52
+ "state":"Off"
53
+ }
54
+ ],
55
+ "name":"Power Supply 01",
56
+ "cmmHealthState":"Normal",
57
+ "userDescription":"",
58
+ "manufactureDate":"5112",
59
+ "partNumber":"69Y5830",
60
+ "firmware":[
61
+ {
62
+ "status":"",
63
+ "name":"Power Supply Firmware",
64
+ "role":"",
65
+ "date":"",
66
+ "type":"Power Supply Firmware",
67
+ "build":"",
68
+ "version":"14"
69
+ }
70
+ ],
71
+ "machineType":"",
72
+ "hardwareRevision":"2.0",
73
+ "parent":{
74
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
75
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
76
+ },
77
+ "FRU":"69Y5831",
78
+ "uri":"powerSupply/735425074A8511E200FB00FB00FB00FB",
79
+ "productId":"303",
80
+ "powerAllocation":{
81
+ "totalInputPower":0,
82
+ "totalOutputPower":0
83
+ },
84
+ "powerState":"Unknown",
85
+ "posID":"128",
86
+ "slots":[
87
+ 1
88
+ ],
89
+ "manufacturer":"IBM",
90
+ "vpdID":"70",
91
+ "uuid":"735425074A8511E200FB00FB00FB00FB",
92
+ "productName":"IBM Flex System Enterprise Chassis 2100W Power Module",
93
+ "fruSerialNumber":"ZK11512CJ007",
94
+ "inputVoltageMax":240
95
+ }
96
+ + Response 400
97
+ + Response 401
98
+ + Response 404
99
+ + Response 409
100
+ + Response 500
101
+
102
+ # GET /powerSupplies/735425074A8511E200FB00FB00FB00FB
103
+
104
+ + Response 200 (application/json)
105
+ {
106
+ "model":"",
107
+ "manufacturerId":"20301",
108
+ "serialNumber":"",
109
+ "inputVoltageIsAC":true,
110
+ "inputVoltageMin":200,
111
+ "type":"PowerSupply",
112
+ "dataHandle":0,
113
+ "cmmDisplayName":"Power Supply 01",
114
+ "leds":[
115
+ {
116
+ "color":"Green",
117
+ "location":"Planar",
118
+ "name":"IN",
119
+ "state":"On"
120
+ },
121
+ {
122
+ "color":"Green",
123
+ "location":"Planar",
124
+ "name":"OUT",
125
+ "state":"On"
126
+ },
127
+ {
128
+ "color":"Amber",
129
+ "location":"Planar",
130
+ "name":"FAULT",
131
+ "state":"Off"
132
+ }
133
+ ],
134
+ "description":"2100W Power Supply",
135
+ "name":"Power Supply 01",
136
+ "cmmHealthState":"Normal",
137
+ "userDescription":"",
138
+ "manufactureDate":"5112",
139
+ "partNumber":"69Y5830",
140
+ "firmware":[
141
+ {
142
+ "status":"",
143
+ "name":"Power Supply Firmware",
144
+ "role":"",
145
+ "date":"",
146
+ "type":"Power Supply Firmware",
147
+ "build":"",
148
+ "version":"14"
149
+ }
150
+ ],
151
+ "machineType":"",
152
+ "hardwareRevision":"2.0",
153
+ "parent":{
154
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
155
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
156
+ },
157
+ "FRU":"69Y5831",
158
+ "uri":"powerSupply/735425074A8511E200FB00FB00FB00FB",
159
+ "productId":"303",
160
+ "powerAllocation":{
161
+ "totalInputPower":0,
162
+ "totalOutputPower":0
163
+ },
164
+ "powerState":"Unknown",
165
+ "posID":"128",
166
+ "slots":[
167
+ 1
168
+ ],
169
+ "manufacturer":"IBM",
170
+ "vpdID":"70",
171
+ "uuid":"735425074A8511E200FB00FB00FB00FB",
172
+ "productName":"IBM Flex System Enterprise Chassis 2100W Power Module",
173
+ "fruSerialNumber":"ZK11512CJ007",
174
+ "inputVoltageMax":240
175
+ }
176
+ + Response 400
177
+ + Response 401
178
+ + Response 404
179
+ + Response 409
180
+ + Response 500
181
+
182
+ # GET /powerSupplies?includeAttributes=description,dataHandle
183
+
184
+ + Response 200 (application/json)
185
+ {
186
+ "powerSupplyList":[
187
+ {
188
+ "description":"2100W Power Supply",
189
+ "parent":{
190
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
191
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
192
+ },
193
+ "uuid":"735425074A8511E200FB00FB00FB00FB",
194
+ "uri":"powerSupply/735425074A8511E200FB00FB00FB00FB",
195
+ "dataHandle":0
196
+ },
197
+ {
198
+ "description":"2100W Power Supply",
199
+ "parent":{
200
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
201
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
202
+ },
203
+ "uuid":"C2890E051CFF11E200AB00AB00AB00AB",
204
+ "uri":"powerSupply/C2890E051CFF11E200AB00AB00AB00AB",
205
+ "dataHandle":0
206
+ }
207
+ ]
208
+ }
209
+ + Response 400
210
+ + Response 401
211
+ + Response 404
212
+ + Response 409
213
+ + Response 500
214
+
215
+ # GET /powerSupplies?excludeAttributes=description,dataHandle
216
+
217
+ + Response 200 (application/json)
218
+ {
219
+ "powerSupplyList":[
220
+ {
221
+ "model":"",
222
+ "manufacturerId":"20301",
223
+ "serialNumber":"",
224
+ "inputVoltageIsAC":true,
225
+ "inputVoltageMin":200,
226
+ "type":"PowerSupply",
227
+ "cmmDisplayName":"Power Supply 01",
228
+ "leds":[
229
+ {
230
+ "color":"Green",
231
+ "location":"Planar",
232
+ "name":"IN",
233
+ "state":"On"
234
+ },
235
+ {
236
+ "color":"Green",
237
+ "location":"Planar",
238
+ "name":"OUT",
239
+ "state":"On"
240
+ },
241
+ {
242
+ "color":"Amber",
243
+ "location":"Planar",
244
+ "name":"FAULT",
245
+ "state":"Off"
246
+ }
247
+ ],
248
+ "name":"Power Supply 01",
249
+ "cmmHealthState":"Normal",
250
+ "userDescription":"",
251
+ "manufactureDate":"5112",
252
+ "partNumber":"69Y5830",
253
+ "firmware":[
254
+ {
255
+ "status":"",
256
+ "name":"Power Supply Firmware",
257
+ "role":"",
258
+ "date":"",
259
+ "type":"Power Supply Firmware",
260
+ "build":"",
261
+ "version":"14"
262
+ }
263
+ ],
264
+ "machineType":"",
265
+ "hardwareRevision":"2.0",
266
+ "parent":{
267
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
268
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
269
+ },
270
+ "FRU":"69Y5831",
271
+ "uri":"powerSupply/735425074A8511E200FB00FB00FB00FB",
272
+ "productId":"303",
273
+ "powerAllocation":{
274
+ "totalInputPower":0,
275
+ "totalOutputPower":0
276
+ },
277
+ "powerState":"Unknown",
278
+ "posID":"128",
279
+ "slots":[
280
+ 1
281
+ ],
282
+ "manufacturer":"IBM",
283
+ "vpdID":"70",
284
+ "uuid":"735425074A8511E200FB00FB00FB00FB",
285
+ "productName":"IBM Flex System Enterprise Chassis 2100W Power Module",
286
+ "fruSerialNumber":"ZK11512CJ007",
287
+ "inputVoltageMax":240
288
+ },
289
+ {
290
+ "model":"",
291
+ "manufacturerId":"20301",
292
+ "serialNumber":"",
293
+ "inputVoltageIsAC":true,
294
+ "inputVoltageMin":200,
295
+ "type":"PowerSupply",
296
+ "cmmDisplayName":"Power Supply 02",
297
+ "leds":[
298
+ {
299
+ "color":"Green",
300
+ "location":"Planar",
301
+ "name":"IN",
302
+ "state":"On"
303
+ },
304
+ {
305
+ "color":"Green",
306
+ "location":"Planar",
307
+ "name":"OUT",
308
+ "state":"On"
309
+ },
310
+ {
311
+ "color":"Amber",
312
+ "location":"Planar",
313
+ "name":"FAULT",
314
+ "state":"Off"
315
+ }
316
+ ],
317
+ "name":"Power Supply 02",
318
+ "cmmHealthState":"Normal",
319
+ "userDescription":"",
320
+ "manufactureDate":"4212",
321
+ "partNumber":"69Y5830",
322
+ "firmware":[
323
+ {
324
+ "status":"",
325
+ "name":"Power Supply Firmware",
326
+ "role":"",
327
+ "date":"",
328
+ "type":"Power Supply Firmware",
329
+ "build":"",
330
+ "version":"14"
331
+ }
332
+ ],
333
+ "machineType":"",
334
+ "hardwareRevision":"2.0",
335
+ "parent":{
336
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
337
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
338
+ },
339
+ "FRU":"69Y5831",
340
+ "uri":"powerSupply/C2890E051CFF11E200AB00AB00AB00AB",
341
+ "productId":"303",
342
+ "powerAllocation":{
343
+ "totalInputPower":0,
344
+ "totalOutputPower":0
345
+ },
346
+ "powerState":"Unknown",
347
+ "posID":"128",
348
+ "slots":[
349
+ 2
350
+ ],
351
+ "manufacturer":"IBM",
352
+ "vpdID":"70",
353
+ "uuid":"C2890E051CFF11E200AB00AB00AB00AB",
354
+ "productName":"IBM Flex System Enterprise Chassis 2100W Power Module",
355
+ "fruSerialNumber":"ZK11512AG03J",
356
+ "inputVoltageMax":240
357
+ }
358
+ ]
359
+ }
360
+ + Response 400
361
+ + Response 401
362
+ + Response 404
363
+ + Response 409
364
+ + Response 500
365
+
366
+ # GET /powerSupplies
367
+
368
+ + Response 200 (application/json)
369
+ {
370
+ "powerSupplyList":[
371
+ {
372
+ "model":"",
373
+ "manufacturerId":"20301",
374
+ "serialNumber":"",
375
+ "inputVoltageIsAC":true,
376
+ "inputVoltageMin":200,
377
+ "type":"PowerSupply",
378
+ "dataHandle":0,
379
+ "cmmDisplayName":"Power Supply 01",
380
+ "leds":[
381
+ {
382
+ "color":"Green",
383
+ "location":"Planar",
384
+ "name":"IN",
385
+ "state":"On"
386
+ },
387
+ {
388
+ "color":"Green",
389
+ "location":"Planar",
390
+ "name":"OUT",
391
+ "state":"On"
392
+ },
393
+ {
394
+ "color":"Amber",
395
+ "location":"Planar",
396
+ "name":"FAULT",
397
+ "state":"Off"
398
+ }
399
+ ],
400
+ "description":"2100W Power Supply",
401
+ "name":"Power Supply 01",
402
+ "cmmHealthState":"Normal",
403
+ "userDescription":"",
404
+ "manufactureDate":"5112",
405
+ "partNumber":"69Y5830",
406
+ "firmware":[
407
+ {
408
+ "status":"",
409
+ "name":"Power Supply Firmware",
410
+ "role":"",
411
+ "date":"",
412
+ "type":"Power Supply Firmware",
413
+ "build":"",
414
+ "version":"14"
415
+ }
416
+ ],
417
+ "machineType":"",
418
+ "hardwareRevision":"2.0",
419
+ "parent":{
420
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
421
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
422
+ },
423
+ "FRU":"69Y5831",
424
+ "uri":"powerSupply/735425074A8511E200FB00FB00FB00FB",
425
+ "productId":"303",
426
+ "powerAllocation":{
427
+ "totalInputPower":0,
428
+ "totalOutputPower":0
429
+ },
430
+ "powerState":"Unknown",
431
+ "posID":"128",
432
+ "slots":[
433
+ 1
434
+ ],
435
+ "manufacturer":"IBM",
436
+ "vpdID":"70",
437
+ "uuid":"735425074A8511E200FB00FB00FB00FB",
438
+ "productName":"IBM Flex System Enterprise Chassis 2100W Power Module",
439
+ "fruSerialNumber":"ZK11512CJ007",
440
+ "inputVoltageMax":240
441
+ },
442
+ {
443
+ "model":"",
444
+ "manufacturerId":"20301",
445
+ "serialNumber":"",
446
+ "inputVoltageIsAC":true,
447
+ "inputVoltageMin":200,
448
+ "type":"PowerSupply",
449
+ "dataHandle":0,
450
+ "cmmDisplayName":"Power Supply 02",
451
+ "leds":[
452
+ {
453
+ "color":"Green",
454
+ "location":"Planar",
455
+ "name":"IN",
456
+ "state":"On"
457
+ },
458
+ {
459
+ "color":"Green",
460
+ "location":"Planar",
461
+ "name":"OUT",
462
+ "state":"On"
463
+ },
464
+ {
465
+ "color":"Amber",
466
+ "location":"Planar",
467
+ "name":"FAULT",
468
+ "state":"Off"
469
+ }
470
+ ],
471
+ "description":"2100W Power Supply",
472
+ "name":"Power Supply 02",
473
+ "cmmHealthState":"Normal",
474
+ "userDescription":"",
475
+ "manufactureDate":"4212",
476
+ "partNumber":"69Y5830",
477
+ "firmware":[
478
+ {
479
+ "status":"",
480
+ "name":"Power Supply Firmware",
481
+ "role":"",
482
+ "date":"",
483
+ "type":"Power Supply Firmware",
484
+ "build":"",
485
+ "version":"14"
486
+ }
487
+ ],
488
+ "machineType":"",
489
+ "hardwareRevision":"2.0",
490
+ "parent":{
491
+ "uuid":"7F3E7E375B5747E0938969896B1CFDF5",
492
+ "uri":"chassis/7F3E7E375B5747E0938969896B1CFDF5"
493
+ },
494
+ "FRU":"69Y5831",
495
+ "uri":"powerSupply/C2890E051CFF11E200AB00AB00AB00AB",
496
+ "productId":"303",
497
+ "powerAllocation":{
498
+ "totalInputPower":0,
499
+ "totalOutputPower":0
500
+ },
501
+ "powerState":"Unknown",
502
+ "posID":"128",
503
+ "slots":[
504
+ 2
505
+ ],
506
+ "manufacturer":"IBM",
507
+ "vpdID":"70",
508
+ "uuid":"C2890E051CFF11E200AB00AB00AB00AB",
509
+ "productName":"IBM Flex System Enterprise Chassis 2100W Power Module",
510
+ "fruSerialNumber":"ZK11512AG03J",
511
+ "inputVoltageMax":240
512
+ }
513
+ ]
514
+ }
515
+ + Response 400
516
+ + Response 401
517
+ + Response 404
518
+ + Response 409
519
+ + Response 500