Open haydnv opened 5 months ago
This is mostly done in the v0.17
branch but replicating a stateful service at startup time still needs to be re-implemented and tested: https://github.com/haydnv/tinychain/blob/v0.17/host/server/src/kernel.rs#L278
This requires implementing routing for Service
here: https://github.com/haydnv/tinychain/blob/v0.17/host/server/src/cluster/public/service.rs
such that:
/service/<name>
with a key of <version number>
creates a new Version
(see https://github.com/haydnv/tinychain/blob/v0.17/host/server/src/cluster/service.rs#L63) with a schema specified by the value of the request/service/<name>/<version number>
with a key of <attr name>
should return the Chain
of the attribute value/service/<service name>/<version number>/<attr name>..
should be routed to the specified Attr
Then, iterating over and replicating each stateful attribute of each version of each service at startup time should be straightforward. The existing tests in the tests/tctest/services
directory should not require any significant changes to cover this new implementation.
This includes: