@contextmanager
def _start_worker_process(app, concurrency=1, pool=u'solo', loglevel=WORKER_LOGLEVEL, logfile=None, **kwargs):
 from celery.apps.multi import Cluster, Node
 app.set_current()
 cluster = Cluster([Node(u'testworker1@%h')])
 cluster.start()
 (yield)
 cluster.stopwait()

@ contextmanager def _start_worker_process ( app , concurrency = 1 , pool = u'solo' , loglevel = WORKER_LOGLEVEL , logfile = None , ** kwargs ) : from celery . apps . multi import Cluster , Node app . set_current ( ) cluster = Cluster ( [ Node ( u'testworker1@%h' ) ] ) cluster . start ( ) ( yield ) cluster . stopwait ( )
start worker in separate process .