Adapt Cluster schema

Add remove boolean to subClusterConfig in MetricList.
Fix Linter errors.
This commit is contained in:
2023-03-21 11:51:11 +01:00
parent 747f6d4e2d
commit 5d526e1168
6 changed files with 1150 additions and 326 deletions

View File

@@ -27,18 +27,17 @@ type MetricValue struct {
}
type SubCluster struct {
Name string `json:"name"`
Nodes string `json:"nodes"`
NumberOfNodes int `json:"numberOfNodes"`
ProcessorType string `json:"processorType"`
SocketsPerNode int `json:"socketsPerNode"`
CoresPerSocket int `json:"coresPerSocket"`
ThreadsPerCore int `json:"threadsPerCore"`
FlopRateScalar *MetricValue `json:"flopRateScalar"`
FlopRateSimd *MetricValue `json:"flopRateSimd"`
MemoryBandwidth *MetricValue `json:"memoryBandwidth"`
Topology *Topology `json:"topology"`
MetricConfig []*MetricConfig `json:"metricConfig"`
Name string `json:"name"`
Nodes string `json:"nodes"`
NumberOfNodes int `json:"numberOfNodes"`
ProcessorType string `json:"processorType"`
SocketsPerNode int `json:"socketsPerNode"`
CoresPerSocket int `json:"coresPerSocket"`
ThreadsPerCore int `json:"threadsPerCore"`
FlopRateScalar *MetricValue `json:"flopRateScalar"`
FlopRateSimd *MetricValue `json:"flopRateSimd"`
MemoryBandwidth *MetricValue `json:"memoryBandwidth"`
Topology *Topology `json:"topology"`
}
type SubClusterConfig struct {
@@ -47,6 +46,7 @@ type SubClusterConfig struct {
Normal float64 `json:"normal"`
Caution float64 `json:"caution"`
Alert float64 `json:"alert"`
Remove bool `json:"remove"`
}
type MetricConfig struct {

View File

@@ -76,13 +76,13 @@
},
"alert": {
"type": "number"
},
"remove": {
"type": "boolean"
}
},
"required": [
"name",
"peak",
"caution",
"alert"
"name"
]
}
}
@@ -261,6 +261,7 @@
},
"required": [
"name",
"nodes",
"topology",
"processorType",
"socketsPerNode",