Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

indexer-common: Avoid recreating recently failed actions #506

Merged
merged 5 commits into from
Oct 14, 2022

Conversation

tilacog
Copy link
Contributor

@tilacog tilacog commented Oct 11, 2022

Adds a new validation step to executeQueueOperation, which prevents the current action from entering the queue if it is found to be a retry from a previously failed attempt.

To do so, we query the database for actions with a failed status from the past 24h and check if it contains the current action.

@tilacog tilacog changed the title Tiago/avoid recreating recently failed actions indexer-common: Avoid recreating recently failed actions Oct 11, 2022
@tilacog tilacog requested a review from fordN October 11, 2022 20:22
@tilacog tilacog requested a review from fordN October 11, 2022 23:08
@tilacog tilacog self-assigned this Oct 12, 2022
Copy link
Contributor

@fordN fordN left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@fordN fordN linked an issue Oct 13, 2022 that may be closed by this pull request
@tilacog
Copy link
Contributor Author

tilacog commented Oct 13, 2022

I changed some variable names in executeQueueOperation and added some comments to clarify that we are performing two different checks.

@tilacog tilacog requested review from hopeyen and fordN October 13, 2022 21:57
Copy link
Contributor

@hopeyen hopeyen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm! 👍

@tilacog tilacog removed the request for review from fordN October 14, 2022 18:09
@tilacog tilacog merged commit 6fc5a03 into main Oct 14, 2022
@tilacog tilacog deleted the tiago/avoid-recreating-recently-failed-actions branch October 14, 2022 18:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

AQI: Improve handling of failed actions
3 participants