Create a flyway index file and verify correctness (#819)

* Create a flyway index file and verify correctness

Create an index file (flyway.txt) containing the names of all of the flyway
files and verify that it is ordered and in sync with the actual contents of
the flyway directory.  Also provide a target (generateFlywayIndex) to
automatically generate it.

The purpose of flyway.txt is to cause a merge conflict in the event that two
different developers add a flyway file with the same sequence number, an event
which has occurred multiple times.
This commit is contained in:
Michael Muller
2020-09-29 11:26:05 -04:00
committed by GitHub
parent ad5a74fee9
commit 6f75dfd116
5 changed files with 176 additions and 1 deletions
+5
View File
@@ -61,6 +61,11 @@ Below are the steps to submit a schema change:
You'll want to have a look at the diffs in the golden schema to verify that
all changes are intentional.
5. Run ./nom_build :db:generateFlywayIndex to regenerate the Flyway index.
This is a file listing all of the current Flyway files. Its purpose is to
produce a merge conflict when more than one person adds a Flyway file with
the same sequence number.
Relevant files (under db/src/main/resources/sql/schema/):
* nomulus.golden.sql is the schema dump (pg_dump for postgres) of the final