Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| ed05c01abc | |||
| 8fd8b9a915 | |||
| 56757e1c71 | |||
| d2ee396cf7 |
14
changelog.md
14
changelog.md
@@ -1,5 +1,19 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 2026-03-02 - 3.0.2 - fix(pidusage)
|
||||||
|
prune history entries for PIDs not present in the requested set to avoid stale data and memory growth
|
||||||
|
|
||||||
|
- Deletes entries from the history map when a PID is not included in the current pids array
|
||||||
|
- Prevents accumulation of stale PID histories and potential memory growth
|
||||||
|
- Change implemented in ts/smartmetrics.pidusage.ts alongside the metrics result construction
|
||||||
|
|
||||||
|
## 2026-02-19 - 3.0.1 - fix(smartmetrics)
|
||||||
|
no code changes detected; no version bump or release required
|
||||||
|
|
||||||
|
- git diff contained no modifications
|
||||||
|
- current package.json version is 3.0.0
|
||||||
|
- no dependency or file changes to warrant a release
|
||||||
|
|
||||||
## 2026-02-19 - 3.0.0 - BREAKING CHANGE(smartmetrics)
|
## 2026-02-19 - 3.0.0 - BREAKING CHANGE(smartmetrics)
|
||||||
add system-wide metrics collection, Prometheus gauges, and normalized CPU reporting
|
add system-wide metrics collection, Prometheus gauges, and normalized CPU reporting
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@push.rocks/smartmetrics",
|
"name": "@push.rocks/smartmetrics",
|
||||||
"version": "3.0.0",
|
"version": "3.0.2",
|
||||||
"private": false,
|
"private": false,
|
||||||
"description": "A package for easy collection and reporting of system and process metrics.",
|
"description": "A package for easy collection and reporting of system and process metrics.",
|
||||||
"main": "dist_ts/index.js",
|
"main": "dist_ts/index.js",
|
||||||
|
|||||||
@@ -3,6 +3,6 @@
|
|||||||
*/
|
*/
|
||||||
export const commitinfo = {
|
export const commitinfo = {
|
||||||
name: '@push.rocks/smartmetrics',
|
name: '@push.rocks/smartmetrics',
|
||||||
version: '3.0.0',
|
version: '3.0.2',
|
||||||
description: 'A package for easy collection and reporting of system and process metrics.'
|
description: 'A package for easy collection and reporting of system and process metrics.'
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -125,5 +125,12 @@ export async function getPidUsage(
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Prune history entries for PIDs no longer in the requested set
|
||||||
|
for (const histPid of history.keys()) {
|
||||||
|
if (!pids.includes(histPid)) {
|
||||||
|
history.delete(histPid);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user