From e25d21acaa8abb43de5b101f54efd34693b89f49 Mon Sep 17 00:00:00 2001 From: akartasov Date: Thu, 5 Aug 2021 12:39:26 +0700 Subject: [PATCH 1/7] test CI for a pull request --- .github/workflows/main.yml | 5 ++++- deploy/pgbench-accounts-index-bid.sql | 3 +++ revert/pgbench-accounts-index-bid.sql | 3 +++ sqitch.plan | 1 + verify/pgbench-accounts-index-bid.sql | 4 ++++ 5 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 deploy/pgbench-accounts-index-bid.sql create mode 100644 revert/pgbench-accounts-index-bid.sql create mode 100644 verify/pgbench-accounts-index-bid.sql diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index fbc7e19..dd97e42 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,4 +1,4 @@ -on: [ push ] +on: [ push, pull_request ] jobs: migration_job: @@ -39,3 +39,6 @@ jobs: # Show migration summary - name: Get the response status run: echo "${{ steps.db-migration.outputs.response }}" + -- Deploy green-zone:pgbench-accounts-index-bid to pg + + diff --git a/deploy/pgbench-accounts-index-bid.sql b/deploy/pgbench-accounts-index-bid.sql new file mode 100644 index 0000000..b390212 --- /dev/null +++ b/deploy/pgbench-accounts-index-bid.sql @@ -0,0 +1,3 @@ +-- Deploy green-zone:pgbench-accounts-index-bid to pg + +create index /**concurrently**/ bid_idx on pgbench_accounts(bid); diff --git a/revert/pgbench-accounts-index-bid.sql b/revert/pgbench-accounts-index-bid.sql new file mode 100644 index 0000000..bd0d163 --- /dev/null +++ b/revert/pgbench-accounts-index-bid.sql @@ -0,0 +1,3 @@ +-- Revert green-zone:pgbench-accounts-index-bid from pg + +drop index concurrently if exists bid_idx; diff --git a/sqitch.plan b/sqitch.plan index 9321ad2..00535a2 100644 --- a/sqitch.plan +++ b/sqitch.plan @@ -4,3 +4,4 @@ initial 2021-06-29T04:14:53Z akartasov # init a database schema @v0.0.1 2021-06-29T04:20:10Z akartasov # initial version +pgbench-accounts-index-bid 2021-08-05T05:36:15Z akartasov # add a new pgbench_accounts index diff --git a/verify/pgbench-accounts-index-bid.sql b/verify/pgbench-accounts-index-bid.sql new file mode 100644 index 0000000..3f299a9 --- /dev/null +++ b/verify/pgbench-accounts-index-bid.sql @@ -0,0 +1,4 @@ +-- Verify green-zone:pgbench-accounts-index-bid on pg + +begin; +rollback; From 60551cec5e577a062ca61d4e91ed34046b206ede Mon Sep 17 00:00:00 2001 From: akartasov Date: Thu, 5 Aug 2021 12:41:21 +0700 Subject: [PATCH 2/7] fix workflow --- .github/workflows/main.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index dd97e42..6a8c6ea 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -39,6 +39,3 @@ jobs: # Show migration summary - name: Get the response status run: echo "${{ steps.db-migration.outputs.response }}" - -- Deploy green-zone:pgbench-accounts-index-bid to pg - - From d52d8f3f765c84b9b8467635d1c992da46253f0c Mon Sep 17 00:00:00 2001 From: akartasov Date: Thu, 5 Aug 2021 16:27:24 +0700 Subject: [PATCH 3/7] create index concurrently --- deploy/pgbench-accounts-index-bid.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploy/pgbench-accounts-index-bid.sql b/deploy/pgbench-accounts-index-bid.sql index b390212..06ea4d9 100644 --- a/deploy/pgbench-accounts-index-bid.sql +++ b/deploy/pgbench-accounts-index-bid.sql @@ -1,3 +1,3 @@ -- Deploy green-zone:pgbench-accounts-index-bid to pg -create index /**concurrently**/ bid_idx on pgbench_accounts(bid); +create index concurrently bid_idx on pgbench_accounts(bid); From 0691d09da56bb979ac0fdad0e9a2c9ab367d10e2 Mon Sep 17 00:00:00 2001 From: Nikolay Samokhvalov Date: Thu, 5 Aug 2021 07:33:29 -0700 Subject: [PATCH 4/7] "bad" --- deploy/pgbench-accounts-index-bid.sql | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/deploy/pgbench-accounts-index-bid.sql b/deploy/pgbench-accounts-index-bid.sql index 06ea4d9..0cf41a6 100644 --- a/deploy/pgbench-accounts-index-bid.sql +++ b/deploy/pgbench-accounts-index-bid.sql @@ -1,3 +1,5 @@ -- Deploy green-zone:pgbench-accounts-index-bid to pg -create index concurrently bid_idx on pgbench_accounts(bid); +create index +--concurrently +bid_idx on pgbench_accounts(bid); From a54dcea28a46c726bc5692c971c017df405a9ae4 Mon Sep 17 00:00:00 2001 From: Nikolay Samokhvalov Date: Thu, 5 Aug 2021 07:51:34 -0700 Subject: [PATCH 5/7] "good" --- deploy/pgbench-accounts-index-bid.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploy/pgbench-accounts-index-bid.sql b/deploy/pgbench-accounts-index-bid.sql index 0cf41a6..e499a80 100644 --- a/deploy/pgbench-accounts-index-bid.sql +++ b/deploy/pgbench-accounts-index-bid.sql @@ -1,5 +1,5 @@ -- Deploy green-zone:pgbench-accounts-index-bid to pg create index ---concurrently +concurrently bid_idx on pgbench_accounts(bid); From 593fedfd9751b4544e4dac1e2f5781e52395b0b0 Mon Sep 17 00:00:00 2001 From: Nikolay Samokhvalov Date: Thu, 5 Aug 2021 08:32:32 -0700 Subject: [PATCH 6/7] Update deploy/pgbench-accounts-index-bid.sql --- deploy/pgbench-accounts-index-bid.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploy/pgbench-accounts-index-bid.sql b/deploy/pgbench-accounts-index-bid.sql index e499a80..0cf41a6 100644 --- a/deploy/pgbench-accounts-index-bid.sql +++ b/deploy/pgbench-accounts-index-bid.sql @@ -1,5 +1,5 @@ -- Deploy green-zone:pgbench-accounts-index-bid to pg create index -concurrently +--concurrently bid_idx on pgbench_accounts(bid); From 804ca1294d267ebc9b90e86efbb67036cbbdf405 Mon Sep 17 00:00:00 2001 From: Nikolay Samokhvalov Date: Wed, 5 Jan 2022 08:47:37 -0800 Subject: [PATCH 7/7] fixed? --- deploy/pgbench-accounts-index-bid.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deploy/pgbench-accounts-index-bid.sql b/deploy/pgbench-accounts-index-bid.sql index 0cf41a6..e499a80 100644 --- a/deploy/pgbench-accounts-index-bid.sql +++ b/deploy/pgbench-accounts-index-bid.sql @@ -1,5 +1,5 @@ -- Deploy green-zone:pgbench-accounts-index-bid to pg create index ---concurrently +concurrently bid_idx on pgbench_accounts(bid);