Skip to content

Commit

Permalink
Migrate to sioworkers version 1.4
Browse files Browse the repository at this point in the history
- bumped required version to 1.4
- fixed celery configuration in default_settings.py

Change-Id: Ic7b03ffca5f0142fcedca968383ee4c3d0d20956
  • Loading branch information
jmolinski committed Mar 22, 2021
1 parent 055a09c commit e4d3653
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 10 deletions.
14 changes: 7 additions & 7 deletions oioioi/default_settings.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# pylint: disable=wildcard-import
import sys

from oioioi.base.utils.finders import find_executable_path
Expand Down Expand Up @@ -497,22 +496,23 @@

# Celery configuration

from sio.celery.default_config import *
CELERY_QUEUES = {}
CELERY_RESULT_BACKEND = 'amqp'
CELERY_ACKS_LATE = True
CELERY_SEND_EVENTS = True

BROKER_URL = 'sqla+sqlite:///' + os.path.join(tempfile.gettempdir(),
'celerydb.sqlite')

# pylint: disable=undefined-variable

CELERY_IMPORTS += [
CELERY_IMPORTS = [
'oioioi.evalmgr.tasks',
'oioioi.problems.unpackmgr',
]

CELERY_ROUTES.update({
CELERY_ROUTES = {
'oioioi.evalmgr.tasks.evalmgr_job': dict(queue='evalmgr'),
'oioioi.problems.unpackmgr.unpackmgr_job': dict(queue='unpackmgr'),
})
}

# Number of concurrently evaluated submissions
EVALMGR_CONCURRENCY = 1
Expand Down
1 change: 0 additions & 1 deletion oioioi/sioworkers/backends.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
# code.
from threading import Lock

import sio.celery.job
import sio.workers.runner
import six
from django.conf import settings
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# These dependencies need to be installed from external sources,
# therefore they must be listed here. Moreover, they cannot be listed in
# setup.py, as pip is not able to install them.
http://github.com/sio2project/sioworkers/zipball/master#egg=sioworkers==1.3
http://github.com/sio2project/sioworkers/zipball/master#egg=sioworkers==1.4
-e .
2 changes: 1 addition & 1 deletion requirements_py3.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
# setup.py, as pip is not able to install them.
http://github.com/Supervisor/supervisor/zipball/master#egg=supervisor==4.0.0.dev0
http://github.com/badochov/djsupervisor/zipball/master#egg=djsupervisor==0.4.0
http://github.com/sio2project/sioworkers/zipball/master#egg=sioworkers==1.3
http://github.com/sio2project/sioworkers/zipball/master#egg=sioworkers==1.4
-e .

0 comments on commit e4d3653

Please sign in to comment.