Add this to your build.sbt
libraryDependencies ++= "de.geekonaut" %% "slickmdc" % "1.0.0"
In your application, you need to pass the MdcAsyncExecutor
to your database setup:
val db = Database.forDataSource(connectionPool, MdcAsyncExecutor.apply("Database", 10)) // using 10 threads
Voila!