Skip to content

Commit

Permalink
Preliminary fix for issue #216
Browse files Browse the repository at this point in the history
  • Loading branch information
ShahriyarR committed Oct 3, 2017
1 parent 8f7c95a commit e721166
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
17 changes: 16 additions & 1 deletion myrocks-tests/myrocks-testsuite.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,18 @@ function start_proxysql_servers() {

}

function start_proxysql_servers_pxc() {
cd $1
FILE="Percona-XtraDB-Cluster-5.7.19-rel17-29.22.1.Linux.x86_64.ssl101.tar.gz"
if [ -f $FILE ]; then
# Starting 3 PS servers with configured ProxySQL
~/percona-qa/proxysql-pxc-config $1 1 "--plugin-load-add=tokudb=ha_tokudb.so --tokudb-check-jemalloc=0 --plugin-load-add=rocksdb=ha_rocksdb.so --default-storage-engine=rocksdb"
else
wget https://www.percona.com/downloads/Percona-XtraDB-Cluster-LATEST/Percona-XtraDB-Cluster-5.7.19-29.22/binary/tarball/Percona-XtraDB-Cluster-5.7.19-rel17-29.22.1.Linux.x86_64.ssl101.tar.gz
~/percona-qa/proxysql-pxc-config $1 1 "--plugin-load-add=tokudb=ha_tokudb.so --tokudb-check-jemalloc=0 --plugin-load-add=rocksdb=ha_rocksdb.so --default-storage-engine=rocksdb"
fi
}

function execute_sql() {
# General function to pass sql statement to mysql client
conn_string="$(cat $1/cl_noprompt)"
Expand Down Expand Up @@ -321,7 +333,7 @@ run_mysqldump_bats

echo "################################################################"

echo "Starting ProxySQL tests"
echo "Starting ProxySQL tests with PS"
start_proxysql_servers ${WORKDIR} ${BASEDIR}

echo "Creating test database over ProxySQL"
Expand All @@ -342,3 +354,6 @@ mysql --user=root --host=localhost --port=6033 --protocol=tcp -e "${INSRT}"

echo "Running proxysql.bats"
run_proxysql_bats

echo "Starting ProxySQL tests with PXC"
start_proxysql_servers_pxc ${WORKDIR}
2 changes: 2 additions & 0 deletions myrocks-tests/proxysql.bats
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ CONN1=$(cat ${WORKDIR}/${BASEDIR}/cl_ps1)
[[ $result = "We are the warriors of true!" ]]
}

BASEDIR=$(ls -1td Percona-XtraDB-Cluster-5.* | grep -v ".tar" | head -n1)

# @test "Running select on PS2" {
# result="$(${CONN2} -e 'select pad from proxysql_test_db.sbtest1')"
# echo $output
Expand Down

0 comments on commit e721166

Please sign in to comment.