Cleanup and dashboard fixes and improvements.
This commit is contained in:
parent
6699566fba
commit
2967f6ef75
27
CHANGELOG.md
27
CHANGELOG.md
|
@ -2,40 +2,35 @@
|
|||
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
## [1.4.2] - 2023-01-05
|
||||
## 1.4.3 - 2023-03-21
|
||||
- Fix and improve processor utilization dashboards.
|
||||
- Minor code cleanup.
|
||||
|
||||
## 1.4.2 - 2023-01-05
|
||||
- Fix error in SR-IOV port type being null.
|
||||
|
||||
## [1.4.1] - 2022-12-15
|
||||
## 1.4.1 - 2022-12-15
|
||||
- Retrieve multiple PCM samples and keep track of processing.
|
||||
- Rename VIOS metric 'vFC' (storage adapter) to 'virtual'.
|
||||
|
||||
## [1.4.0] - 2022-12-01
|
||||
## 1.4.0 - 2022-12-01
|
||||
- Rewrite of toml+xml+json de-serialization code (uses jackson now).
|
||||
- Changes to configuration file format - please look at [doc/hmci.toml](doc/hmci.toml) as example.
|
||||
- Logging (write to file) JSON output from HMC is currently not possible.
|
||||
|
||||
## [1.3.3] - 2022-09-20
|
||||
## 1.3.3 - 2022-09-20
|
||||
- Default configuration location on Windows platform.
|
||||
- Process LPAR SR-IOV logical network ports data
|
||||
- Update default dashboards
|
||||
- Update documentation
|
||||
|
||||
## [1.3.0] - 2022-02-04
|
||||
## 1.3.0 - 2022-02-04
|
||||
- Correct use of InfluxDB batch writing.
|
||||
|
||||
## [1.2.8] - 2022-02-28
|
||||
## 1.2.8 - 2022-02-28
|
||||
- Sort measurement tags before writing to InfluxDB.
|
||||
- Update 3rd party dependencies.
|
||||
|
||||
|
||||
## [1.2.7] - 2022-02-24
|
||||
## 1.2.7 - 2022-02-24
|
||||
- Options to include/exclude Managed Systems and/or Logical Partitions.
|
||||
|
||||
[1.4.2]: https://bitbucket.org/mnellemann/hmci/branches/compare/v1.4.2%0Dv1.4.1
|
||||
[1.4.1]: https://bitbucket.org/mnellemann/hmci/branches/compare/v1.4.1%0Dv1.4.0
|
||||
[1.4.0]: https://bitbucket.org/mnellemann/hmci/branches/compare/v1.4.0%0Dv1.3.3
|
||||
[1.3.3]: https://bitbucket.org/mnellemann/hmci/branches/compare/v1.3.3%0Dv1.3.0
|
||||
[1.3.0]: https://bitbucket.org/mnellemann/hmci/branches/compare/v1.3.0%0Dv1.2.8
|
||||
[1.2.8]: https://bitbucket.org/mnellemann/hmci/branches/compare/v1.2.8%0Dv1.2.7
|
||||
[1.2.7]: https://bitbucket.org/mnellemann/hmci/branches/compare/v1.2.7%0Dv1.2.6
|
||||
[1.2.6]: https://bitbucket.org/mnellemann/hmci/branches/compare/v1.2.6%0Dv1.2.5
|
||||
|
|
|
@ -390,7 +390,7 @@
|
|||
"measurement": "lpar_details",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"query": "SELECT last(\"weight\") AS \"Weight\", last(\"mode\") AS \"Mode\", last(\"entitledProcUnits\") AS \"eCPU\", mean(\"utilizedProcUnits\") / mean(\"entitledProcUnits\")*100 AS \"Utilization eCPU\", last(\"currentVirtualProcessors\") AS \"vCPU\", mean(\"utilizedProcUnits\") / mean(\"maxProcUnits\") * 100 AS \"Utilization vCPU\" FROM \"lpar_processor\" WHERE (\"servername\" =~ /^$ServerName$/) AND (\"lparname\" =~ /^$LPAR$/) AND $timeFilter GROUP BY \"lparname\" fill(previous)",
|
||||
"query": "SELECT last(\"weight\") AS \"Weight\", last(\"mode\") AS \"Mode\", last(\"entitledProcUnits\") AS \"eCPU\", mean(\"utilizedProcUnits\") / mean(\"entitledProcUnits\")*100 AS \"Utilization eCPU\", last(\"currentVirtualProcessors\") AS \"vCPU\", mean(\"utilizedProcUnits\") / mean(\"currentVirtualProcessors\") * 100 AS \"Utilization vCPU\" FROM \"lpar_processor\" WHERE (\"servername\" =~ /^$ServerName$/) AND (\"lparname\" =~ /^$LPAR$/) AND $timeFilter GROUP BY \"lparname\" fill(previous)",
|
||||
"queryType": "randomWalk",
|
||||
"rawQuery": true,
|
||||
"refId": "A",
|
||||
|
@ -534,6 +534,7 @@
|
|||
"type": "influxdb",
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
"defaults": {
|
||||
"color": {
|
||||
|
@ -640,7 +641,7 @@
|
|||
"measurement": "/^$ServerName$/",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"query": "SELECT (mean(\"utilizedProcUnits\") / mean(\"maxProcUnits\")) * 100 AS \"usage\" FROM \"lpar_processor\" WHERE (\"servername\" =~ /^$ServerName$/ AND \"lparname\" =~ /^$LPAR$/) AND $timeFilter GROUP BY time($interval), \"lparname\", \"servername\" fill(linear)",
|
||||
"query": "SELECT (mean(\"utilizedProcUnits\") / mean(\"entitledProcUnits\")) * 100 AS \"usage\" FROM \"lpar_processor\" WHERE (\"servername\" =~ /^$ServerName$/ AND \"lparname\" =~ /^$LPAR$/) AND $timeFilter GROUP BY time($interval), \"lparname\", \"servername\" fill(linear)",
|
||||
"rawQuery": true,
|
||||
"refId": "A",
|
||||
"resultFormat": "time_series",
|
||||
|
@ -661,7 +662,7 @@
|
|||
"tags": []
|
||||
}
|
||||
],
|
||||
"title": "Processor Units - Utilization Percentage",
|
||||
"title": "Processor Units - Utilization / Entitled Percentage",
|
||||
"transformations": [],
|
||||
"type": "timeseries"
|
||||
},
|
||||
|
@ -2710,6 +2711,6 @@
|
|||
"timezone": "browser",
|
||||
"title": "HMCi - Power LPAR Overview",
|
||||
"uid": "Xl7oHESGz",
|
||||
"version": 4,
|
||||
"version": 3,
|
||||
"weekStart": ""
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"__inputs": [
|
||||
{
|
||||
"name": "DS_INFLUXDB",
|
||||
"name": "DS_HMCI",
|
||||
"label": "Database",
|
||||
"description": "",
|
||||
"type": "datasource",
|
||||
|
@ -15,7 +15,7 @@
|
|||
"type": "grafana",
|
||||
"id": "grafana",
|
||||
"name": "Grafana",
|
||||
"version": "9.1.3"
|
||||
"version": "9.1.6"
|
||||
},
|
||||
{
|
||||
"type": "datasource",
|
||||
|
@ -71,7 +71,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"gridPos": {
|
||||
"h": 3,
|
||||
|
@ -84,12 +84,12 @@
|
|||
"content": "## Metrics collected from IBM Power HMC\n \nFor more information visit: [git.data.coop/nellemann/hmci](https://git.data.coop/nellemann/hmci)\n ",
|
||||
"mode": "markdown"
|
||||
},
|
||||
"pluginVersion": "9.1.3",
|
||||
"pluginVersion": "9.1.6",
|
||||
"targets": [
|
||||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"refId": "A"
|
||||
}
|
||||
|
@ -100,7 +100,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
|
@ -189,7 +189,7 @@
|
|||
"alias": "$tag_lparname",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
|
@ -209,7 +209,7 @@
|
|||
"measurement": "/^$ServerName$/",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"query": "SELECT mean(\"utilizedProcUnits\") / mean(\"maxProcUnits\") AS \"usage\" FROM \"lpar_processor\" WHERE (\"servername\" =~ /^$ServerName$/ AND \"lparname\" =~ /^$LPAR$/) AND $timeFilter GROUP BY time($interval), \"lparname\", \"servername\" fill(none)",
|
||||
"query": "SELECT mean(\"utilizedProcUnits\") / mean(\"currentVirtualProcessors\") AS \"usage\" FROM \"lpar_processor\" WHERE (\"servername\" =~ /^$ServerName$/ AND \"lparname\" =~ /^$LPAR$/) AND $timeFilter GROUP BY time($interval), \"lparname\", \"servername\" fill(none)",
|
||||
"rawQuery": true,
|
||||
"refId": "A",
|
||||
"resultFormat": "time_series",
|
||||
|
@ -237,7 +237,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
|
@ -319,7 +319,7 @@
|
|||
"alias": "$tag_servername - $tag_lparname ($col)",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
|
@ -419,7 +419,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
|
@ -497,7 +497,7 @@
|
|||
"alias": "$tag_servername - $tag_lparname ($col)",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
|
@ -620,7 +620,7 @@
|
|||
"current": {},
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"definition": "SHOW TAG VALUES FROM \"server_processor\" WITH KEY = \"servername\" WHERE time > now() - 24h",
|
||||
"hide": 0,
|
||||
|
@ -644,7 +644,7 @@
|
|||
"current": {},
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"definition": "SHOW TAG VALUES FROM \"lpar_processor\" WITH KEY = \"lparname\" WHERE servername =~ /$ServerName/",
|
||||
"hide": 0,
|
||||
|
@ -697,6 +697,6 @@
|
|||
"timezone": "browser",
|
||||
"title": "HMCi - Power LPAR Utilization",
|
||||
"uid": "jFsbpTH4k",
|
||||
"version": 4,
|
||||
"version": 2,
|
||||
"weekStart": ""
|
||||
}
|
||||
|
|
|
@ -115,6 +115,370 @@
|
|||
"transparent": true,
|
||||
"type": "text"
|
||||
},
|
||||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
"defaults": {
|
||||
"color": {
|
||||
"mode": "palette-classic"
|
||||
},
|
||||
"custom": {
|
||||
"axisCenteredZero": false,
|
||||
"axisColorMode": "text",
|
||||
"axisLabel": "cores",
|
||||
"axisPlacement": "auto",
|
||||
"barAlignment": 0,
|
||||
"drawStyle": "line",
|
||||
"fillOpacity": 10,
|
||||
"gradientMode": "opacity",
|
||||
"hideFrom": {
|
||||
"legend": false,
|
||||
"tooltip": false,
|
||||
"viz": false
|
||||
},
|
||||
"lineInterpolation": "linear",
|
||||
"lineWidth": 1,
|
||||
"pointSize": 5,
|
||||
"scaleDistribution": {
|
||||
"type": "linear"
|
||||
},
|
||||
"showPoints": "never",
|
||||
"spanNulls": false,
|
||||
"stacking": {
|
||||
"group": "A",
|
||||
"mode": "none"
|
||||
},
|
||||
"thresholdsStyle": {
|
||||
"mode": "off"
|
||||
}
|
||||
},
|
||||
"decimals": 2,
|
||||
"links": [],
|
||||
"mappings": [],
|
||||
"min": 0,
|
||||
"thresholds": {
|
||||
"mode": "absolute",
|
||||
"steps": [
|
||||
{
|
||||
"color": "green",
|
||||
"value": null
|
||||
}
|
||||
]
|
||||
},
|
||||
"unit": "short"
|
||||
},
|
||||
"overrides": []
|
||||
},
|
||||
"gridPos": {
|
||||
"h": 6,
|
||||
"w": 12,
|
||||
"x": 0,
|
||||
"y": 3
|
||||
},
|
||||
"id": 31,
|
||||
"links": [],
|
||||
"options": {
|
||||
"legend": {
|
||||
"calcs": [],
|
||||
"displayMode": "list",
|
||||
"placement": "bottom",
|
||||
"showLegend": true
|
||||
},
|
||||
"tooltip": {
|
||||
"mode": "multi",
|
||||
"sort": "desc"
|
||||
}
|
||||
},
|
||||
"pluginVersion": "8.1.4",
|
||||
"targets": [
|
||||
{
|
||||
"alias": "$col",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
{
|
||||
"params": [
|
||||
"$interval"
|
||||
],
|
||||
"type": "time"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"servername"
|
||||
],
|
||||
"type": "tag"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"none"
|
||||
],
|
||||
"type": "fill"
|
||||
}
|
||||
],
|
||||
"hide": false,
|
||||
"measurement": "server_processor",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"refId": "A",
|
||||
"resultFormat": "time_series",
|
||||
"select": [
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"utilizedProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"utlized"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"totalProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"total"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"availableProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"available"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"configurableProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"configurable"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
]
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"key": "servername",
|
||||
"operator": "=~",
|
||||
"value": "/^$ServerName$/"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"title": "System Processor Utilization",
|
||||
"type": "timeseries"
|
||||
},
|
||||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
"defaults": {
|
||||
"color": {
|
||||
"mode": "palette-classic"
|
||||
},
|
||||
"custom": {
|
||||
"axisCenteredZero": false,
|
||||
"axisColorMode": "text",
|
||||
"axisLabel": "Memory",
|
||||
"axisPlacement": "auto",
|
||||
"barAlignment": 0,
|
||||
"drawStyle": "line",
|
||||
"fillOpacity": 10,
|
||||
"gradientMode": "opacity",
|
||||
"hideFrom": {
|
||||
"legend": false,
|
||||
"tooltip": false,
|
||||
"viz": false
|
||||
},
|
||||
"lineInterpolation": "linear",
|
||||
"lineWidth": 1,
|
||||
"pointSize": 5,
|
||||
"scaleDistribution": {
|
||||
"type": "linear"
|
||||
},
|
||||
"showPoints": "never",
|
||||
"spanNulls": false,
|
||||
"stacking": {
|
||||
"group": "A",
|
||||
"mode": "none"
|
||||
},
|
||||
"thresholdsStyle": {
|
||||
"mode": "off"
|
||||
}
|
||||
},
|
||||
"links": [],
|
||||
"mappings": [],
|
||||
"thresholds": {
|
||||
"mode": "absolute",
|
||||
"steps": [
|
||||
{
|
||||
"color": "green",
|
||||
"value": null
|
||||
},
|
||||
{
|
||||
"color": "red",
|
||||
"value": 80
|
||||
}
|
||||
]
|
||||
},
|
||||
"unit": "decmbytes"
|
||||
},
|
||||
"overrides": []
|
||||
},
|
||||
"gridPos": {
|
||||
"h": 6,
|
||||
"w": 12,
|
||||
"x": 12,
|
||||
"y": 3
|
||||
},
|
||||
"id": 2,
|
||||
"links": [],
|
||||
"options": {
|
||||
"legend": {
|
||||
"calcs": [],
|
||||
"displayMode": "list",
|
||||
"placement": "bottom",
|
||||
"showLegend": true
|
||||
},
|
||||
"tooltip": {
|
||||
"mode": "multi",
|
||||
"sort": "none"
|
||||
}
|
||||
},
|
||||
"pluginVersion": "8.1.4",
|
||||
"targets": [
|
||||
{
|
||||
"alias": "$col",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
{
|
||||
"params": [
|
||||
"$interval"
|
||||
],
|
||||
"type": "time"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"servername"
|
||||
],
|
||||
"type": "tag"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"none"
|
||||
],
|
||||
"type": "fill"
|
||||
}
|
||||
],
|
||||
"hide": false,
|
||||
"measurement": "server_memory",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"refId": "A",
|
||||
"resultFormat": "time_series",
|
||||
"select": [
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"assignedMemToLpars"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"assigned"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"availableMem"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"available"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
]
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"key": "servername",
|
||||
"operator": "=~",
|
||||
"value": "/^$ServerName$/"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"title": "System Memory Utilization",
|
||||
"type": "timeseries"
|
||||
},
|
||||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
|
@ -181,7 +545,7 @@
|
|||
"h": 9,
|
||||
"w": 15,
|
||||
"x": 0,
|
||||
"y": 3
|
||||
"y": 9
|
||||
},
|
||||
"id": 19,
|
||||
"links": [],
|
||||
|
@ -304,7 +668,7 @@
|
|||
"h": 9,
|
||||
"w": 5,
|
||||
"x": 15,
|
||||
"y": 3
|
||||
"y": 9
|
||||
},
|
||||
"id": 29,
|
||||
"options": {
|
||||
|
@ -379,7 +743,7 @@
|
|||
]
|
||||
}
|
||||
],
|
||||
"title": "Shared Processor Pools - Utilization / Assigned",
|
||||
"title": "Shared Processor Pools - Utilization",
|
||||
"type": "stat"
|
||||
},
|
||||
{
|
||||
|
@ -418,7 +782,7 @@
|
|||
"h": 9,
|
||||
"w": 4,
|
||||
"x": 20,
|
||||
"y": 3
|
||||
"y": 9
|
||||
},
|
||||
"id": 30,
|
||||
"options": {
|
||||
|
@ -491,7 +855,7 @@
|
|||
]
|
||||
}
|
||||
],
|
||||
"title": "Processors - Utilization / Total",
|
||||
"title": "System Processors - Utilization",
|
||||
"type": "gauge"
|
||||
},
|
||||
{
|
||||
|
@ -554,9 +918,9 @@
|
|||
},
|
||||
"gridPos": {
|
||||
"h": 9,
|
||||
"w": 8,
|
||||
"w": 12,
|
||||
"x": 0,
|
||||
"y": 12
|
||||
"y": 18
|
||||
},
|
||||
"id": 27,
|
||||
"links": [],
|
||||
|
@ -753,212 +1117,11 @@
|
|||
},
|
||||
"gridPos": {
|
||||
"h": 9,
|
||||
"w": 8,
|
||||
"x": 8,
|
||||
"y": 12
|
||||
"w": 12,
|
||||
"x": 12,
|
||||
"y": 18
|
||||
},
|
||||
"id": 31,
|
||||
"links": [],
|
||||
"options": {
|
||||
"legend": {
|
||||
"calcs": [],
|
||||
"displayMode": "list",
|
||||
"placement": "bottom",
|
||||
"showLegend": true
|
||||
},
|
||||
"tooltip": {
|
||||
"mode": "multi",
|
||||
"sort": "desc"
|
||||
}
|
||||
},
|
||||
"pluginVersion": "8.1.4",
|
||||
"targets": [
|
||||
{
|
||||
"alias": "$col",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
{
|
||||
"params": [
|
||||
"$interval"
|
||||
],
|
||||
"type": "time"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"servername"
|
||||
],
|
||||
"type": "tag"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"none"
|
||||
],
|
||||
"type": "fill"
|
||||
}
|
||||
],
|
||||
"hide": false,
|
||||
"measurement": "server_processor",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"refId": "A",
|
||||
"resultFormat": "time_series",
|
||||
"select": [
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"utilizedProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"utlized"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"totalProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"total"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"availableProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"available"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"configurableProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"configured"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
]
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"key": "servername",
|
||||
"operator": "=~",
|
||||
"value": "/^$ServerName$/"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"title": "Processor - Core Utilization",
|
||||
"type": "timeseries"
|
||||
},
|
||||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
"defaults": {
|
||||
"color": {
|
||||
"mode": "palette-classic"
|
||||
},
|
||||
"custom": {
|
||||
"axisCenteredZero": false,
|
||||
"axisColorMode": "text",
|
||||
"axisLabel": "Memory",
|
||||
"axisPlacement": "auto",
|
||||
"barAlignment": 0,
|
||||
"drawStyle": "line",
|
||||
"fillOpacity": 10,
|
||||
"gradientMode": "opacity",
|
||||
"hideFrom": {
|
||||
"legend": false,
|
||||
"tooltip": false,
|
||||
"viz": false
|
||||
},
|
||||
"lineInterpolation": "linear",
|
||||
"lineWidth": 1,
|
||||
"pointSize": 5,
|
||||
"scaleDistribution": {
|
||||
"type": "linear"
|
||||
},
|
||||
"showPoints": "never",
|
||||
"spanNulls": false,
|
||||
"stacking": {
|
||||
"group": "A",
|
||||
"mode": "none"
|
||||
},
|
||||
"thresholdsStyle": {
|
||||
"mode": "off"
|
||||
}
|
||||
},
|
||||
"links": [],
|
||||
"mappings": [],
|
||||
"thresholds": {
|
||||
"mode": "absolute",
|
||||
"steps": [
|
||||
{
|
||||
"color": "green",
|
||||
"value": null
|
||||
},
|
||||
{
|
||||
"color": "red",
|
||||
"value": 80
|
||||
}
|
||||
]
|
||||
},
|
||||
"unit": "decmbytes"
|
||||
},
|
||||
"overrides": []
|
||||
},
|
||||
"gridPos": {
|
||||
"h": 9,
|
||||
"w": 8,
|
||||
"x": 16,
|
||||
"y": 12
|
||||
},
|
||||
"id": 2,
|
||||
"id": 35,
|
||||
"links": [],
|
||||
"options": {
|
||||
"legend": {
|
||||
|
@ -975,7 +1138,7 @@
|
|||
"pluginVersion": "8.1.4",
|
||||
"targets": [
|
||||
{
|
||||
"alias": "$col",
|
||||
"alias": "$tag_poolname",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_HMCI}"
|
||||
|
@ -990,7 +1153,7 @@
|
|||
},
|
||||
{
|
||||
"params": [
|
||||
"servername"
|
||||
"poolname"
|
||||
],
|
||||
"type": "tag"
|
||||
},
|
||||
|
@ -1002,7 +1165,7 @@
|
|||
}
|
||||
],
|
||||
"hide": false,
|
||||
"measurement": "server_memory",
|
||||
"measurement": "server_sharedProcessorPool",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"refId": "A",
|
||||
|
@ -1011,7 +1174,7 @@
|
|||
[
|
||||
{
|
||||
"params": [
|
||||
"assignedMemToLpars"
|
||||
"availableProcUnits"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
|
@ -1021,25 +1184,7 @@
|
|||
},
|
||||
{
|
||||
"params": [
|
||||
"assigned"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
],
|
||||
[
|
||||
{
|
||||
"params": [
|
||||
"availableMem"
|
||||
],
|
||||
"type": "field"
|
||||
},
|
||||
{
|
||||
"params": [],
|
||||
"type": "mean"
|
||||
},
|
||||
{
|
||||
"params": [
|
||||
"available"
|
||||
"utlized"
|
||||
],
|
||||
"type": "alias"
|
||||
}
|
||||
|
@ -1054,7 +1199,7 @@
|
|||
]
|
||||
}
|
||||
],
|
||||
"title": "Memory Utilization",
|
||||
"title": "Shared Processor Pools - Core Utilization",
|
||||
"type": "timeseries"
|
||||
},
|
||||
{
|
||||
|
@ -1150,7 +1295,7 @@
|
|||
"h": 9,
|
||||
"w": 12,
|
||||
"x": 0,
|
||||
"y": 21
|
||||
"y": 27
|
||||
},
|
||||
"id": 11,
|
||||
"links": [],
|
||||
|
@ -1297,7 +1442,7 @@
|
|||
"h": 9,
|
||||
"w": 12,
|
||||
"x": 12,
|
||||
"y": 21
|
||||
"y": 27
|
||||
},
|
||||
"id": 16,
|
||||
"links": [],
|
||||
|
@ -1414,7 +1559,7 @@
|
|||
"h": 10,
|
||||
"w": 12,
|
||||
"x": 0,
|
||||
"y": 30
|
||||
"y": 36
|
||||
},
|
||||
"id": 26,
|
||||
"options": {
|
||||
|
@ -1614,7 +1759,7 @@
|
|||
"h": 10,
|
||||
"w": 6,
|
||||
"x": 12,
|
||||
"y": 30
|
||||
"y": 36
|
||||
},
|
||||
"id": 34,
|
||||
"options": {
|
||||
|
@ -1749,7 +1894,7 @@
|
|||
"h": 10,
|
||||
"w": 6,
|
||||
"x": 18,
|
||||
"y": 30
|
||||
"y": 36
|
||||
},
|
||||
"id": 22,
|
||||
"options": {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"__inputs": [
|
||||
{
|
||||
"name": "DS_INFLUXDB",
|
||||
"name": "DS_HMCI",
|
||||
"label": "Database",
|
||||
"description": "",
|
||||
"type": "datasource",
|
||||
|
@ -90,7 +90,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"gridPos": {
|
||||
"h": 3,
|
||||
|
@ -108,7 +108,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"refId": "A"
|
||||
}
|
||||
|
@ -147,7 +147,7 @@
|
|||
"alias": "$tag_servername",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
|
@ -273,7 +273,7 @@
|
|||
"alias": "$tag_servername",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
|
@ -381,7 +381,7 @@
|
|||
"alias": "$tag_servername",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
|
@ -482,7 +482,7 @@
|
|||
"alias": "$tag_servername",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"groupBy": [
|
||||
{
|
||||
|
@ -597,7 +597,7 @@
|
|||
"alias": "$tag_servername",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
|
|
|
@ -445,12 +445,7 @@
|
|||
"show": false
|
||||
},
|
||||
"showHeader": true,
|
||||
"sortBy": [
|
||||
{
|
||||
"desc": true,
|
||||
"displayName": "Utilization"
|
||||
}
|
||||
]
|
||||
"sortBy": []
|
||||
},
|
||||
"pluginVersion": "9.1.6",
|
||||
"targets": [
|
||||
|
@ -472,7 +467,7 @@
|
|||
"measurement": "lpar_details",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"query": "SELECT last(\"weight\") AS \"Weight\", last(\"entitledProcUnits\") AS \"Entitled\", last(\"currentVirtualProcessors\") AS \"VP\", (last(\"utilizedProcUnits\") / last(\"maxProcUnits\")) * 100 AS \"Utilization\", last(\"mode\") AS \"Mode\" FROM \"vios_processor\" WHERE (\"servername\" =~ /^$ServerName$/) AND (\"viosname\" =~ /^$ViosName$/) AND $timeFilter GROUP BY \"viosname\" fill(previous)",
|
||||
"query": "SELECT last(\"weight\") AS \"Weight\", last(\"entitledProcUnits\") AS \"Entitled\", last(\"currentVirtualProcessors\") AS \"VP\", (mean(\"utilizedProcUnits\") / mean(\"entitledProcUnits\")) * 100 AS \"Utilization\", last(\"mode\") AS \"Mode\" FROM \"vios_processor\" WHERE (\"servername\" =~ /^$ServerName$/) AND (\"viosname\" =~ /^$ViosName$/) AND $timeFilter GROUP BY \"viosname\" fill(previous)",
|
||||
"queryType": "randomWalk",
|
||||
"rawQuery": true,
|
||||
"refId": "A",
|
||||
|
@ -1395,8 +1390,7 @@
|
|||
"mode": "absolute",
|
||||
"steps": [
|
||||
{
|
||||
"color": "green",
|
||||
"value": null
|
||||
"color": "green"
|
||||
}
|
||||
]
|
||||
},
|
||||
|
@ -1569,8 +1563,7 @@
|
|||
"mode": "absolute",
|
||||
"steps": [
|
||||
{
|
||||
"color": "green",
|
||||
"value": null
|
||||
"color": "green"
|
||||
},
|
||||
{
|
||||
"color": "red",
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"__inputs": [
|
||||
{
|
||||
"name": "DS_INFLUXDB",
|
||||
"name": "DS_HMCI",
|
||||
"label": "Database",
|
||||
"description": "",
|
||||
"type": "datasource",
|
||||
|
@ -21,7 +21,7 @@
|
|||
"type": "grafana",
|
||||
"id": "grafana",
|
||||
"name": "Grafana",
|
||||
"version": "9.1.3"
|
||||
"version": "9.1.6"
|
||||
},
|
||||
{
|
||||
"type": "datasource",
|
||||
|
@ -77,7 +77,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"gridPos": {
|
||||
"h": 3,
|
||||
|
@ -90,12 +90,12 @@
|
|||
"content": "## Metrics collected from IBM Power HMC\n \nFor more information visit: [git.data.coop/nellemann/hmci](https://git.data.coop/nellemann/hmci)\n ",
|
||||
"mode": "markdown"
|
||||
},
|
||||
"pluginVersion": "9.1.3",
|
||||
"pluginVersion": "9.1.6",
|
||||
"targets": [
|
||||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"refId": "A"
|
||||
}
|
||||
|
@ -106,7 +106,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
|
@ -155,13 +155,13 @@
|
|||
"showThresholdLabels": false,
|
||||
"showThresholdMarkers": false
|
||||
},
|
||||
"pluginVersion": "9.1.3",
|
||||
"pluginVersion": "9.1.6",
|
||||
"targets": [
|
||||
{
|
||||
"alias": "$tag_servername - $tag_viosname",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
|
@ -194,7 +194,7 @@
|
|||
"measurement": "vios_processor",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"query": "SELECT last(\"utilizedProcUnits\") / last(\"maxProcUnits\") AS \"utilization\" FROM \"vios_processor\" WHERE (\"servername\" =~ /^$ServerName$/ AND \"viosname\" =~ /^$ViosName$/) AND $timeFilter GROUP BY time($interval), \"viosname\", \"servername\" fill(none)",
|
||||
"query": "SELECT mean(\"utilizedProcUnits\") / mean(\"entitledProcUnits\") AS \"utilization\" FROM \"vios_processor\" WHERE (\"servername\" =~ /^$ServerName$/ AND \"viosname\" =~ /^$ViosName$/) AND $timeFilter GROUP BY time($interval), \"viosname\", \"servername\" fill(none)",
|
||||
"rawQuery": true,
|
||||
"refId": "A",
|
||||
"resultFormat": "time_series",
|
||||
|
@ -257,7 +257,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
|
@ -344,7 +344,7 @@
|
|||
"alias": "$tag_servername - $tag_viosname",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
|
@ -377,7 +377,7 @@
|
|||
"measurement": "vios_processor",
|
||||
"orderByTime": "ASC",
|
||||
"policy": "default",
|
||||
"query": "SELECT mean(\"utilizedProcUnits\") / mean(\"maxProcUnits\") AS \"utilization\" FROM \"vios_processor\" WHERE (\"servername\" =~ /^$ServerName$/ AND \"viosname\" =~ /^$ViosName$/) AND $timeFilter GROUP BY time($interval), \"viosname\", \"servername\" fill(none)",
|
||||
"query": "SELECT mean(\"utilizedProcUnits\") / mean(\"entitledProcUnits\") AS \"utilization\" FROM \"vios_processor\" WHERE (\"servername\" =~ /^$ServerName$/ AND \"viosname\" =~ /^$ViosName$/) AND $timeFilter GROUP BY time($interval), \"viosname\", \"servername\" fill(none)",
|
||||
"rawQuery": true,
|
||||
"refId": "A",
|
||||
"resultFormat": "time_series",
|
||||
|
@ -440,7 +440,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
|
@ -527,7 +527,7 @@
|
|||
"alias": "$tag_servername - $tag_viosname ($tag_location - $col)",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
|
@ -645,7 +645,7 @@
|
|||
{
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"description": "",
|
||||
"fieldConfig": {
|
||||
|
@ -727,7 +727,7 @@
|
|||
"alias": "$tag_servername - $tag_viosname ($tag_location - $col)",
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"dsType": "influxdb",
|
||||
"groupBy": [
|
||||
|
@ -860,7 +860,7 @@
|
|||
"current": {},
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"definition": "SHOW TAG VALUES FROM \"server_processor\" WITH KEY = \"servername\" WHERE time > now() - 24h",
|
||||
"hide": 0,
|
||||
|
@ -884,7 +884,7 @@
|
|||
"current": {},
|
||||
"datasource": {
|
||||
"type": "influxdb",
|
||||
"uid": "${DS_INFLUXDB}"
|
||||
"uid": "${DS_HMCI}"
|
||||
},
|
||||
"definition": "SHOW TAG VALUES FROM \"vios_details\" WITH KEY = \"viosname\" WHERE servername =~ /$ServerName/ AND time > now() - 24h",
|
||||
"hide": 0,
|
||||
|
@ -906,7 +906,7 @@
|
|||
]
|
||||
},
|
||||
"time": {
|
||||
"from": "now-2d",
|
||||
"from": "now-7d",
|
||||
"now": false,
|
||||
"to": "now-30s"
|
||||
},
|
||||
|
@ -937,6 +937,6 @@
|
|||
"timezone": "browser",
|
||||
"title": "HMCi - Power VIO Utilization",
|
||||
"uid": "DDNEv5vGy",
|
||||
"version": 10,
|
||||
"version": 2,
|
||||
"weekStart": ""
|
||||
}
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
projectId = hmci
|
||||
projectGroup = biz.nellemann.hmci
|
||||
projectVersion = 1.4.2
|
||||
projectVersion = 1.4.3
|
||||
|
|
|
@ -23,7 +23,6 @@ import org.influxdb.dto.Point;
|
|||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.time.Instant;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
@ -98,13 +97,6 @@ public final class InfluxClient {
|
|||
}
|
||||
|
||||
|
||||
/*
|
||||
public void write(List<Measurement> measurements, Instant timestamp, String name) {
|
||||
log.debug("write() - measurement: {} {}", name, measurements.size());
|
||||
processMeasurementMap(measurements, timestamp, name).forEach( (point) -> { influxDB.write(point); });
|
||||
}*/
|
||||
|
||||
|
||||
public void write(List<Measurement> measurements, String name) {
|
||||
log.debug("write() - measurement: {} {}", name, measurements.size());
|
||||
if(!measurements.isEmpty()) {
|
||||
|
@ -115,23 +107,6 @@ public final class InfluxClient {
|
|||
}
|
||||
|
||||
|
||||
/*
|
||||
private List<Point> processMeasurementMap(List<Measurement> measurements, Instant timestamp, String name) {
|
||||
List<Point> listOfPoints = new ArrayList<>();
|
||||
measurements.forEach( (m) -> {
|
||||
|
||||
Point.Builder builder = Point.measurement(name)
|
||||
.time(timestamp.getEpochSecond(), TimeUnit.SECONDS)
|
||||
.tag(m.tags)
|
||||
.fields(m.fields);
|
||||
|
||||
listOfPoints.add(builder.build());
|
||||
});
|
||||
|
||||
return listOfPoints;
|
||||
}*/
|
||||
|
||||
|
||||
private List<Point> processMeasurementMap(List<Measurement> measurements, String name) {
|
||||
List<Point> listOfPoints = new ArrayList<>();
|
||||
measurements.forEach( (m) -> {
|
||||
|
|
|
@ -23,7 +23,6 @@ import com.fasterxml.jackson.dataformat.xml.XmlMapper;
|
|||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.io.File;
|
||||
import java.time.Duration;
|
||||
import java.time.Instant;
|
||||
import java.time.temporal.ChronoUnit;
|
||||
|
|
|
@ -21,9 +21,9 @@ public abstract class Resource {
|
|||
private final ArrayList<String> sampleHistory = new ArrayList<>();
|
||||
|
||||
protected SystemUtil metric;
|
||||
protected final int maxNumberOfSamples = 60;
|
||||
protected final int minNumberOfSamples = 5;
|
||||
protected int noOfSamples = maxNumberOfSamples;
|
||||
protected final int MAX_NUMBER_OF_SAMPLES = 60;
|
||||
protected final int MIN_NUMBER_OF_SAMPLES = 5;
|
||||
protected int noOfSamples = MAX_NUMBER_OF_SAMPLES;
|
||||
|
||||
|
||||
|
||||
|
@ -125,8 +125,8 @@ public abstract class Resource {
|
|||
}
|
||||
|
||||
// Decrease down to minSamples
|
||||
if(noOfSamples > minNumberOfSamples) {
|
||||
noOfSamples = Math.min( (noOfSamples - 1), Math.max( (noOfSamples - processed) + 5, minNumberOfSamples));
|
||||
if(noOfSamples > MIN_NUMBER_OF_SAMPLES) {
|
||||
noOfSamples = Math.min( (noOfSamples - 1), Math.max( (noOfSamples - processed) + 5, MIN_NUMBER_OF_SAMPLES));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -131,9 +131,7 @@ public class RestClient {
|
|||
.delete()
|
||||
.build();
|
||||
|
||||
String responseBody;
|
||||
try (Response response = httpClient.newCall(request).execute()) {
|
||||
responseBody = Objects.requireNonNull(response.body()).string();
|
||||
} catch (IOException e) {
|
||||
log.warn("logoff() error: {}", e.getMessage());
|
||||
} finally {
|
||||
|
|
|
@ -2,7 +2,6 @@ package biz.nellemann.hmci.dto.json;
|
|||
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonUnwrapped;
|
||||
|
||||
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||
|
|
|
@ -5,7 +5,6 @@ import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
|||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
//@JsonIgnoreProperties({ "author", "etag" })
|
||||
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||
|
|
|
@ -6,9 +6,7 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
|||
import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlElementWrapper;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
//@JsonIgnoreProperties({ "link" })
|
||||
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||
|
|
Loading…
Reference in a new issue