WL#6613: Refactor logging code - split logging and binlogging code

Affects: Server-5.7   —   Status: Complete

This worklog aims to refactor logging code (log.h/log.cc)

Overall aims of the refactoring:
- Split binlogging code from general/slow/error logging code
  so that replication and runtime teams can work independently.
- Improve code documentation.
- Make logging code easier to test.