Skip to content

commit is forbidden in queue jobs #889

@sbidoul

Description

@sbidoul

It is forbidden to call env.cr.commit() in delayed job functions.

It has always been bad practice, but now a commit releases the job lock and can cause it to be started again (while still running) by the dead jobs requeuer.

#880 makes such commits an error to make that explicit.

I open this issue to collect feedback on this, as there might be (semi-)legitimate uses of commit.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions