-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wrap research_data row addition in critical section (#4412)
wrap research_data row addition in critical section, keyed on unique constraint, as we do rarely experience asynchronous collisions. this is intended to prevent exceptions such as the following, seen once during the initial population of 100K rows: ``` Unexpected exception in `cache_research_data_task` on 231 : (psycopg2.errors.UniqueViolation) duplicate key value violates unique constraint "ix_research_data_questionnaire_response_id" DETAIL: Key (questionnaire_response_id)=(97480) already exists. ``` Co-authored-by: Ivan Cvitkovic <[email protected]>
- Loading branch information
Showing
1 changed file
with
43 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters