Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,17 +52,15 @@ In order to change the duration of a lock, set the DB_MUTEX_TTL_SECONDS variable
Django DB Mutex can be used with celery's tasks in the following manner.

from celery import Task
from abc import ABCMeta, abstractmethod

class NonOverlappingTask(Task):
__metaclass__ = ABCMeta

@abstractmethod
def run_worker(self, *args, **kwargs):
"""
Run worker code here.
"""
pass
raise NotImplementedError()

def run(self, *args, **kwargs):
try:
Expand Down