mirror of
https://github.com/percona/percona-toolkit.git
synced 2025-09-25 21:54:48 +00:00
Update MasterSlave in all tools and add "none" to --recursion-method docs. Tools pass their tests.
This commit is contained in:
@@ -1614,6 +1614,9 @@ sub get_slaves {
|
||||
dsn_table_dsn => $dsn_table_dsn,
|
||||
);
|
||||
}
|
||||
elsif ( $method =~ m/none/i ) {
|
||||
PTDEBUG && _d('Not getting to slaves');
|
||||
}
|
||||
else {
|
||||
die "Invalid --recursion-method: $method. Valid values are: "
|
||||
. "dsn=DSN, hosts, or processlist.\n";
|
||||
@@ -1628,6 +1631,11 @@ sub recurse_to_slaves {
|
||||
my $dp = $args->{dsn_parser};
|
||||
my $dsn = $args->{dsn};
|
||||
|
||||
if ( lc($args->{method} || '') eq 'none' ) {
|
||||
PTDEBUG && _d('Not recursing to slaves');
|
||||
return;
|
||||
}
|
||||
|
||||
my $dbh;
|
||||
eval {
|
||||
$dbh = $args->{dbh} || $dp->get_dbh(
|
||||
@@ -3179,9 +3187,10 @@ Preferred recursion method used to find slaves.
|
||||
Possible methods are:
|
||||
|
||||
METHOD USES
|
||||
=========== ================
|
||||
=========== ==================
|
||||
processlist SHOW PROCESSLIST
|
||||
hosts SHOW SLAVE HOSTS
|
||||
none Do not find slaves
|
||||
|
||||
The processlist method is preferred because SHOW SLAVE HOSTS is not reliable.
|
||||
However, the hosts method is required if the server uses a non-standard
|
||||
|
Reference in New Issue
Block a user