Create a series of snapshots, with names that intentionally sort
differently by topology than by name. Use revert to create fanout.
Domain snapshot s1 created
error: operation failed: domain moment s1 already exists
Domain snapshot s3 created
Domain snapshot s2 created
Domain snapshot s3 reverted
Domain snapshot s6 created
Domain snapshot s5 created
Domain snapshot s6 reverted
Domain snapshot s4 created
Domain snapshot s1 reverted
Domain snapshot s7 created
Domain snapshot s8 created
checkpoints cannot be created while snapshots exist
error: Operation not supported: cannot create checkpoint while snapshot exists
Checking tree view (siblings sorted alphabetically)
s1
|
+- s3
| |
| +- s2
| +- s6
| |
| +- s4
| +- s5
|
+- s7
|
+- s8
Current was last one created, but we can change that
s8
Snapshot s1 set as current
s1
Deleting current root leads to multiple roots, demonstrate list filtering
Domain snapshot s1 deleted
error: domain 'test' has no current snapshot
list roots
s3
s7
list leaves
s2
s4
s5
s8
list no-leaves
s3
s6 s3
s7
list from
s2
s6
s2
s4
s5
s6
More fun with delete flags, current node moves up to remaining parent
Snapshot s4 set as current
Domain snapshot s6 children deleted
s6
Domain snapshot s7 deleted
s6
Domain snapshot s6 deleted
s3
Now the tree is linear, so we have an unambiguous topological order
s2
s3
s3
s2
s3runningtest6695eb01-f6a4-8304-79aa-97f2502e193f838860820971522hvmdestroyrestartdestroys2runnings3test6695eb01-f6a4-8304-79aa-97f2502e193f838860820971522hvmdestroyrestartdestroy