mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
Merge 10.3 into 10.4
This commit is contained in:
@@ -21,6 +21,17 @@ use strict;
|
||||
use warnings;
|
||||
use Carp;
|
||||
|
||||
# Define all MariaDB options that the user should be able to specify
|
||||
# many times in the config file. Note that options must be written
|
||||
# using '-' instead of '_' here!
|
||||
|
||||
my %multipart_options=
|
||||
(
|
||||
"plugin-load-add" => 1,
|
||||
"optimizer-switch" => 1,
|
||||
);
|
||||
|
||||
|
||||
sub new {
|
||||
my ($class, $option_name, $option_value)= @_;
|
||||
my $self= bless { name => $option_name,
|
||||
@@ -327,7 +338,6 @@ sub new {
|
||||
# Skip comment
|
||||
next;
|
||||
}
|
||||
|
||||
else {
|
||||
croak "Unexpected line '$line' found in '$path'";
|
||||
}
|
||||
@@ -355,6 +365,11 @@ sub insert {
|
||||
|
||||
if ( defined $option ) {
|
||||
#print "option: $option, value: $value\n";
|
||||
my $tmp_option= $option;
|
||||
$tmp_option =~ s/_/-/g;
|
||||
|
||||
# If the option is an option that one can specify many times, always add
|
||||
$if_not_exist= 1 if ($multipart_options{$tmp_option});
|
||||
|
||||
# Add the option to the group
|
||||
$group->insert($option, $value, $if_not_exist);
|
||||
|
@@ -291,7 +291,7 @@ sub post_check_client_groups {
|
||||
$first_mysqld->name());
|
||||
|
||||
# Then generate [client.<suffix>] for each [mysqld.<suffix>]
|
||||
foreach my $mysqld ( $config->like('mysqld.') ) {
|
||||
foreach my $mysqld ( $config->like('mysqld\.') ) {
|
||||
$self->post_check_client_group($config,
|
||||
'client'.$mysqld->after('mysqld'),
|
||||
$mysqld->name())
|
||||
@@ -313,7 +313,7 @@ sub post_check_embedded_group {
|
||||
my $mysqld= $config->group('mysqld') or
|
||||
croak "Can't run with embedded, config has no default mysqld section";
|
||||
|
||||
my $first_mysqld= $config->first_like('mysqld.') or
|
||||
my $first_mysqld= $config->first_like('mysqld\.') or
|
||||
croak "Can't run with embedded, config has no mysqld";
|
||||
|
||||
my %no_copy = map { $_ => 1 }
|
||||
@@ -351,7 +351,7 @@ sub resolve_at_variable {
|
||||
}
|
||||
$res .= $after;
|
||||
|
||||
$config->insert($group->name(), $option->name(), $res)
|
||||
$option->{value}= $res;
|
||||
}
|
||||
|
||||
|
||||
@@ -436,7 +436,7 @@ sub new_config {
|
||||
}
|
||||
|
||||
$self->run_section_rules($config,
|
||||
'mysqld.',
|
||||
'mysqld\.',
|
||||
@mysqld_rules);
|
||||
|
||||
# [mysqlbinlog] need additional settings
|
||||
|
Reference in New Issue
Block a user