You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Why cant we have a function that keps on checking remaining sockets and close them. It will be called in stop().
`
function stop (callback) {
// allow request handlers to update state before we act on that state
setImmediate(() => {
stopped = true
if (grace < Infinity) {
setTimeout(destroyAll, grace).unref()
}
server.close(e => {
if (callback) {
callback(e, gracefully)
}
})
reqsPerSocket.forEach(endIfIdle)
if (!grace)
closeRemaining(reqsPerSocket);
})
Why cant we have a function that keps on checking remaining sockets and close them. It will be called in stop().
`
function stop (callback) {
}
function closeRemaining(reqsPerSocket){
if(reqsPerSocket.size>0)
{
reqsPerSocket.forEach(endIfIdle);
if(reqsPerSocket.size>0){
setTimeout(closeRemaining, 1000)
}
}
}
`
The text was updated successfully, but these errors were encountered: