You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Support int8 migration versions via new int8-versions feature
This addresses, though does not really *fix* #83, because it doesn't make refinery support timestamped migrations *by default*, but only if you opt-in to the new feature.
However, making it an optional feature neatly sidesteps the unanswered questions in the issue, and so makes the implementation easier to complete and land.
Copy file name to clipboardExpand all lines: README.md
+6-4
Original file line number
Diff line number
Diff line change
@@ -53,15 +53,17 @@ fn main() {
53
53
For more library examples, refer to the [`examples`](https://github.com/rust-db/refinery/tree/main/examples).
54
54
### Example: CLI
55
55
56
-
NOTE:
56
+
NOTE:
57
57
58
-
- Contiguous (adjacent) migration version numbers are restricted to `u32` (unsigned, 32-bit integers).
59
-
- Non-contiguous (not adjacent) migration version numbers are restricted to `u32` (unsigned, 32-bit integers).
58
+
- By default, migration version numbers are restricted to `i32` (signed, 32-bit integers).
59
+
- If you enable the `int8-versions` feature, this restriction is lifted to being able to use `i64`s for your migration version numbers (yay timestamps!).
60
+
Bear in mind that this feature must be enabled *before* you start using refinery on a given database.
61
+
Migrating an existing database's `refinery_schema_history` table to use `int8` versions will break the checksums on all previously-applied migrations, which is... bad.
0 commit comments