server: track result leaks

This commit is contained in:
Koushik Dutta
2022-06-27 13:46:22 -07:00
parent 5f9a827b79
commit 261d3ea09f

View File

@@ -88,8 +88,10 @@ export class PluginComponent {
const packageJson = await this.getPackageJson(pluginId);
const host = this.scrypted.plugins[pluginId];
let rpcObjects = 0;
let pendingResults = 0;
if (host.peer) {
rpcObjects = host.peer.localProxied.size + Object.keys(host.peer.remoteWeakProxies).length;
pendingResults = Object.keys(host.peer.pendingResults).length;
}
return {
pid: host?.worker?.pid,