Skip to content

Commit 86db0a8

Browse files
palichoroba
authored andcommitted
Extend documentation for Embedded server option mariadb_embedded_options
Do not specify explicit language subdir in --language= argument as it breaks multi language support or explicit language selection via SQL command "SET lc_messages = 'ja_JP'" (it does not signal any error). Add information about --log-error= argument and why it is suggested to always specify it.
1 parent 2b76ad0 commit 86db0a8

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

lib/DBD/MariaDB.pod

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -364,15 +364,20 @@ Example:
364364

365365
use DBI;
366366
my $datadir = '/var/lib/mysql/';
367-
my $langdir = '/usr/share/mysql/english';
367+
my $langdir = '/usr/share/mysql/';
368368
my $dsn = 'DBI:MariaDB:host=embedded;database=test;'
369-
. "mariadb_embedded_options=--datadir=$datadir,--language=$langdir";
369+
. "mariadb_embedded_options=--datadir=$datadir,'
370+
. '--language=$langdir,'
371+
. '--log-error=/dev/null";
370372
my $dbh = DBI->connect($dsn, undef, undef);
371373

372374
This would start embedded server with language directory C<$langdir>, database
373-
directory C<$datadir> and connects to database C<test>. Embedded server does not
374-
have to be supported by configured MariaDB or MySQL library. In that case
375-
L<C<< DBI->connect() >>|/connect> returns an error.
375+
directory C<$datadir>, drop error messages and connects to database C<test>.
376+
It is suggested to specify C<--log-error=> option which defines location for
377+
warning messages because by default Embedded server prints its warning and
378+
error messages to C<STDOUT> which is not expected by Perl or application.
379+
Embedded server does not have to be supported by configured MariaDB or MySQL
380+
library. In that case L<C<< DBI->connect() >>|/connect> returns an error.
376381

377382
=item mariadb_embedded_groups
378383

0 commit comments

Comments
 (0)