Skip to content
Permalink
Browse files

Make Executor and DatabaseConfig visibility public (#386)

Those classes will be used outside of cuttle
  • Loading branch information...
bubblesly committed Mar 27, 2019
1 parent 73d8cd6 commit 407d1ccd58af48f94393166d78af150082925f3b
@@ -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"
@@ -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
@@ -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
@@ -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,

0 comments on commit 407d1cc

Please sign in to comment.
You can’t perform that action at this time.