mailman3-web needs Q_CLUSTER retry setting

Bug #2060293 reported by Marco van Zwetselaar
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
mailman-suite (Ubuntu)
New
Undecided
Unassigned

Bug Description

Installation of mailman3-web (0+20200530-2.1) on mantic produces this warning:

    Creating config file /etc/mailman3/mailman-web.py with new version
    /usr/lib/python3/dist-packages/django_q/conf.py:139: UserWarning: Retry and timeout are misconfigured. Set retry larger than timeout,
            failure to do so will cause the tasks to be retriggered before completion.
            See https://django-q.readthedocs.io/en/latest/configure.html#retry for details.

This refers to the 'retry' and 'timeout' fields of the Q_CLUSTER dictionary configured in /usr/share/mailman3-web/settings.py.

That file sets 'timeout' to 300, but has no setting for retry. The documentation linked above states that the built-in default is 60 seconds.

Though Django reports this as a warning, clearly this configuration will cause bugs such as tasks being executed multiple times (up to 5 retries could be started while previous tasks may still finish).

The fix is to add a 'retry' setting to the settings file. Assuming that the 300s timeout was deliberately chosen upstream, then setting the retry interval to 360 would be sensible (= retry one minute after timeout). A patch is attached.

Tags: mantic patch
Revision history for this message
Marco van Zwetselaar (zwets) wrote :
Revision history for this message
Marco van Zwetselaar (zwets) wrote :

Fixed patch (previous patch had retry setting 450)

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "Add retry setting to settings.py" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.