Skip to content
Snippets Groups Projects
Commit b0f063a0 authored by Vladimir Davydov's avatar Vladimir Davydov Committed by Konstantin Osipov
Browse files

vinyl: improve logging in vylog

 - Log debug messages at VERBOSE log level. Currently, the only way to
   debug a vylog failure in production is enabling DEBUG log level, but
   that basically floods the log with tons of not so important messages.
   There are not that many vylog messages so it should be OK to log them
   with say_verbose().

 - Report the filename on failure to load or save a vylog in order to
   simplify identification of the corrupted file.

 - Log some critical errors, such as error processing a vylog record or
   failure to flush the vylog for recovery.

 - Add sentinel messages for log rotation, saving, and loading, logged
   at VERBOSE level. This will help matching dumped log records to high
   level operations that emitted them.

 - Remove debug logging from the vy_recovery callback, which is invoked
   by vy_recovery_iterate() and vy_recovery_load_index(), as it is a
   responsibility of the caller to write log messages there, not of
   the vylog internal implementation. Besides, dumping all replayed
   records there is not really necessary as they are dumped while vylog
   is loaded anyway (see vy_recovery_new()), which should be enough for
   debugging.
parent e0c76280
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment