feat(compute-pressure) monitor cpu pressure (#13645)

This commit is contained in:
Mihaela Dumitru
2023-08-03 14:20:35 +03:00
committed by GitHub
parent ef3f20830d
commit 4461196ba3
7 changed files with 74 additions and 1 deletions

View File

@@ -2059,6 +2059,19 @@ class API {
});
}
/**
* Notify the external application (if API is enabled) when the compute pressure changed.
*
* @param {Array} records - The new pressure records.
* @returns {void}
*/
notifyComputePressureChanged(records) {
this._sendEvent({
name: 'compute-pressure-changed',
records
});
}
/**
* Disposes the allocated resources.
*