though this should rarely happen, sometimes we'll need to change formats of the repository files; this includes config key changes, and data inside leveldb. we should never break people's objects, so that means we need to handle these upgrades with great care.
We probably should use something like a repo-version with migrations. one possible way to do this is: we have a single repo version, every time we make format change we increment the repo version, and add a tool repo_migrate_<old>2<new> that performs the update. We should then be able to apply each script in sequence.
It would be easiest to write these in go, given much of the formatting will have to do with datastore keys or protobufs. things that would make this easier:
a datastore tool (cli tool to manipulate arbitrary datastores)
a repo tool (standalone tool that understands config, datastore, blockstore, + merkledag) and can manipulate them.
The text was updated successfully, but these errors were encountered:
jbenet commentedJan 11, 2015
though this should rarely happen, sometimes we'll need to change formats of the repository files; this includes config key changes, and data inside leveldb. we should never break people's objects, so that means we need to handle these upgrades with great care.
We probably should use something like a repo-version with migrations. one possible way to do this is: we have a single repo version, every time we make format change we increment the repo version, and add a tool
repo_migrate_<old>2<new>that performs the update. We should then be able to apply each script in sequence.It would be easiest to write these in go, given much of the formatting will have to do with datastore keys or protobufs. things that would make this easier:
The text was updated successfully, but these errors were encountered: