hil icon indicating copy to clipboard operation
hil copied to clipboard

Handle DB transaction failure

Open henn opened this issue 11 years ago • 0 comments

Currently, we have a bunch of code that assumes that DB commits through SQLAlchemy succeed. They could fail due to concurrent requests that modify any shared objects.

We should catch the failures and do something sensible. One way to do this is to catch the exception before dispatching to the API call and retry the operation some number of times. If the retry count were exceeded, we could return a 503 status to the user.

Discussed with @gsilvis and @zenhack

henn avatar Oct 16 '14 19:10 henn