Skip to content

Commit

Permalink
Make Executor and DatabaseConfig visibility public (#386)
Browse files Browse the repository at this point in the history
Those classes will be used outside of cuttle
  • Loading branch information
bubblesly authored Mar 27, 2019
1 parent 73d8cd6 commit 407d1cc
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 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.9.2"
val VERSION = "0.9.3"

lazy val catsCore = "1.5.0"
lazy val circe = "0.10.1"
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/scala/com/criteo/cuttle/Database.scala
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ object DatabaseConfig {
}
}

private[cuttle] object Database {
object Database {

implicit val JsonMeta: Meta[Json] = Meta[String].imap(x => parse(x).fold(e => throw e, identity _))(
x => x.noSpaces
Expand Down
6 changes: 3 additions & 3 deletions core/src/main/scala/com/criteo/cuttle/Executor.scala
Original file line number Diff line number Diff line change
Expand Up @@ -377,13 +377,13 @@ trait ExecutionPlatform {
def waiting: Set[Execution[_]]
}

private[cuttle] object ExecutionPlatform {
object ExecutionPlatform {
implicit def fromExecution(implicit e: Execution[_]): Seq[ExecutionPlatform] = e.platforms
def lookup[E: ClassTag](implicit platforms: Seq[ExecutionPlatform]): Option[E] =
platforms.find(classTag[E].runtimeClass.isInstance).map(_.asInstanceOf[E])
}

private[cuttle] object Executor {
object Executor {

// we save a mapping of ThreadName -> ExecutionStreams to be able to redirect logs comming
// form different SideEffect (Futures) to the corresponding ExecutionStreams
Expand All @@ -394,7 +394,7 @@ private[cuttle] object Executor {

/** An [[Executor]] is responsible to actually execute the [[SideEffect]] functions for the
* given [[Execution Executions]]. */
class Executor[S <: Scheduling] private[cuttle] (
class Executor[S <: Scheduling] (
val platforms: Seq[ExecutionPlatform],
xa: XA,
logger: Logger,
Expand Down

0 comments on commit 407d1cc

Please sign in to comment.