Added flushing of all logs to disk when MaxScale exits
It is possible that messages logged immediately before exiting are not flushed to disk. Flushing all logs before exiting from the main function guarantees that any relevant log messages are flushed to disk.
This commit is contained in:
@ -2007,6 +2007,8 @@ int main(int argc, char **argv)
|
||||
|
||||
return_main:
|
||||
|
||||
mxs_log_flush_sync();
|
||||
|
||||
if (daemon_mode && rc != MAXSCALE_SHUTDOWN)
|
||||
{
|
||||
/** Notify the parent process that an error has occurred */
|
||||
|
Reference in New Issue
Block a user