mirror of
https://github.com/zulip/zulip.git
synced 2025-11-04 14:03:30 +00:00
In the event that two processes are racing to be the first to load data from zulip.yaml, we now make the race scenario be duplicated effort instead of having the second racer get an attribute error on `data`. We do this by declaring victory only after setting `data`. "Declaring victory" in this case is a matter of setting `last_update`. We are still possibly vulnerable to corrupted data here, so we should investigate a mutex, or just read the data on every call (but it's strangely expensive, almost 3.5s on my instance), or converting the YAML to code before launching the server.
4.4 KiB
4.4 KiB