Skip to content

Commit

Permalink
worker: detect if wait-behind is finished
Browse files Browse the repository at this point in the history
  • Loading branch information
markokr committed Feb 2, 2022
1 parent b974e64 commit c4611f1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pgq/cascade/worker.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ def wait_for_tick(self, dst_db, tick_id):
to appear from combined-root.
"""
dst_db.commit()
while True:
while self._worker_state.wait_behind:
cst = self._consumer_state
if cst['completed_tick'] >= tick_id:
return
Expand Down

0 comments on commit c4611f1

Please sign in to comment.