banyancomputer / banyan-cli

Banyan's client, BanyanFS+CAR encrypted filesystem packer and metadata handler.
https://banyan.computer/
MIT License
25 stars 2 forks source link

Vera/ENG-308 Data Restoration #259

Closed organizedgrime closed 12 months ago

organizedgrime commented 1 year ago

Description

Huge refactor of CLI structure:

Link to issue

https://linear.app/banyan/issue/ENG-308/data-restoration

Type of change

Test plan

Most of this code is integration based and should not be tested through cargo tests but rather through actually interacting with the tool.

linear[bot] commented 1 year ago
ENG-308 Data Restoration

Tomb cli should be able to get the current metadata from the metadata service for an individual bucket, and begin restoration using that. If it encounters a data block that is not present it should request the storage providers associated with that bucket using the API defined in [ENG-304](https://linear.app/banyan/issue/ENG-304/block-storage-retrieval-staging-service). It should try each of the storage providers returned in the order they were returned to attempt to retrieve the blocks. When multiple blocks are needed it should attempt to continue using the storage provider returned until it encounters a 404 error as most blocks that are part of a restore will most likely be stored together. If a 404 is encountered the next storage provider should be tried. If the [ENG-307](https://linear.app/banyan/issue/ENG-307/metadata-service-block-lookup) API returns a non-200 response the restore should be aborted with an error. If an individual block is not available in all of the returned storage providers, the restore should be aborted with an error.

sstelfox commented 12 months ago

Looks good šŸ‘šŸ¼