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

Add retry pattern for jobs #92

Merged
merged 6 commits into from Jul 3, 2015

Conversation

Projects
None yet
2 participants
@guewen
Member

guewen commented Jul 3, 2015

Follows #75

JosDeGraeve and others added some commits Jun 1, 2015

[IMP] Add retry pattern for jobs
This adds a retry pattern for queue jobs.
see OCA/connector-magento#26
FIX: sort the retry dictionairy by retry count
Sort the retry dict by key ( the retry count ) instead of by value
Keep the retry pattern on the @job definition rather than in jobs
It avoids to copy and to store the pattern for every job when all jobs of one
function will probably share the same pattern.
Use seconds of the higher retry count of the retry pattern
So that the last count is repeated indefinitely.
For the following pattern:
{1: 10*60,
 5: 20*60,
 10: 60*60}
The retries 1 to 4 will be postponed 10 minutes later.
The retries 5 to 9 will be postponed 20 minutes later.
The retries 10 to infinite will be postponed 1 hour later.
@guewen

This comment has been minimized.

Show comment
Hide comment
@guewen

guewen Jul 3, 2015

Member

This change has been accepted here: #75
I just removed a field which was unused.
I'll merge as soon as I get a green.

Member

guewen commented Jul 3, 2015

This change has been accepted here: #75
I just removed a field which was unused.
I'll merge as soon as I get a green.

guewen added a commit that referenced this pull request Jul 3, 2015

@guewen guewen merged commit 56acda9 into OCA:8.0 Jul 3, 2015

2 checks passed

ci/runbot runbot build 3110373-92-54dd71 (runtime 30s)
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@guewen guewen deleted the guewen:8.0_job_retry_pattern branch Jul 3, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment