vmm: openapi: Add the /vm.counters API entry point

This is a hash table of string to hash tables of u64s. In JSON these
hash tables are object types.

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
Rob Bradford 2020-06-26 15:05:15 +01:00 committed by Samuel Ortiz
parent 72ae1577ed
commit 522d8c8412

View File

@ -42,6 +42,17 @@ paths:
schema: schema:
$ref: '#/components/schemas/VmInfo' $ref: '#/components/schemas/VmInfo'
/vm.counters:
get:
summary: Get counters from the VM
responses:
200:
description: The VM counters
content:
application/json:
schema:
$ref: '#/components/schemas/VmCounters'
/vm.create: /vm.create:
put: put:
summary: Create the cloud-hypervisor Virtual Machine (VM) instance. The instance is not booted, only created. summary: Create the cloud-hypervisor Virtual Machine (VM) instance. The instance is not booted, only created.
@ -335,6 +346,14 @@ components:
enum: [Created, Running, Shutdown, Paused] enum: [Created, Running, Shutdown, Paused]
description: Virtual Machine information description: Virtual Machine information
VmCounters:
type: object
additionalProperties:
type: object
additionalProperties:
type: integer
format: uint64
PciDeviceInfo: PciDeviceInfo:
required: required:
- id - id