Commit ac75e391 authored by Grégory Wisniewski's avatar Grégory Wisniewski

Fix a bug from the TODO-list: Storage unknown with the selected partition table

at the end of the recovery process are set in pending state.


git-svn-id: https://svn.erp5.org/repos/neo/branches/prototype3@995 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent 780cc016
......@@ -123,9 +123,6 @@ RC Known bugs
- Fix inconsistencies between client oid pool and the last oid returned by storage nodes.
Currently, the max oid returned by a storage is the max of the oid column, which ignores oids generated by master node which are not used yet in any object.
The oid pool at client side can then contain oids greater than loid known by primary master.
Master
- Fix recovery process. When the partition table is selected, current
storage nodes that are not in the table are considered as running.
Later
- Consider auto-generating cluster name upon initial startup (it might actualy be a partition property).
......
......@@ -394,11 +394,19 @@ class Application(object):
em.poll(1)
logging.info('startup allowed')
# build a new partition table
if self.pt.getID() is None:
self.buildFromScratch()
# FIXME: storage node with existing partition but not in the selected PT
# must switch to PENDING state or be disconnected to restarts from nothing
# collect node that are connected but not in the selected partition
# table and set them in pending state
allowed_node_set = set(self.pt.getNodeList())
refused_node_set = set(self.nm.getStorageNodeList()) - allowed_node_set
for node in refused_node_set:
node.setState(protocol.PENDING_STATE)
self.broadcastNodeInformation(node)
logging.debug('cluster starts with this partition table :')
self.pt.log()
......
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