MySQL 8.4.2
Source Code Documentation
|
Functions in the built-in log-sink (i.e. More...
Go to the source code of this file.
Functions | |
ssize_t | parse_trad_field (const char *parse_from, const char **token_end, const char *buf_end) |
Find the end of the current field (' ') More... | |
log_service_error | log_sink_trad_parse_log_line (const char *line_start, size_t line_length) |
Parse a single line in the traditional error log. More... | |
int | log_sink_trad (void *instance, log_line *ll) |
services: log sinks: basic logging ("classic error-log") Will write timestamp, label, thread-ID, and message to stderr/file. More... | |
Functions in the built-in log-sink (i.e.
the writer for the traditional MySQL error log):
a) writing an error log event to the traditional error log file b) parsing a line from the traditional error log file
int log_sink_trad | ( | void * | instance, |
log_line * | ll | ||
) |
services: log sinks: basic logging ("classic error-log") Will write timestamp, label, thread-ID, and message to stderr/file.
If you should not be able to specify a label, one will be generated for you from the line's priority field.
instance | instance handle |
ll | the log line to write |
int | number of added fields, if any |
log_service_error log_sink_trad_parse_log_line | ( | const char * | line_start, |
size_t | line_length | ||
) |
Parse a single line in the traditional error log.
line_start | pointer to the beginning of the line ('2' of the ISO-date) |
line_length | length of the line |
LOG_SERVICE_ARGUMENT_TOO_LONG | Token too long for its field |
LOG_SERVICE_PARSE_ERROR | No more spaces in line, cannot find expected end of token, or input otherwise malformed |
LOG_SERVICE_SUCCESS | Event added to ring-buffer |
ssize_t parse_trad_field | ( | const char * | parse_from, |
const char ** | token_end, | ||
const char * | buf_end | ||
) |
Find the end of the current field (' ')
parse_from | start of the token |
token_end | where to store the address of the delimiter found |
buf_end | end of the input line |
-1 | delimiter not found, "parsing" failed |
>=0 | length of token |