When sending a node to bulk API store operation, which values are valid for the field parent in node serialization?
(We ignore that parent of a partition is always null.)
Option A: Symmetric with its parent's containment/annotation
For each node, we MUST also send its parent node. The parent's containments/annotations MUST mention the child node's id,
and the child MUST mention the parent's node id.
Pro:
Con:
- We can never send subtrees, as we always need to (transitively) also send all parents. For each parent, we must also send all children (to keep symmetry). So we always must send the whole partition.
Option B: Can always be null
Pro:
- We can build the model tree from containments/annotations info, so
parent field is not needed
- Less chances of inconsistent chunks
Con:
- Less chance of detecting issues
Option C: Symmetric with its parent IF parent is also part of the request, null otherwise
Pro:
- Better chance of detecting issues
Con:
- Relatively complex criteria
Option D: Symmetric with its parent, interpret null as "delete node"
Pro:
- Allows deletion without new command
- In line with bulk API idea "I send you how the model should be"
Con:
- Implicit deletion, and deletion is a dangerous operation (as it might be recursive)
- Relatively complex criteria
Option E: Symmetric with its parent, also check parent, also check the repository for parent node
For each node, we CAN also send its parent node. If the parent is not part of the same request, the parent MUST already exist in the repository.
The parent's containments/annotations MUST mention the child node's id, and the child MUST mention the parent's node id.
Pro:
- Perfect symmetry
- No need to send unchanged (parent) nodes
Con:
When sending a node to bulk API store operation, which values are valid for the field
parentin node serialization?(We ignore that parent of a partition is always
null.)Option A: Symmetric with its parent's containment/annotation
For each node, we MUST also send its parent node. The parent's
containments/annotationsMUST mention the child node's id,and the child MUST mention the parent's node id.
Pro:
Con:
Option B: Can always be
nullPro:
parentfield is not neededCon:
Option C: Symmetric with its parent IF parent is also part of the request,
nullotherwisePro:
Con:
Option D: Symmetric with its parent, interpret
nullas "delete node"Pro:
Con:
Option E: Symmetric with its parent, also check parent, also check the repository for parent node
For each node, we CAN also send its parent node. If the parent is not part of the same request, the parent MUST already exist in the repository.
The parent's
containments/annotationsMUST mention the child node's id, and the child MUST mention the parent's node id.Pro:
Con: