|From:||David J Myers|
|Subject:||[libmicrohttpd] MHD Conection timeout seems to hog the CPU|
|Date:||Tue, 10 May 2011 12:55:06 +0100|
My video streaming webserver can stream multiple video streams simultaneously, and these streams can come and go, ie start and stop.
It seems that when a connection closes (client navigates away), and after the MHD_OPTION_CONNECTION_TIMEOUT has expired, my main process thread is halted for up to one second. If I change the timeout, the halt seems to follow the new value ie if I set this to 10 seconds, I get a pause in my main thread 10 seconds after a video connection closes. This is very bad for me as all remaining video streams stutter and jerk for up to one second.
Is there any known CPU-intensive processing in MHD which happens when a connection closes? I am using a thread pool but this also happens if I switch to MHD_USE_THREAD_PER_CONNECTION mode.
Any advice would be gratefully received.
|[Prev in Thread]||Current Thread||[Next in Thread]|