If a client disconnects before its pending EVENT write messages have been processed, drop those messages instead of trying to write them

This commit is contained in:
Doug Hoyte
2023-07-21 07:46:37 -04:00
parent 7c17b066a1
commit 80915f969d
5 changed files with 36 additions and 2 deletions

View File

@ -71,6 +71,7 @@ void RelayServer::runIngester(ThreadPool<MsgIngester>::Thread &thr) {
}
} else if (auto msg = std::get_if<MsgIngester::CloseConn>(&newMsg.msg)) {
auto connId = msg->connId;
tpWriter.dispatch(connId, MsgWriter{MsgWriter::CloseConn{connId}});
tpReqWorker.dispatch(connId, MsgReqWorker{MsgReqWorker::CloseConn{connId}});
tpNegentropy.dispatch(connId, MsgNegentropy{MsgNegentropy::CloseConn{connId}});
}