Fix Swagger doc issues
This commit is contained in:
parent
f1b4593367
commit
212ecaab68
|
@ -838,25 +838,8 @@ class API_Faults(Resource):
|
||||||
---
|
---
|
||||||
tags:
|
tags:
|
||||||
- faults
|
- faults
|
||||||
parameters:
|
definitions:
|
||||||
- in: query
|
- schema:
|
||||||
name: sort_key
|
|
||||||
type: string
|
|
||||||
required: false
|
|
||||||
description: The fault object key to sort results by
|
|
||||||
enum:
|
|
||||||
- first_reported
|
|
||||||
- last_reported
|
|
||||||
- acknowledged_at
|
|
||||||
- status
|
|
||||||
- health_delta
|
|
||||||
- message
|
|
||||||
responses:
|
|
||||||
200:
|
|
||||||
description: OK
|
|
||||||
schema:
|
|
||||||
type: array
|
|
||||||
items:
|
|
||||||
type: object
|
type: object
|
||||||
id: fault
|
id: fault
|
||||||
properties:
|
properties:
|
||||||
|
@ -888,6 +871,26 @@ class API_Faults(Resource):
|
||||||
type: string
|
type: string
|
||||||
description: The textual description of the fault
|
description: The textual description of the fault
|
||||||
example: "Node hv1 was at 40% (psur@-10%, psql@-50%) <= 50% health"
|
example: "Node hv1 was at 40% (psur@-10%, psql@-50%) <= 50% health"
|
||||||
|
parameters:
|
||||||
|
- in: query
|
||||||
|
name: sort_key
|
||||||
|
type: string
|
||||||
|
required: false
|
||||||
|
description: The fault object key to sort results by
|
||||||
|
enum:
|
||||||
|
- first_reported
|
||||||
|
- last_reported
|
||||||
|
- acknowledged_at
|
||||||
|
- status
|
||||||
|
- health_delta
|
||||||
|
- message
|
||||||
|
responses:
|
||||||
|
200:
|
||||||
|
description: OK
|
||||||
|
schema:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
$ref: '#/definitions/fault'
|
||||||
"""
|
"""
|
||||||
return api_helper.fault_list(sort_key=reqargs.get("sort_key", "last_reported"))
|
return api_helper.fault_list(sort_key=reqargs.get("sort_key", "last_reported"))
|
||||||
|
|
||||||
|
@ -948,8 +951,6 @@ class API_Faults_Element(Resource):
|
||||||
schema:
|
schema:
|
||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
type: object
|
|
||||||
id: fault
|
|
||||||
$ref: '#/definitions/fault'
|
$ref: '#/definitions/fault'
|
||||||
"""
|
"""
|
||||||
return api_helper.fault_list(limit=fault_id)
|
return api_helper.fault_list(limit=fault_id)
|
||||||
|
@ -1625,7 +1626,7 @@ class API_VM_Root(Resource):
|
||||||
descrpition: Unix timestamp of the snapshot
|
descrpition: Unix timestamp of the snapshot
|
||||||
age:
|
age:
|
||||||
type: string
|
type: string
|
||||||
description: Human-readable age of the snapshot in the largest viable unit: seconds, minutes, hours, days
|
description: Human-readable age of the snapshot in the largest viable unit (seconds, minutes, hours, days)
|
||||||
rbd_snapshots:
|
rbd_snapshots:
|
||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
|
|
Loading…
Reference in New Issue