Improve daemon client debug reports

Before this change a daemon client debug messages were printed
only when the client could not connect and the 'kotlin.daemon.verbose'
system property was set up.

Now messages are printed if the debug logging is enabled and
the 'kotlin.daemon.verbose' is set up.
This commit is contained in:
Alexey Tsvetkov
2017-03-17 16:30:54 +03:00
parent c5324fcc50
commit 9819de1abd
4 changed files with 16 additions and 2 deletions
@@ -395,11 +395,13 @@ object KotlinCompilerClient {
daemon.inputStream
.reader()
.forEachLine {
reportingTargets.report(DaemonReportCategory.DEBUG, it, "daemon")
if (it == COMPILE_DAEMON_IS_READY_MESSAGE) {
reportingTargets.report(DaemonReportCategory.DEBUG, "Received the message signalling that the daemon is ready")
isEchoRead.release()
return@forEachLine
}
reportingTargets.report(DaemonReportCategory.DEBUG, it, "daemon")
}
}
finally {