logger: Refactor the logging framework
authorManuel Nickschas <sputnick@quassel-irc.org>
Wed, 20 Jun 2018 23:36:27 +0000 (01:36 +0200)
committerManuel Nickschas <sputnick@quassel-irc.org>
Thu, 12 Jul 2018 20:49:25 +0000 (22:49 +0200)
commit37110ceaa070167b4f40ed449ac9ea130503a792
tree2a3a2038897c4a558690025206e60aa6fa75a759
parentf42dc2dd4b22600ca1dc6d8bdcc94aa16dda8276
logger: Refactor the logging framework

* Rename the previous Logger class to LogMessage (since that is what
  it is), and consolidate logging functionality, including the
  various output methods, setup of log file etc., into a new
  Logger class.

* Hold the "debug log", i.e. the collected log messages, in the Logger
  class instead of in the Client. Adapt the DebugLogWidget accordingly.
  Messages will not be kept in quasselcore, as we wouldn't have a way
  to display them otherwise (and we don't want to accumulate lots of
  data over months of the core running).

* Support early log messages. Instantiate the Logger right at the
  start of main(), and keep all log messages until the Quassel class
  is initialized and we can rely on command-line options to configure
  backends accordingly. Accumulated messages will be output once the
  Logger is configured.
30 files changed:
src/client/client.cpp
src/client/client.h
src/client/clientauthhandler.cpp
src/common/CMakeLists.txt
src/common/basichandler.cpp
src/common/logger.cpp
src/common/logger.h
src/common/logmessage.cpp [new file with mode: 0644]
src/common/logmessage.h [new file with mode: 0644]
src/common/main.cpp
src/common/quassel.cpp
src/common/quassel.h
src/core/abstractsqlstorage.cpp
src/core/cipher.cpp
src/core/core.cpp
src/core/coreauthhandler.cpp
src/core/corebasichandler.cpp
src/core/coresession.cpp
src/core/coresessioneventprocessor.cpp
src/core/identserver.cpp
src/core/ldapauthenticator.cpp
src/core/postgresqlstorage.cpp
src/core/sqlauthenticator.cpp
src/core/sqlitestorage.cpp
src/core/sslserver.cpp
src/qtui/debuglogwidget.cpp
src/qtui/debuglogwidget.h
src/qtui/mainwin.cpp
src/qtui/qtui.h
src/qtui/qtuiapplication.cpp