add vcenter totals line graph
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -854,6 +854,73 @@ const docTemplate = `{
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/vcenters": {
|
||||
"get": {
|
||||
"description": "Lists all vCenters with recorded snapshot totals.",
|
||||
"produces": [
|
||||
"text/html"
|
||||
],
|
||||
"tags": [
|
||||
"vcenters"
|
||||
],
|
||||
"summary": "List vCenters",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "HTML page",
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/vcenters/totals": {
|
||||
"get": {
|
||||
"description": "Shows per-snapshot totals for a vCenter.",
|
||||
"produces": [
|
||||
"text/html"
|
||||
],
|
||||
"tags": [
|
||||
"vcenters"
|
||||
],
|
||||
"summary": "vCenter totals",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "string",
|
||||
"description": "vCenter URL",
|
||||
"name": "vcenter",
|
||||
"in": "query",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"type": "string",
|
||||
"description": "hourly|daily|monthly (default: hourly)",
|
||||
"name": "type",
|
||||
"in": "query"
|
||||
},
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Limit results (default 200)",
|
||||
"name": "limit",
|
||||
"in": "query"
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "HTML page",
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"400": {
|
||||
"description": "Missing vcenter",
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"definitions": {
|
||||
|
||||
@@ -843,6 +843,73 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/vcenters": {
|
||||
"get": {
|
||||
"description": "Lists all vCenters with recorded snapshot totals.",
|
||||
"produces": [
|
||||
"text/html"
|
||||
],
|
||||
"tags": [
|
||||
"vcenters"
|
||||
],
|
||||
"summary": "List vCenters",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "HTML page",
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/vcenters/totals": {
|
||||
"get": {
|
||||
"description": "Shows per-snapshot totals for a vCenter.",
|
||||
"produces": [
|
||||
"text/html"
|
||||
],
|
||||
"tags": [
|
||||
"vcenters"
|
||||
],
|
||||
"summary": "vCenter totals",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "string",
|
||||
"description": "vCenter URL",
|
||||
"name": "vcenter",
|
||||
"in": "query",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"type": "string",
|
||||
"description": "hourly|daily|monthly (default: hourly)",
|
||||
"name": "type",
|
||||
"in": "query"
|
||||
},
|
||||
{
|
||||
"type": "integer",
|
||||
"description": "Limit results (default 200)",
|
||||
"name": "limit",
|
||||
"in": "query"
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "HTML page",
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"400": {
|
||||
"description": "Missing vcenter",
|
||||
"schema": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"definitions": {
|
||||
|
||||
@@ -720,4 +720,48 @@ paths:
|
||||
summary: List monthly snapshots
|
||||
tags:
|
||||
- snapshots
|
||||
/vcenters:
|
||||
get:
|
||||
description: Lists all vCenters with recorded snapshot totals.
|
||||
produces:
|
||||
- text/html
|
||||
responses:
|
||||
"200":
|
||||
description: HTML page
|
||||
schema:
|
||||
type: string
|
||||
summary: List vCenters
|
||||
tags:
|
||||
- vcenters
|
||||
/vcenters/totals:
|
||||
get:
|
||||
description: Shows per-snapshot totals for a vCenter.
|
||||
parameters:
|
||||
- description: vCenter URL
|
||||
in: query
|
||||
name: vcenter
|
||||
required: true
|
||||
type: string
|
||||
- description: 'hourly|daily|monthly (default: hourly)'
|
||||
in: query
|
||||
name: type
|
||||
type: string
|
||||
- description: Limit results (default 200)
|
||||
in: query
|
||||
name: limit
|
||||
type: integer
|
||||
produces:
|
||||
- text/html
|
||||
responses:
|
||||
"200":
|
||||
description: HTML page
|
||||
schema:
|
||||
type: string
|
||||
"400":
|
||||
description: Missing vcenter
|
||||
schema:
|
||||
type: string
|
||||
summary: vCenter totals
|
||||
tags:
|
||||
- vcenters
|
||||
swagger: "2.0"
|
||||
|
||||
@@ -66,6 +66,8 @@ func New(logger *slog.Logger, database db.Database, buildTime string, sha1ver st
|
||||
mux.HandleFunc("/api/snapshots/hourly/force", h.SnapshotForceHourly)
|
||||
mux.HandleFunc("/api/snapshots/migrate", h.SnapshotMigrate)
|
||||
mux.HandleFunc("/api/snapshots/regenerate-hourly-reports", h.SnapshotRegenerateHourlyReports)
|
||||
mux.HandleFunc("/vcenters", h.VcenterList)
|
||||
mux.HandleFunc("/vcenters/totals", h.VcenterTotals)
|
||||
mux.HandleFunc("/metrics", h.Metrics)
|
||||
|
||||
mux.HandleFunc("/snapshots/hourly", h.SnapshotHourlyList)
|
||||
|
||||
Reference in New Issue
Block a user