Merge pull request #664 from simons-public/fix-gui-status

Change log level on several status messages (Fixes #652, Fixes #516)
This commit is contained in:
Dom Rodriguez 2020-05-12 21:40:38 +01:00 committed by GitHub
commit dc2869f48b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 7 additions and 8 deletions

View File

@ -345,7 +345,9 @@ void MainWindow::logError()
void MainWindow::appendLogInfo(const QString& text) void MainWindow::appendLogInfo(const QString& text)
{ {
m_pLogWindow->appendInfo(text); if (appConfig().logLevel() >= 3) {
m_pLogWindow->appendInfo(text);
}
} }
void MainWindow::appendLogDebug(const QString& text) { void MainWindow::appendLogDebug(const QString& text) {
@ -536,10 +538,7 @@ void MainWindow::startBarrier()
qDebug() << args; qDebug() << args;
// show command if debug log level... appendLogDebug(QString("command: %1 %2").arg(app, args.join(" ")));
if (appConfig().logLevel() >= 4) {
appendLogInfo(QString("command: %1 %2").arg(app, args.join(" ")));
}
appendLogInfo("config file: " + configFilename()); appendLogInfo("config file: " + configFilename());
appendLogInfo("log level: " + appConfig().logLevelText()); appendLogInfo("log level: " + appConfig().logLevelText());

View File

@ -282,7 +282,7 @@ ClientApp::scheduleClientRestart(double retryTime)
void void
ClientApp::handleClientConnected(const Event&, void*) ClientApp::handleClientConnected(const Event&, void*)
{ {
LOG((CLOG_NOTE "connected to server")); LOG((CLOG_PRINT "connected to server"));
resetRestartTimeout(); resetRestartTimeout();
updateStatus(); updateStatus();
} }

View File

@ -555,7 +555,7 @@ ServerApp::startServer()
m_server->setListener(listener); m_server->setListener(listener);
m_listener = listener; m_listener = listener;
updateStatus(); updateStatus();
LOG((CLOG_NOTE "started server (%s), waiting for clients", family)); LOG((CLOG_PRINT "started server (%s), waiting for clients", family));
m_serverState = kStarted; m_serverState = kStarted;
return true; return true;
} }

View File

@ -353,7 +353,7 @@ DaemonApp::handleIpcMessage(const Event& e, void*)
LOG((CLOG_DEBUG "ipc hello, type=%s", type.c_str())); LOG((CLOG_DEBUG "ipc hello, type=%s", type.c_str()));
const char * serverstatus = m_watchdog->isProcessActive() ? "active" : "not active"; const char * serverstatus = m_watchdog->isProcessActive() ? "active" : "not active";
LOG((CLOG_INFO "server status: %s", serverstatus)); LOG((CLOG_PRINT "server status: %s", serverstatus));
m_ipcLogOutputter->notifyBuffer(); m_ipcLogOutputter->notifyBuffer();
break; break;