System Service¶
The System Service is a gRPC & Go based system resource tracker and system controller.
Table of Contents¶
System.proto¶
Cpu¶
Cpu type contains Cpu utilization at the current moment.
| Field | Type | Label | Description |
|---|---|---|---|
| usedCpuPercentage | float | Percentage of used CPU e.g: 20.0 | |
| freeCpuPercentage | float | Percentage of available CPU e.g: 80.0 | |
| coreCount | int32 | Total available core count for CPU.e.g 2C/4T CPU value will be 4 | |
| modelInfo | string | intel x64 etc.. |
FirmwareInfo¶
FirmwareInfo contains Firmware Version.
| Field | Type | Label | Description |
|---|---|---|---|
| version | string | Firmware version. |
Limits¶
System Limits for the Edge Runtime.
| Field | Type | Label | Description |
|---|---|---|---|
| maxInstalledApplications | int32 | Maximum allowed number of installed Edge applications. | |
| maxRunningApplications | int32 | Maximum allowed number of running Edge applications. | |
| maxMemoryUsageInGB | float | Maximum allowed memory usage in Gigabytes. | |
| maxStorageUsageInGB | float | Maximum allowed disk usage in Gigabytes. | |
| maxCpuUsagePerecentage | float | Maximum allowed percentage of CPU usage. |
LogRequest¶
LogRequest type, determines the destination path for saving log file.
| Field | Type | Label | Description |
|---|---|---|---|
| saveFolderPath | string | Folder path for saving gathered logs. |
LogResponse¶
LogResponse type, contains the full path for the collected log archive.
| Field | Type | Label | Description |
|---|---|---|---|
| logPath | string | Full file path for collected log archive. |
ModelNumber¶
ModelNumber type indicates device specific model information.
| Field | Type | Label | Description |
|---|---|---|---|
| modelNumber | string | Can be MLFB for SIEMENS devices, for 3rd party vendors it can be any model information. |
Resource¶
System Resource , memory or storage.
| Field | Type | Label | Description |
|---|---|---|---|
| totalSpaceInGB | float | Total capacity of storage device in Gigabytes e.g: 3.5 | |
| freeSpaceInGB | float | Free space of storage device in Gigabytes e.g: 40.4 | |
| usedSpaceInGB | float | Used space of storage device in Gigabytes e.g: 23.2 | |
| percentageFreeSpace | float | Percentage of available space e.g: 3.5 | |
| percentageUsedSpace | float | Percentage of used space e.g: 96.5 |
Stats¶
System Utilization type. Cpu, storage and memory utilization.
| Field | Type | Label | Description |
|---|---|---|---|
| cpu | Cpu | Cpu Utilization | |
| storageDevices | Resource | repeated | StorageDevices array of Resource type. |
| memory | Resource | RAM Utilization Information | |
| upTime | string | Elapsed time since the device is started. |
SystemService¶
System service ,uses a UNIX Domain Socket "/var/run/devicemodel/system.sock" for GRPC communication. protoc generates both client and server instance for this Service. GRPC Status codes : https://developers.google.com/maps-booking/reference/grpc-api/status_codes .
| Method Name | Request Type | Response Type | Description |
|---|---|---|---|
| RestartDevice | .google.protobuf.Empty | .google.protobuf.Empty | Restarts the device |
| ShutdownDevice | .google.protobuf.Empty | .google.protobuf.Empty | ShutsDown the device. |
| HardReset | .google.protobuf.Empty | .google.protobuf.Empty | Performs host side actions in addition to edge-core for hard reset. e.g: cleaning hard-reset flag(mandatory) ,custom Device Builder steps(optional) and finally reboots the system(mandatory). |
| GetModelNumber | .google.protobuf.Empty | ModelNumber | Returns model number (mlfb) for siemens or any type model for 3rd party vendors. |
| GetFirmwareInfo | .google.protobuf.Empty | FirmwareInfo | Returns firmware information of currently installed firmware |
| GetResourceStats | .google.protobuf.Empty | Stats | Returns current Cpu, Memory, Uptime and Storage usage |
| GetLimits | .google.protobuf.Empty | Limits | Returns limits for how many applications and how much cpu, ram and storage should be available for applications. |
| GetCustomSettings | .google.protobuf.Empty | .google.protobuf.Any | Returns device specific custom settings. |
| ApplyCustomSettings | .google.protobuf.Any | .google.protobuf.Empty | Applies device specific custom settings. |
| GetLogFile | LogRequest | LogResponse | Collects and compress all Journald logs (mandatory) from host ,(plus optional device specific log/report) and then returns a single file path for this new log archive. |