##// END OF EJS Templates
pass config obj to Scheduler as dict...
MinRK -
Show More
@@ -109,8 +109,10 b' class ControllerFactory(HubFactory):'
109 109
110 110 else:
111 111 self.log.info("task::using Python %s Task scheduler"%self.scheme)
112 sargs = (self.client_info['task'][1], self.engine_info['task'], self.monitor_url, self.client_info['notification'])
113 kwargs = dict(scheme=self.scheme,logname=self.log.name, loglevel=self.log.level, config=self.config)
112 sargs = (self.client_info['task'][1], self.engine_info['task'],
113 self.monitor_url, self.client_info['notification'])
114 kwargs = dict(scheme=self.scheme,logname=self.log.name, loglevel=self.log.level,
115 config=dict(self.config))
114 116 q = Process(target=launch_scheduler, args=sargs, kwargs=kwargs)
115 117 q.daemon=True
116 118 children.append(q)
@@ -34,6 +34,7 b' from zmq.eventloop import ioloop, zmqstream'
34 34
35 35 # local imports
36 36 from IPython.external.decorator import decorator
37 from IPython.config.loader import Config
37 38 from IPython.utils.traitlets import Instance, Dict, List, Set
38 39
39 40 from IPython.parallel import error
@@ -557,9 +558,12 b' def launch_scheduler(in_addr, out_addr, mon_addr, not_addr, config=None,logname='
557 558 from zmq.eventloop import ioloop
558 559 from zmq.eventloop.zmqstream import ZMQStream
559 560
561 if config:
562 # unwrap dict back into Config
563 config = Config(config)
564
560 565 ctx = zmq.Context()
561 566 loop = ioloop.IOLoop()
562 print (in_addr, out_addr, mon_addr, not_addr)
563 567 ins = ZMQStream(ctx.socket(zmq.XREP),loop)
564 568 ins.setsockopt(zmq.IDENTITY, identity)
565 569 ins.bind(in_addr)
General Comments 0
You need to be logged in to leave comments. Login now