tag
log4net

Aug 4, 2026·13 min read
How To Cure log4net's Lock Convoy on a Sitecore CD
At the worst moment of a load test, 279 of our Sitecore Content Delivery server's 427 threads were parked on a single lock, waiting for permission to write a log line. This is the story of how log4net's synchronous file appender becomes a lock convoy under concurrency, how a memory dump and two WinDbg commands convicted it in ten minutes, and the sixty-line never-blocking appender — built against Sitecore's log4net fork, because Apache-targeting packages won't load — that structurally abolished it. Plus an honest accounting of the trade-offs: dropped events over blocked threads, a crash that eats the queue, and a log that lags reality.