Created
August 21, 2021 02:22
-
-
Save dunithd/155166133b316d7f2da4f24642ab5264 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
asyncapi: '2.0.0' | |
info: | |
title: Metrics Service | |
version: 1.0.0 | |
description: This service is in charge of providing health data for a computer cluster | |
servers: | |
production: | |
url: 'ws://localhost:8080' | |
protocol: ws | |
channels: | |
metrics/{machineId}/memory: | |
parameters: | |
machineId: | |
$ref: '#/components/parameters/machineId' | |
subscribe: | |
message: | |
$ref: '#/components/messages/MemoryInfo' | |
metrics/{machineId}/cpu: | |
parameters: | |
machineId: | |
$ref: '#/components/parameters/machineId' | |
subscribe: | |
message: | |
$ref: '#/components/messages/CPUInfo' | |
components: | |
messages: | |
MemoryInfo: | |
payload: | |
type: object | |
properties: | |
timestamp: | |
type: integer | |
format: int64 | |
description: Timestamp when the measurement was taken | |
heap: | |
type: string | |
description: Amount of heap memory | |
nonHeap: | |
type: string | |
description: Amount of non-heap memory | |
CPUInfo: | |
payload: | |
type: object | |
properties: | |
timestamp: | |
type: integer | |
format: int64 | |
description: Timestamp when the measurement was taken | |
utilized: | |
type: string | |
description: Current CPU utilization | |
parameters: | |
machineId: | |
description: Id of the machine. | |
schema: | |
type: string |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment