Unmasking a hidden singleton
This title could be clearer and more informative.Try out Clickbait Shieldfor free (5 uses left this month).
A load test on monday.com's AI Reports feature revealed a critical race condition caused by a hidden singleton pattern. When multiple users simultaneously generated reports, a WorkdocsAPIService registered as a singleton shared mutable state across concurrent requests, causing workdoc IDs to override each other and trigger 400
Table of contents
Setting the stageLoad testsThe smoking gunRabbit holes, dead ends, and the “aha!”Why didn’t we see this sooner?TakewaysSort: