Merge pull request #6618 from mempool/mononaut/socket-prints

[ops] log backend server socket counts
This commit is contained in:
wiz 2026-07-04 18:16:55 +09:00 committed by GitHub
commit 0d3b45b34b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -400,6 +400,16 @@ class Server {
this.warnedHeapCritical = false;
this.maxHeapSize = 0;
this.lastHeapLogTime = now;
this.server?.getConnections((error, count) => {
if (!error) {
logger.debug(`${count} open TCP sockets`);
}
});
this.serverUnixSocket?.getConnections((error, count) => {
if (!error) {
logger.debug(`${count} open unix sockets`);
}
});
}
}