mirror of
https://github.com/postgresml/pgcat.git
synced 2026-03-23 17:36:28 +00:00
fixes to the banlist
This commit is contained in:
@@ -1,7 +1,12 @@
|
||||
#/bin/bash
|
||||
set -e
|
||||
|
||||
# Setup all the shards.
|
||||
sudo service postgresql restart
|
||||
# sudo service postgresql restart
|
||||
|
||||
echo "Giving Postgres 5 seconds to start up..."
|
||||
|
||||
# sleep 5
|
||||
|
||||
psql -f query_routing_setup.sql
|
||||
|
||||
@@ -9,4 +14,6 @@ psql -h 127.0.0.1 -p 6432 -f query_routing_test_insert.sql
|
||||
|
||||
psql -h 127.0.0.1 -p 6432 -f query_routing_test_select.sql
|
||||
|
||||
psql -e -h 127.0.0.1 -p 6432 -f query_routing_test_primary_replica.sql
|
||||
|
||||
psql -f query_routing_test_validate.sql
|
||||
13
tests/sharding/query_routing_test_primary_replica.sql
Normal file
13
tests/sharding/query_routing_test_primary_replica.sql
Normal file
@@ -0,0 +1,13 @@
|
||||
SET SERVER ROLE TO 'primary';
|
||||
SELECT 1;
|
||||
|
||||
SET SERVER ROLE TO 'replica';
|
||||
SELECT 1;
|
||||
|
||||
SET SHARDING KEY TO '1234';
|
||||
SET SERVER ROLE TO 'primary';
|
||||
SELECT 1;
|
||||
|
||||
SET SERVER ROLE TO 'replica';
|
||||
SET SHARDING KEY TO '4321';
|
||||
SELECT 1;
|
||||
Reference in New Issue
Block a user