Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reuse
expiration_interval
as select()
timeout
This is a continuation of: #352 As discussed in that pull request, on Windows the select() method does not return when a socket is ready. While the reason is still to be found out, to get the benefit of using a usually much higher timeout merged, Windows is not handled differently: The timeout is capped to 0.05 seconds to assure that connections are not delayed more than that. 0.05 seconds are used as an empirically obtained balance between max connection delay and idle system load. Benchmarks show a mean processing time per connection of ~0.03 seconds on Linux and with 0.01 seconds timeout on Windows: #352 While this highly depends on system and hardware, 0.05 seconds max delay should hence usually not significantly increase the mean time/delay per connection, but significantly reduce idle system load by reducing socket loops to 1/5 with 0.01 seconds. Signed-off-by: MichaIng <[email protected]>
- Loading branch information