# Week9 Over the past week, I took a slight detour from my postgres work after my mentor asked me to handle a [Redb issue](https://github.com/sigp/lighthouse/issues/7911). The context was that Redb recently release [v3.0.0](https://github.com/cberner/redb/releases/tag/v3.0.0), which provides several optimizations. But before we can move Lighthouse to v3.0.0, we first need to upgrade our Redb file format to v3. The steps involved are; - Upgrade our Redb crate to v2.6.2 (the last version before v3.0.0). - Write a database migration script that upgrades Redb to the v3 file formate, if Redb is enabled. - Note that v3.0.0 doesn't support the v2 format at all and doesn't even provide an upgrade path -- so this migration is essential groundwork. I have now implemented the schema migration as v29 and opened a draft [PR](https://github.com/sigp/lighthouse/pull/7917), which upgrades Redb from v2 --> v3. After opening the PR, I got some useful feedback - The downgrade should only fail if Redb is enabled and the backed is actually Redb; otherwise, it should be a no-op. - Also, Redb v2.6.2 already creates a new database using the v3 file format by default using the v3 format by [default](https://docs.rs/redb/2.6.2/src/redb/db.rs.html#1202-1220), so once this change lands, new Redb databases will automatically be in the correct format. This feedback I'm currently implementing, and doing some network testing.