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

Fixing possible issue with basic engine #1059

Closed
wants to merge 1 commit into from
Closed

Conversation

m1ome
Copy link

@m1ome m1ome commented Mar 22, 2024

Hi, first of all, thank you for a great software.
We encountered a bug, when we have 10+ jobs have their attempts 1 with a max_attempts also equals to 1.
We double checked a lifeline plugin, but this jobs was forever stuck in available with 1 attempt and 1 max_attempt.

Due to current way how jobs retrieved in Engine there is a possibility, that some queue can be stuck forever.
There is a possible fix for this (i will try to investigate why do we have a problem with Lifeline)

@sorentwo
Copy link
Member

Moving the check inside the CTE changes the query plan so that it's no longer able to do an index only scan. That would have a significant impact on fetch performance in all cases. That's not desirable for this edge case, which is obnoxious and crops up infrequently in some systems some of the time, but I've never been able to reproduce it.

The Lifeline plugin only rescues executing jobs, it doesn't do anything to available jobs.

If this situation is ongoing, or you can reproduce it and we can try to diagnose together, please open an issue for investigation.

@sorentwo sorentwo closed this Mar 25, 2024
@sorentwo sorentwo added kind:bug Something isn't working area:oss Related to Oban OSS closed:invalid This doens't seem right labels Mar 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:oss Related to Oban OSS closed:invalid This doens't seem right kind:bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants