Upgrade GetNodes

This commit is contained in:
Quentin 2023-11-22 14:25:04 +01:00
parent d1d1940252
commit 9b24d7c402
Signed by untrusted user: quentin
GPG key ID: E9602264D639FF68

View file

@ -30,33 +30,53 @@ paths:
application/json: application/json:
schema: schema:
type: object type: object
required: [ node, garageVersion, knownNodes, layout ] required: [ node, garageVersion, garageFeatures, rustVersion, dbEngine, knownNodes, layout ]
properties: properties:
node: node:
type: string type: string
example: "ec79480e0ce52ae26fd00c9da684e4fa56658d9c64cdcecb094e936de0bfe71f" example: "ec79480e0ce52ae26fd00c9da684e4fa56658d9c64cdcecb094e936de0bfe71f"
garageVersion: garageVersion:
type: string type: string
example: "v0.7.3" example: "v0.9.0"
knownNodes: garageFeatures:
type: object type: array
items:
type: string
example: example:
"ec79480e0ce52ae26fd00c9da684e4fa56658d9c64cdcecb094e936de0bfe71f": - "k2v"
- "sled"
- "lmdb"
- "sqlite"
- "consul-discovery"
- "kubernetes-discovery"
- "metrics"
- "telemetry-otlp"
- "bundled-libs"
rustVersion:
type: string
example: "1.68.0"
dbEngine:
type: string
example: "LMDB (using Heed crate)"
knownNodes:
type: array
example:
- id: "ec79480e0ce52ae26fd00c9da684e4fa56658d9c64cdcecb094e936de0bfe71f"
addr: "10.0.0.11:3901" addr: "10.0.0.11:3901"
is_up: true isUp: true
last_seen_secs_ago: 9 lastSeenSecsAgo: 9
hostname: orion hostname: orion
"4a6ae5a1d0d33bf895f5bb4f0a418b7dc94c47c0dd2eb108d1158f3c8f60b0ff": - id: "4a6ae5a1d0d33bf895f5bb4f0a418b7dc94c47c0dd2eb108d1158f3c8f60b0ff"
addr: "10.0.0.12:3901" addr: "10.0.0.12:3901"
is_up: true isUp: true
last_seen_secs_ago: 13 lastSeenSecsAgo: 13
hostname: pegasus hostname: pegasus
"e2ee7984ee65b260682086ec70026165903c86e601a4a5a501c1900afe28d84b": - id: "e2ee7984ee65b260682086ec70026165903c86e601a4a5a501c1900afe28d84b"
addr: "10.0.0.13:3901" addr: "10.0.0.13:3901"
is_up: true isUp: true
last_seen_secs_ago: 2 lastSeenSecsAgo: 2
hostname: neptune hostname: neptune
additionalProperties: items:
$ref: '#/components/schemas/NodeNetworkInfo' $ref: '#/components/schemas/NodeNetworkInfo'
layout: layout:
$ref: '#/components/schemas/ClusterLayout' $ref: '#/components/schemas/ClusterLayout'
@ -1007,15 +1027,18 @@ components:
schemas: schemas:
NodeNetworkInfo: NodeNetworkInfo:
type: object type: object
required: [ addr, is_up, last_seen_secs_ago, hostname ] required: [ addr, isUp, lastSeenSecsAgo, hostname ]
properties: properties:
id:
type: string
example: "6a8e08af2aab1083ebab9b22165ea8b5b9d333b60a39ecd504e85cc1f432c36f"
addr: addr:
type: string type: string
example: "10.0.0.11:3901" example: "10.0.0.11:3901"
is_up: isUp:
type: boolean type: boolean
example: true example: true
last_seen_secs_ago: lastSeenSecsAgo:
type: integer type: integer
nullable: true nullable: true
example: 9 example: 9
@ -1024,7 +1047,7 @@ components:
example: "node1" example: "node1"
NodeClusterInfo: NodeClusterInfo:
type: object type: object
required: [ zone, capacity, tags ] required: [ id, zone, tags ]
properties: properties:
zone: zone:
type: string type: string
@ -1050,30 +1073,30 @@ components:
type: integer type: integer
example: 12 example: 12
roles: roles:
type: object type: array
example: example:
"ec79480e0ce52ae26fd00c9da684e4fa56658d9c64cdcecb094e936de0bfe71f": - id: "ec79480e0ce52ae26fd00c9da684e4fa56658d9c64cdcecb094e936de0bfe71f"
zone: "madrid" zone: "madrid"
capacity: 3 capacity: 3
tags: tags:
- fast - fast
- amd64 - amd64
"4a6ae5a1d0d33bf895f5bb4f0a418b7dc94c47c0dd2eb108d1158f3c8f60b0ff": - id: "4a6ae5a1d0d33bf895f5bb4f0a418b7dc94c47c0dd2eb108d1158f3c8f60b0ff"
zone: "geneva" zone: "geneva"
capacity: 7 capacity: 7
tags: tags:
- arm64 - arm64
additionalProperties: items:
$ref: '#/components/schemas/NodeClusterInfo' $ref: '#/components/schemas/NodeClusterInfo'
stagedRoleChanges: stagedRoleChanges:
type: object type: array
example: example:
"e2ee7984ee65b260682086ec70026165903c86e601a4a5a501c1900afe28d84b": - id: "e2ee7984ee65b260682086ec70026165903c86e601a4a5a501c1900afe28d84b"
zone: "geneva" zone: "geneva"
capacity: 4 capacity: 4
tags: tags:
- gateway - gateway
additionalProperties: items:
$ref: '#/components/schemas/NodeClusterInfo' $ref: '#/components/schemas/NodeClusterInfo'
LayoutVersion: LayoutVersion:
type: object type: object