ioserver: change on disconnect to once to avoid double-counting

This commit is contained in:
Calvin Montgomery 2017-08-14 18:23:07 -07:00
parent 82bd645781
commit 82004aab73
1 changed files with 1 additions and 1 deletions

View File

@ -293,7 +293,7 @@ function emitMetrics(sock) {
}
});
sock.on('disconnect', () => {
sock.once('disconnect', () => {
try {
promSocketCount.dec({ transport: transportName });
promSocketDisconnect.inc(1, new Date());