Skip to content

Commit

Permalink
remove doobie debug logs (#348)
Browse files Browse the repository at this point in the history
reducing amoung of logs producing by Cuttle as some logs aren't configurable
currently
- removing doobie debug logs
- removing duplicated debug logs from execution streams
  • Loading branch information
eryshev authored Jan 23, 2019
1 parent 234e2ac commit 08c192d
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 6 deletions.
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
val devMode = settingKey[Boolean]("Some build optimization are applied in devMode.")
val writeClasspath = taskKey[File]("Write the project classpath to a file.")

val VERSION = "0.5.2"
val VERSION = "0.5.3"

lazy val catsCore = "1.5.0"
lazy val circe = "0.10.1"
Expand Down
2 changes: 0 additions & 2 deletions core/src/main/scala/com/criteo/cuttle/Database.scala
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import io.circe.parser._
import cats.data.NonEmptyList
import cats.implicits._
import cats.effect.{IO, Resource}
import doobie.util.log

import com.criteo.cuttle.ExecutionStatus._
import com.criteo.cuttle.events.{Event, JobSuccessForced}
Expand Down Expand Up @@ -66,7 +65,6 @@ object DatabaseConfig {
}

private[cuttle] object Database {
implicit val logHandler: log.LogHandler = DoobieLogsHandler(logger).handler

implicit val ExecutionStatusMeta: Meta[ExecutionStatus] =
Meta[Boolean].imap(x => if (x) ExecutionSuccessful else ExecutionFailed: ExecutionStatus) {
Expand Down
4 changes: 1 addition & 3 deletions core/src/main/scala/com/criteo/cuttle/Executor.scala
Original file line number Diff line number Diff line change
Expand Up @@ -779,10 +779,8 @@ class Executor[S <: Scheduling] private[cuttle] (val platforms: Seq[ExecutionPla
val nextExecutionId = utils.randomUUID

val streams = new ExecutionStreams {
def writeln(str: CharSequence) = {
def writeln(str: CharSequence) =
ExecutionStreams.writeln(nextExecutionId, str)
logger.debug(s"[$nextExecutionId] $str")
}
}

// wrap the execution context so that we can register the name of the thread of each
Expand Down

0 comments on commit 08c192d

Please sign in to comment.