Commit 1b82f1e4 authored by Vincent Pelletier's avatar Vincent Pelletier

Factorise MasterEventHandler instanciation.


git-svn-id: https://svn.erp5.org/repos/neo/branches/prototype3@1031 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent 1657753a
......@@ -74,6 +74,7 @@ class Application(object):
self.ptid = None
self.monitoring_handler = MasterMonitoringEventHandler(self)
self.request_handler = MasterRequestEventHandler(self)
self.master_event_handler = MasterEventHandler(self)
self.dispatcher = Dispatcher()
self.cluster_state = None
self.master_conn = None
......@@ -140,7 +141,7 @@ class Application(object):
raise RuntimeError('the number of replicas is inconsistent')
# passive handler
self.master_conn.setHandler(MasterEventHandler(self))
self.master_conn.setHandler(self.master_event_handler)
# XXX: Use an initialization module to ensure all nodes and the whole
# partition table are received before process neoctl requests.
self.master_conn.ask(protocol.askNodeInformation())
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment