-
Tatjana Azundris Nuernberg authored
In mysqld, all local messages ("things found on console / in error log") now go through a central function rather than through a lot of fprint()s. This means we can properly timestamp those lines with ISO 8601 compliant timestamps (likewise for slow and general log files); it also means that we can gag those messages with the new system variable / startup option --log_error_verbosity, which depraces --log_warnings / -W. As timestamps go, the DBA can choose between system time or zulu time with the new option --log_timestamps. Client programs now print their warnings prefixed by their name (no path, no ".exe") and the severity level in brackets, so "Warning: foo" from bin/mysql.exe becomes "mysql: [Warning] foo" This is useful especially in mysql_upgrade (which in turn calls other binaries) so we can see whether a warning was thrown by mysql_upgrade or one of its children (and in the latter case, which). On the tech side, we now have a generic hook for local messages. This prints to stderr by default (and in the case of client apps likely always will), but can be overridden to log elsewhere, mangle the string, etc. (as is done by the server once the facilities are initiliazed; then this goes to error_log_print, for better timestamps, filtering by verbosity level, and for printing to NT syslog on Win). We deprecate my_printf_warning() which does something similar, with a less clear name. New test cases added, comments clarified, old test cases updated.
Tatjana Azundris Nuernberg authoredIn mysqld, all local messages ("things found on console / in error log") now go through a central function rather than through a lot of fprint()s. This means we can properly timestamp those lines with ISO 8601 compliant timestamps (likewise for slow and general log files); it also means that we can gag those messages with the new system variable / startup option --log_error_verbosity, which depraces --log_warnings / -W. As timestamps go, the DBA can choose between system time or zulu time with the new option --log_timestamps. Client programs now print their warnings prefixed by their name (no path, no ".exe") and the severity level in brackets, so "Warning: foo" from bin/mysql.exe becomes "mysql: [Warning] foo" This is useful especially in mysql_upgrade (which in turn calls other binaries) so we can see whether a warning was thrown by mysql_upgrade or one of its children (and in the latter case, which). On the tech side, we now have a generic hook for local messages. This prints to stderr by default (and in the case of client apps likely always will), but can be overridden to log elsewhere, mangle the string, etc. (as is done by the server once the facilities are initiliazed; then this goes to error_log_print, for better timestamps, filtering by verbosity level, and for printing to NT syslog on Win). We deprecate my_printf_warning() which does something similar, with a less clear name. New test cases added, comments clarified, old test cases updated.
Loading