Skip to content

Commit 1ee7ac3

Browse files
committed
docs: improve clarity and readability of migration squashing ADR with PR review suggestions
1 parent c98b443 commit 1ee7ac3

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

docs/website/adr/009-database-migration-squashing.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,17 @@ Accepted
1414

1515
## Context
1616

17-
Many database migrations have accumulated over time for the Mithril nodes. As the migrations are done sequentially, the resulting scheme of the database is hard to understand and maintain.
17+
Over time, many database migrations have accumulated in Mithril nodes. Since these migrations are applied sequentially, the resulting database schema has become difficult to understand and maintain.
1818

1919
## Decision
2020

21-
To mitigate these concerns, we have decided to implement a migration squashing once we have stacked too many migrations for a store: all the existing migrations are consolidated and replaced by the equivalent new migration.
21+
To address this, the team decided to implement migration squashing once too many migrations have accumulated for a store. This process consolidates all existing migrations into a single, equivalent migration.
2222

2323
## Consequences
2424

25-
- This applies to the migrations of all the stores of the Mithril nodes
25+
- This applies to the migrations of all Mithril node stores
2626
- A squashed migration will be applied when a database is initialized for the first time
27-
- A squashed migration must be optional and run only if not already applied previously with the equivalent migration sequence
28-
- Some nodes may have only partially applied the equivalent sequence of migrations and thus can not apply the squashed migration right away:
29-
- They need to first run the migration with the latest distribution that does not ship the squashed migration so that their database is ready to play the squashed migration
30-
- This distribution is associated to a squashed migration to provide a smooth user experience.
27+
- A squashed migration must be optional and should only run if it has not been previously applied with the equivalent migration sequence
28+
- Some nodes may have only partially applied the equivalent sequence of migrations and cannot apply the squashed migration immediately:
29+
- They must first run the migration using the latest distribution that does not include the squashed migration, ensuring their database is prepared to apply it
30+
- This distribution is associated with a squashed migration to provide a smooth user experience.

0 commit comments

Comments
 (0)