Resource URL: /platform/<<version=1>>/storagepool/status

    Overview: This resource gathers the health status of the OneFS pool system
              as a whole.

     Methods: GET

********************************************************************************

Method GET: List any health conditions detected.

       URL: GET /platform/<<version=1>>/storagepool/status

There are no query arguments for this method.

GET response body schema:
{
  "type": [
    {
      "additionalProperties": false, 
      "type": "object", 
      "description": "A list of errors that may be returned.", 
      "properties": {
        "errors": {
          "items": {
            "additionalProperties": false, 
            "type": "object", 
            "description": "An object describing a single error.", 
            "properties": {
              "field": {
                "type": "string", 
                "description": "The field with the error if applicable."
              }, 
              "message": {
                "type": "string", 
                "description": "The error message."
              }, 
              "code": {
                "type": "string", 
                "description": "The error code."
              }
            }
          }, 
          "type": "array"
        }
      }
    }, 
    {
      "type": "object", 
      "properties": {
        "unprovisioned": {
          "items": {
            "type": "object", 
            "properties": {
              "lnn": {
                "required": true, 
                "type": "integer", 
                "description": "The node the drive is on."
              }, 
              "bay": {
                "required": true, 
                "type": "integer", 
                "description": "The drive bay number."
              }
            }
          }, 
          "required": true, 
          "type": "array", 
          "description": "Drives which are not currently provisioned into a disk pool."
        }, 
        "unhealthy": {
          "items": {
            "type": "object", 
            "properties": {
              "diskpool": {
                "type": "object", 
                "properties": {
                  "ssd_drives": {
                    "items": {
                      "type": "object", 
                      "properties": {
                        "lnn": {
                          "required": true, 
                          "type": "integer", 
                          "description": "The node the drive is on."
                        }, 
                        "bay": {
                          "required": true, 
                          "type": "integer", 
                          "description": "The drive bay number."
                        }
                      }
                    }, 
                    "required": true, 
                    "type": "array", 
                    "description": "The SSDs that are part of this disk pool."
                  }, 
                  "name": {
                    "required": true, 
                    "type": "string", 
                    "description": "The disk pool name."
                  }, 
                  "drives": {
                    "items": {
                      "type": "object", 
                      "properties": {
                        "lnn": {
                          "required": true, 
                          "type": "integer", 
                          "description": "The node the drive is on."
                        }, 
                        "bay": {
                          "required": true, 
                          "type": "integer", 
                          "description": "The drive bay number."
                        }
                      }
                    }, 
                    "required": true, 
                    "type": "array", 
                    "description": "The drives that are part of this disk pool."
                  }, 
                  "protection_policy": {
                    "required": true, 
                    "type": "string", 
                    "description": "The protection policy for the disk pool."
                  }, 
                  "nodepool_id": {
                    "required": true, 
                    "type": [
                      "integer", 
                      "null"
                    ], 
                    "description": "The system ID of the disk pool's node pool, if it is in a node pool."
                  }, 
                  "id": {
                    "required": true, 
                    "type": "integer", 
                    "description": "The system ID given to the disk pool."
                  }
                }
              }, 
              "health_flags": {
                "items": {
                  "enum": [
                    "underprovisioned", 
                    "missing_drives", 
                    "devices_down", 
                    "devices_smartfailed", 
                    "waiting_repair"
                  ], 
                  "type": "string"
                }, 
                "type": "array", 
                "description": "An array of containing any health issues with this pool.  If the pool is healthy, the list is empty."
              }, 
              "affected": {
                "items": {
                  "type": "object", 
                  "properties": {
                    "device": {
                      "required": true, 
                      "type": [
                        "integer", 
                        {
                          "type": "object", 
                          "properties": {
                            "lnn": {
                              "required": true, 
                              "type": "integer", 
                              "description": "The node the drive is on."
                            }, 
                            "bay": {
                              "required": true, 
                              "type": "integer", 
                              "description": "The drive bay number."
                            }
                          }
                        }
                      ], 
                      "description": "The logical node number or drive identifier."
                    }, 
                    "down": {
                      "required": true, 
                      "type": "boolean", 
                      "description": "Whether or not the device is currently down."
                    }, 
                    "restriping": {
                      "required": true, 
                      "type": "boolean", 
                      "description": "Whether or not the device is currently being repaired."
                    }, 
                    "type": {
                      "enum": [
                        "node", 
                        "drive"
                      ], 
                      "type": "string", 
                      "description": "The type of affected device.", 
                      "required": true
                    }, 
                    "smartfailed": {
                      "required": true, 
                      "type": "boolean", 
                      "description": "Whether or not the device is currently smartfailed."
                    }
                  }
                }, 
                "required": true, 
                "type": "array", 
                "description": "The affected nodes and/or drives."
              }
            }
          }, 
          "required": true, 
          "type": "array", 
          "description": "Disk pools which are currently unhealthy."
        }
      }
    }
  ]
}
