diff --git a/core/src/main/scala/com/criteo/cuttle/Executor.scala b/core/src/main/scala/com/criteo/cuttle/Executor.scala index 1aa050d17..fd6fc98f2 100755 --- a/core/src/main/scala/com/criteo/cuttle/Executor.scala +++ b/core/src/main/scala/com/criteo/cuttle/Executor.scala @@ -7,7 +7,6 @@ import java.util.concurrent.atomic.AtomicBoolean import java.util.{Timer, TimerTask} import scala.concurrent.duration._ -import scala.concurrent.stm.Txn.ExternalDecider import scala.concurrent.stm._ import scala.concurrent.{Future, Promise} import scala.reflect.{classTag, ClassTag} @@ -804,7 +803,7 @@ class Executor[S <: Scheduling] private[cuttle] (val platforms: Seq[ExecutionPla existingOrNew.map( _.fold( identity, { - case (job, execution, promise, whatToDo) => + case (_, execution, promise, whatToDo) => Future { execution.streams.debug(s"Execution: ${execution.id}") execution.streams.debug(s"Context: ${execution.context.asJson}") diff --git a/core/src/main/scala/com/criteo/cuttle/Scheduling.scala b/core/src/main/scala/com/criteo/cuttle/Scheduling.scala index e6ca19c8c..6e811b2ad 100644 --- a/core/src/main/scala/com/criteo/cuttle/Scheduling.scala +++ b/core/src/main/scala/com/criteo/cuttle/Scheduling.scala @@ -1,13 +1,11 @@ package com.criteo.cuttle -import lol.http.PartialService import io.circe.Json import doobie.imports._ import cats.free._ import java.util.Comparator import Metrics.MetricProvider -import Auth._ /** A scheduler interpret a [[Workflow]] and instanciate [[Execution Executions]] for all * defined [[Job Jobs]]. For example, a typical cuttle [[Scheduler]] is the [[timeseries.TimeSeries TimeSeries]] diff --git a/examples/src/main/scala/com/criteo/cuttle/examples/HelloCustomScheduling.scala b/examples/src/main/scala/com/criteo/cuttle/examples/HelloCustomScheduling.scala index bc5a4a75c..abba97a10 100644 --- a/examples/src/main/scala/com/criteo/cuttle/examples/HelloCustomScheduling.scala +++ b/examples/src/main/scala/com/criteo/cuttle/examples/HelloCustomScheduling.scala @@ -77,7 +77,7 @@ object HelloCustomScheduling { // We will retry the execution until it is successful. def runSuccessfully(ctx: LoopContext): Future[Completed] = { logger.info(s"Running ${id}.${ctx.iteration}") - val (execution, result) = executor.run(job, ctx) + val (_, result) = executor.run(job, ctx) result.recoverWith { case e =>