blockstore
blockstore copied to clipboard
Race condition when adding files to a draft via PATCH
If two simultaneous requests each add a (differently named) file to a draft, both requests will apparently succeed and return a 204 status code, but later attempts to GET one of the files will fail.
This is presumably because of a race condition updating the summary file.
@ormsbee This issue just bit someone else on my team. What are your thoughts on the best way to fix it? I'm tempted to just put a simple mysql or redis lock in place when updating the summary file, but I think moving the data in the summary file to mysql is also an option.
Note: to the best of my knowledge, this is still a bug in blockstore as of 2022.