clockworklabs / clockworklabs/SpacetimeDB
Bootstrap the system tables from the commitlog
- Dominant language
- Rust
- Stars
- 25.2k
- Forks
- 1.1k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 46
Description
The purpose of this ticket and corresponding PR is the following:
Currently some rows are inserted into system tables by the bootstrapping code. If we ever wanted to change the system tables for existing databases, then we would have to maintain two versions of the bootstrapping code. One for the old database which were initially bootstrapped with the old code and one for the new database which was bootstrapped with the new code. This is complex.
Instead we want to make it so that the only tables which have rows inserted into them on startup is st_table and st_column and that all rows in all other tables are inserted into the commitlog. Thus making it so that migrating a system table is the same as migrating any table. We would old need the old system table code if we wanted to look at the historical state of a system table in an old database.
Food for thought, Postgres creates a template1 database and then clones it to create all other new databases.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.