Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPavlo Strokov <pstrokov@gitlab.com>2021-01-22 15:06:20 +0300
committerPavlo Strokov <pstrokov@gitlab.com>2021-02-03 14:29:04 +0300
commit22ab6f1623ff40ec12bb010b1da35116aa107291 (patch)
tree82c3bd9cc8e070adf6caa9960414cdd6c77b8317 /.gitlab-ci.yml
parentabee54a8216e132645fc0aea5a9b0e37afa74385 (diff)
Integration test to verify backwards compatibility
With multistage deployments we have both old and a new versions of the praefect service running and sharing the same database. We must be sure the changes done to the database schema doesn't affect the old version of the praefect functionality and it operates without issues. The new job was added to the pipeline to verify compatibility of the previous release and latest changes done to schema migration. The pipeline runs only if a new migration was added/modified. Closes: https://gitlab.com/gitlab-org/gitaly/-/issues/3338
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r--.gitlab-ci.yml16
1 files changed, 14 insertions, 2 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 1640488fa..cd6889c86 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -79,11 +79,11 @@ danger-review:
- postgres:11.8
variables:
PGHOST: postgres
- PGPORT: 5432
+ PGPORT: "5432"
PGUSER: postgres
POSTGRES_HOST_AUTH_METHOD: trust
PGHOST_PGBOUNCER: 0.0.0.0
- PGPORT_PGBOUNCER: 6432
+ PGPORT_PGBOUNCER: "6432"
before_script:
- go version
- git version
@@ -256,6 +256,18 @@ praefect_sql_test:
script:
- make test-postgres
+backwards_compatibility_test:
+ <<: *test_definition
+ <<: *postgres_definition
+ rules:
+ - changes:
+ - "internal/praefect/datastore/migrations/*"
+ script:
+ - git fetch origin 'refs/tags/*:refs/tags/*'
+ - git checkout $(_support/get-previous-minor-release)
+ - git checkout --no-overlay $CI_COMMIT_SHA -- internal/praefect/datastore/migrations
+ - make test-postgres
+
lint:
stage: test
retry: 2