Skip to content

Commit

Permalink
chore: Addressed review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinshahfws committed Jun 20, 2024
1 parent ff9dced commit 602ed5c
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 105 deletions.
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

148 changes: 46 additions & 102 deletions src/openrpc/certificationextension.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"methods": [
{
"name": "onFireboltInteractions",
"summary": "",
"summary": "Event to fetch the interaction details for the firebolt api call",
"tags": [
{
"name": "event"
Expand All @@ -29,24 +29,12 @@
},
"examples": [
{
"name": "Firebolt interaction to acquire platform token",
"name": "Firebolt interaction to acquire device token",
"params": [],
"result": {
"name": "event",
"name": "Default Result",
"value": {
"interactionRequest": {
"id": "1",
"jsonrpc": "2.0",
"method": "token",
"params": {
"type": "platform"
}
},
"interactionResponse": {
"id": "1",
"jsonrpc": "2.0",
"state": true
}
"payload": "{\"request\":{\"type\":\"method\",\"method\":\"Authentication.device\"},\"response\":\"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c\"}"
}
}
}
Expand Down Expand Up @@ -98,7 +86,7 @@
}
],
"result": {
"name": "success",
"name": "Default Result",
"value": true
}
}
Expand Down Expand Up @@ -157,15 +145,15 @@
}
],
"result": {
"name": "success",
"name": "Default Result",
"value": true
}
}
]
},
{
"name": "healthCheck",
"summary": "",
"name": "platformHealthCheck",
"summary": "Health check for the device and process. It provides the load, memory, cpu usage and total live firebolt connections.",
"tags": [
{
"name": "capabilities",
Expand All @@ -188,19 +176,21 @@
"result": {
"name": "healthCheckResult",
"value": {
"load": 0.5,
"deviceMemory": 0.5,
"processMemory": 0.5,
"cpu": 0.5,
"connections": 10
"cpuLoad1minAverage": 2.2,
"cpuLoad5minAverage": 1.8,
"deviceMemoryUsed": 886,
"deviceMemoryLimit": 1024,
"processMemoryPSS": 500,
"processMemoryRSS": 600,
"activeConnections": 10
}
}
}
]
},
{
"name": "appPerformance",
"summary": "",
"name": "appHealthCheck",
"summary": "App healthCheck",
"tags": [
{
"name": "capabilities",
Expand Down Expand Up @@ -251,70 +241,14 @@
"title": "InteractionResult",
"type": "object",
"required": [
"interactionRequest",
"interactionResponse"
"payload"
],
"properties": {
"interactionRequest": {
"type": "object",
"required": [
"method",
"params"
],
"properties": {
"method": {
"type": "string",
"description": "The method name"
},
"params": {
"oneOf": [
{
"type": "object",
"description": "JSON object that represents the interaction request"
},
{
"const": null
}
]
}
},
"description": "JSON object that represents the interaction request"
},
"interactionResponse": {
"type": "object",
"required": [
"state"
],
"properties": {
"method": {
"type": "string",
"description": "The method name"
},
"state": {
"type": "boolean",
"description": "The state of the response whether it is success or failure"
}
},
"description": "JSON object that represents the state of the interaction response"
}
},
"examples": [
{
"interactionRequest": {
"id": "1",
"jsonrpc": "2.0",
"method": "token",
"params": {
"type": "platform"
}
},
"interactionResponse": {
"id": "1",
"jsonrpc": "2.0",
"state": true
}
"payload": {
"type": "string",
"description": "The stringyfy payload of the interaction contains firebolt api request and response"
}
]
}
},
"PlatformIntent": {
"title": "PlatformIntent",
Expand All @@ -330,32 +264,42 @@
"description": "Performance and healthcheck snapshot for the device and process which includes load, memory, cpu usage. It also provides total live firebolt connections.",
"type": "object",
"required": [
"load",
"processMemory",
"cpu",
"deviceMemory",
"connections"
"cpuLoad1minAverage",
"cpuLoad5minAverage",
"deviceMemoryUsed",
"deviceMemoryLimit",
"processMemoryPSS",
"processMemoryRSS",
"activeConnections"
],
"properties": {
"load": {
"cpuLoad1minAverage": {
"type": "number",
"description": "The load average of the system"
"description": "The load average of the system for 1 min, typically known as short term load."
},
"processMemory": {
"cpuLoad5minAverage": {
"type": "number",
"description": "The memory usage of the process"
"description": "The load average of the system for 5 min, typically known as mid term load."
},
"cpu": {
"processMemoryPSS": {
"type": "number",
"description": "Process memory usage as proportional set size (PSS) in KB. This data provides a way to account for memory shared between processes more accurately"
},
"processMemoryRSS": {
"type": "number",
"description": "The cpu usage of the system"
"description": "Process memory usage as resident set size (RSS) in KB. It represents the portion of a process's memory that is held in RAM"
},
"deviceMemory": {
"deviceMemoryUsed": {
"type": "number",
"description": "The memory usage of the device"
},
"connections": {
"deviceMemoryLimit": {
"type": "number",
"description": "Total memory limit of the device"
},
"activeConnections": {
"type": "number",
"description": "The total number of live firebolt connections"
"description": "The total number of active firebolt connections"
}
}
},
Expand Down

0 comments on commit 602ed5c

Please sign in to comment.