Bug #6729
Updated by François ARMAND over 9 years ago
If we do a partial promise regeneration, some node may have their new promises in the folder
/path/to/relay.new/path/to/node
rather than the good old /path/to/relay/path/to/node
More presillely, we have the following case to manage (node3 was removed in the generation):
*1/ Relay and all nodes updated (historical defautl behaviour)*
Generation gives:
<pre>
relay/
relay_promises
share/{ node1, node2, node3 }
relay.new/
relay_promises
share/{ node1.new, node2.new }
</pre>
We want ([U] means updated):
<pre>
relay/
relay_promises [U]
share/{ node1 [U], node2 [U] }
</pre>
*2/ Relay promises not updated, some children updated:*
Generation gives:
<pre>
relay/
relay_promises
share/{ node1, node2, node3 }
relay.new/
share/{ node1.new }
</pre>
We want:
<pre>
relay/
relay_promises
share/{ node1 [U], node2 }
</pre>
*3/ Relay promises updated, some children updated:*
Generation gives:
<pre>
relay/
relay_promises
share/{ node1, node2, node3 }
relay.new/
relay_promises
share/{ node1.new }
</pre>
We want:
<pre>
relay/
relay_promises [U]
share/{ node1 [U], node2 }
</pre>
We see that all the naive scheme of moving or copying can't be used, and that some set union and intersection of nodes modified or not modified must be done.