Configure pdf extraction; move Logger and DataType to common

This commit is contained in:
Eike Kettner
2020-02-17 14:01:36 +01:00
parent 3d615181e0
commit e0682464b5
12 changed files with 64 additions and 27 deletions

View File

@ -52,7 +52,7 @@ object Context {
): F[Context[F, A]] =
for {
_ <- log.ftrace("Creating logger for task run")
logger <- Logger(job.id, job.info, config.logBufferSize, logSink)
logger <- QueueLogger(job.id, job.info, config.logBufferSize, logSink)
_ <- log.ftrace("Logger created, instantiating context")
ctx = create[F, A](job, arg, config, logger, store, blocker)
} yield ctx

View File

@ -5,7 +5,7 @@ import cats.effect.{Concurrent, Sync}
import docspell.common._
import fs2.concurrent.Queue
object Logger {
object QueueLogger {
def create[F[_]: Sync](jobId: Ident, jobInfo: String, q: Queue[F, LogEvent]): Logger[F] =
new Logger[F] {