Remove Sentry and celery from Mayan EDMS

This commit is contained in:
Roberto Rosario
2012-01-23 20:00:39 -04:00
parent 8d3824ea51
commit d9aa63f8ca
12 changed files with 1 additions and 117 deletions

View File

@@ -1,16 +1,5 @@
from celery.decorators import task, periodic_task
from celery.task.control import inspect
from job_processor.conf.settings import BACKEND from job_processor.conf.settings import BACKEND
@task
def celery_task(func, *args, **kwargs):
return func(*args, **kwargs)
def process_job(func, *args, **kwargs): def process_job(func, *args, **kwargs):
if BACKEND == 'celery':
return celery_task.delay(func, *args, **kwargs)
elif BACKEND is None:
return func(*args, **kwargs) return func(*args, **kwargs)

View File

@@ -1,12 +0,0 @@
"""Configuration options for the job_processing app"""
from django.utils.translation import ugettext_lazy as _
from smart_settings.api import register_settings
register_settings(
namespace=u'job_processor',
module=u'job_processor.conf.settings',
settings=[
{'name': u'BACKEND', 'global_name': u'JOB_PROCESSING_BACKEND', 'default': None, 'description': _('Specified which job processing library to use, option are: None and celery.')},
]
)

View File

@@ -11,7 +11,6 @@ from django.utils.translation import ugettext_lazy as _
from django.core.urlresolvers import reverse from django.core.urlresolvers import reverse
from django.core.exceptions import PermissionDenied from django.core.exceptions import PermissionDenied
from celery.task.control import inspect
from permissions.models import Permission from permissions.models import Permission
from documents.models import Document from documents.models import Document
from documents.widgets import document_link, document_thumbnail from documents.widgets import document_link, document_thumbnail

View File

@@ -1,23 +0,0 @@
; =======================================
; celeryd supervisor example for Django
; =======================================
[program:celery]
command=/usr/share/mayan/bin/python /usr/share/mayan/mayan/manage.py celeryd --loglevel=INFO
directory=/usr/share/mayan/mayan
user=nobody
numprocs=1
stdout_logfile=/var/log/mayan-celeryd.log
stderr_logfile=/var/log/mayan-celeryd.log
autostart=true
autorestart=true
startsecs=10
; Need to wait for currently executing tasks to finish at shutdown.
; Increase this if you have very long running tasks.
stopwaitsecs = 600
; if rabbitmq is supervised, set its priority higher
; so it starts first
priority=998

View File

@@ -1,19 +0,0 @@
; ==========================================
; celerybeat supervisor example for Django
; ==========================================
[program:celerybeat]
command=/usr/share/mayan/bin/python /usr/share/mayan/mayan/manage.py celerybeat --schedule=/var/lib/celery/celerybeat-schedule --loglevel=INFO
directory=/usr/share/mayan/mayan
user=nobody
numprocs=1
stdout_logfile=/var/log/mayan-celerybeat.log
stderr_logfile=/var/log/mayan-celerybeat.log
autostart=true
autorestart=true
startsecs=10
; if rabbitmq is supervised, set its priority higher
; so it starts first
priority=999

View File

@@ -75,14 +75,6 @@ Credits
* Jens Gulden 2005-2007 - unpaper@jensgulden.de. * Jens Gulden 2005-2007 - unpaper@jensgulden.de.
* http://unpaper.berlios.de/ * http://unpaper.berlios.de/
* celery - Celery is an open source asynchronous task queue/job queue based on distributed message passing. It is focused on real-time operation, but supports scheduling as well.
* Copyright 2009-2011, Ask Solem & contributors
* http://ask.github.com/celery/getting-started/introduction.html
* django-celery - django-celery provides Celery integration for Django
* Copyright Ask Solem & contributors
* http://github.com/ask/django-celery/
* favicon * favicon
* http://www.iconfinder.com/icondetails/21581/24/draw_pyramid_icon * http://www.iconfinder.com/icondetails/21581/24/draw_pyramid_icon
* Gnome Project * Gnome Project

View File

@@ -28,12 +28,6 @@ Executables:
Optional requirements Optional requirements
===================== =====================
To enable distributed OCR support
---------------------------------
* ``celery`` - asynchronous task queue/job queue based on distributed message passing
* ``django-celery`` - celery integration for Django
To store documents in a GridFS database To store documents in a GridFS database
--------------------------------------- ---------------------------------------

View File

@@ -180,17 +180,6 @@ Storage
Default: ``document_storage`` Default: ``document_storage``
Job processor
-------------
.. data:: JOB_PROCESSING_BACKEND
Default: ``None``
Specifies which job processing library to use, option are: None and celery.
Document indexing Document indexing
----------------- -----------------

View File

@@ -4,9 +4,6 @@ django-extensions==0.7.1
django-pagination==1.0.7 django-pagination==1.0.7
django-rosetta==0.6.2 django-rosetta==0.6.2
wsgiref==0.1.2 wsgiref==0.1.2
celery==2.2.2
django-celery==2.2.2
django-sentry==1.6.0
django-taggit==0.9.3 django-taggit==0.9.3
-e git://github.com/django-mptt/django-mptt.git@0af02a95877041b2fd6d458bd95413dc1666c321#egg=django-mptt -e git://github.com/django-mptt/django-mptt.git@0af02a95877041b2fd6d458bd95413dc1666c321#egg=django-mptt
-e git://github.com/ahupp/python-magic.git@a75cf0a4a7790eb106155c947af9612f15693b6e#egg=python-magic -e git://github.com/ahupp/python-magic.git@a75cf0a4a7790eb106155c947af9612f15693b6e#egg=python-magic

View File

@@ -1,9 +1,6 @@
Django==1.3.1 Django==1.3.1
django-pagination==1.0.7 django-pagination==1.0.7
wsgiref==0.1.2 wsgiref==0.1.2
celery==2.2.2
django-celery==2.2.2
django-sentry==1.6.0
django-taggit==0.9.3 django-taggit==0.9.3
-e git://github.com/django-mptt/django-mptt.git@0af02a95877041b2fd6d458bd95413dc1666c321#egg=django-mptt -e git://github.com/django-mptt/django-mptt.git@0af02a95877041b2fd6d458bd95413dc1666c321#egg=django-mptt
-e git://github.com/ahupp/python-magic.git@a75cf0a4a7790eb106155c947af9612f15693b6e#egg=python-magic -e git://github.com/ahupp/python-magic.git@a75cf0a4a7790eb106155c947af9612f15693b6e#egg=python-magic

View File

@@ -18,7 +18,6 @@ DEVELOPMENT = False
TEMPLATE_DEBUG = False TEMPLATE_DEBUG = False
ADMINS = () ADMINS = ()
SENTRY_ADMINS = ('root@localhost',)
MANAGERS = ADMINS MANAGERS = ADMINS
DATABASES = { DATABASES = {
@@ -141,12 +140,6 @@ INSTALLED_APPS = (
'filetransfers', 'filetransfers',
'acls', 'acls',
'converter', 'converter',
'djcelery',
'indexer',
'paging',
'sentry',
'sentry.client',
'sentry.client.celery',
'storage', 'storage',
'folders', 'folders',
'document_comments', 'document_comments',
@@ -278,18 +271,7 @@ COMPRESS_ENABLED=False
#------------ django-sendfile -------------- #------------ django-sendfile --------------
# Change to xsendfile for apache if x-sendfile is enabled # Change to xsendfile for apache if x-sendfile is enabled
SENDFILE_BACKEND = 'sendfile.backends.simple' SENDFILE_BACKEND = 'sendfile.backends.simple'
#----------- django-celery --------------
import djcelery
djcelery.setup_loader()
BROKER_HOST = "localhost"
BROKER_PORT = 5672
BROKER_USER = "guest"
BROKER_PASSWORD = "guest"
BROKER_VHOST = "/"
CELERYBEAT_SCHEDULER = 'djcelery.schedulers.DatabaseScheduler'
#======== End of user configuration options ======= #======== End of user configuration options =======
#--------- Celery ------------------
CELERY_DISABLE_RATE_LIMITS = True
#--------- Web theme --------------- #--------- Web theme ---------------
WEB_THEME_ENABLE_SCROLL_JS = False WEB_THEME_ENABLE_SCROLL_JS = False
#--------- Django ------------------- #--------- Django -------------------

View File

@@ -15,7 +15,6 @@ urlpatterns = patterns('',
(r'^tags/', include('tags.urls')), (r'^tags/', include('tags.urls')),
(r'^admin/doc/', include('django.contrib.admindocs.urls')), (r'^admin/doc/', include('django.contrib.admindocs.urls')),
(r'^admin/', include(admin.site.urls)), (r'^admin/', include(admin.site.urls)),
(r'^sentry/', include('sentry.urls')),
(r'^comments/', include('document_comments.urls')), (r'^comments/', include('document_comments.urls')),
(r'^user_management/', include('user_management.urls')), (r'^user_management/', include('user_management.urls')),
(r'^settings/', include('smart_settings.urls')), (r'^settings/', include('smart_settings.urls')),