Browse Source

Add retry for sync_point_update_input_data

update_input_data in sync_point.sync() at times fails with
DBDeadlock. Let's add retry like sync_point_create()

Change-Id: Id4468801bcffa7a704d90d2e190ec8dbb9a0a00b
Task: 36299
(cherry picked from commit ba9c42b9eb)
changes/95/677395/1
Rabi Mishra 1 month ago
parent
commit
4678832046
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      heat/db/sqlalchemy/api.py

+ 2
- 0
heat/db/sqlalchemy/api.py View File

@@ -1548,6 +1548,8 @@ def sync_point_get(context, entity_id, traversal_id, is_update):
1548 1548
     )
1549 1549
 
1550 1550
 
1551
+@oslo_db_api.wrap_db_retry(max_retries=3, retry_on_deadlock=True,
1552
+                           retry_interval=0.5, inc_retry_interval=True)
1551 1553
 def sync_point_update_input_data(context, entity_id,
1552 1554
                                  traversal_id, is_update, atomic_key,
1553 1555
                                  input_data):

Loading…
Cancel
Save