From 5cc2096f93b7f130b36f8bc0fc43440db9a848e4 Mon Sep 17 00:00:00 2001 From: Pali Date: Fri, 7 Jun 2019 16:30:27 +0200 Subject: Switch Perl DBI scripts from DBD::mysql to DBD::MariaDB driver Perl DBD::MariaDB driver is available CPAN and is already used in production environment. --- tests/fork_big.pl | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'tests/fork_big.pl') diff --git a/tests/fork_big.pl b/tests/fork_big.pl index 623377ab5cd..2f803b7fdd3 100755 --- a/tests/fork_big.pl +++ b/tests/fork_big.pl @@ -65,7 +65,7 @@ srand 100; # Make random numbers repeatable #### $start_time=new Benchmark; -$dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", +$dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; if (!$opt_skip_create) @@ -155,7 +155,7 @@ while (($pid=wait()) != -1) if (!$opt_skip_delete && !$errors) { my $table_def; - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -189,7 +189,7 @@ sub test_insert $from_table=0; $to_table=$numtables-1; } - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -218,7 +218,7 @@ sub test_select { my ($dbh, $i, $j, $count, $loop, $count_query, $row_counts); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -255,7 +255,7 @@ sub test_select_count { my ($dbh, $i, $j, $count, $loop); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -285,7 +285,7 @@ sub test_join { my ($dbh, $i, $j, $count, $loop, $count_query, $row_counts); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -326,7 +326,7 @@ sub test_delete $table_count=2; $count=0; - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -360,7 +360,7 @@ sub test_delete sub test_update { my ($dbh, $i, $j, $row_counts, $count_query, $count, $loop); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -403,7 +403,7 @@ sub test_update sub test_check { my ($dbh, $sth, $row, $i, $j, $type, $table); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -440,7 +440,7 @@ sub test_check sub test_repair { my ($dbh, $sth, $row, $i, $type, $table); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -474,7 +474,7 @@ sub test_flush { my ($dbh,$count,$tables); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -502,7 +502,7 @@ sub test_database { my ($database) = @_; my ($dbh, $sth, $row, $i, $type, $tables); - $dbh = DBI->connect("DBI:mysql:$database:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$database:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -535,7 +535,7 @@ sub test_database sub test_alter { my ($dbh, $sth, $row, $i, $type, $table); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; @@ -559,7 +559,7 @@ sub test_alter sub signal_abort { my ($dbh); - $dbh = DBI->connect("DBI:mysql:$opt_db:$opt_host", + $dbh = DBI->connect("DBI:MariaDB:$opt_db:$opt_host", $opt_user, $opt_password, { PrintError => 0}) || die $DBI::errstr; -- cgit v1.2.1