Asks near first, if not found, asks far.
If found in there, returns it, and inserts it into
near.
Specifically, it always obtains the entire directory closure from far and inserts it into near,
which is useful when far does not support accessing intermediate directories (but near does).
There is no negative cache.
Inserts and listings are not implemented for now.
This represents a full (and validated) graph of Directory nodes.
It can be constructed using DirectoryGraphBuilder, and is normally used to
convert from one order to the other.
If you just want to validate an order without keeping the results,
RootToLeavesValidator or LeavesToRootValidator can be used.
Stores directory closures in an object store.
Notably, this makes use of the option to disallow accessing child directories except when
fetching them recursively via the top-level directory, since all batched writes
(using put_multiple_start) are stored in a single object.
Directories are stored in a length-delimited format with a 1MiB limit. The length field is a
u32 and the directories are stored in root-to-leaves topological order, the same way they will
be returned to the client in get_recursive.
This is an implementation of DirectoryPutter that simply
inserts individual Directory messages one by one, on close, after
they successfully validated.