gva/gnuviechadmin/gvacommon/celeryrouters.py
Jan Dittberner 7360b33eca Merge commit 'd31c1d0fbf02bde5d4dc2be24762d872da64935f'
* commit 'd31c1d0fbf02bde5d4dc2be24762d872da64935f':
  add new route 'web' for web server configuration
2015-01-26 15:44:04 +01:00

15 lines
431 B
Python

# -*- coding: utf-8 -*-
from __future__ import unicode_literals
class GvaRouter(object):
def route_for_task(self, task, args=None, kwargs=None):
for route in ['ldap', 'file', 'mysql', 'pgsql', 'web']:
if route in task:
return {
'exchange': route,
'exchange_type': 'direct',
'queue': route,
}
return None