Browse Source

akka-http-slick-postgres: less dependencies; improved configuration; current Scala, sbt and dependency versions (#4751)

Sven Ludwig 6 years ago
parent
commit
dbf6f14900
16 changed files with 59 additions and 109 deletions
  1. 2 2
      frameworks/Scala/akka-http/akka-http-slick-postgres.dockerfile
  2. 7 22
      frameworks/Scala/akka-http/akka-http-slick-postgres/build.sbt
  3. 1 1
      frameworks/Scala/akka-http/akka-http-slick-postgres/project/build.properties
  4. 1 1
      frameworks/Scala/akka-http/akka-http-slick-postgres/project/plugins.sbt
  5. 11 34
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/resources/application.conf
  6. 15 0
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/resources/application.ini
  7. 2 3
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/ApiRoutes.scala
  8. 3 7
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/Main.scala
  9. 0 22
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/db/CustomPostgresProfile.scala
  10. 4 3
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/db/DatabaseConfiguration.scala
  11. 2 2
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/db/DatabaseRepositoryLoader.scala
  12. 5 5
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/fortune/FortuneRepositoryModule.scala
  13. 1 1
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/fortune/FortuneTable.scala
  14. 3 3
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/world/WorldRepositoryModule.scala
  15. 1 2
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/world/WorldRoutes.scala
  16. 1 1
      frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/world/WorldTable.scala

+ 2 - 2
frameworks/Scala/akka-http/akka-http-slick-postgres.dockerfile

@@ -1,4 +1,4 @@
-FROM hseeberger/scala-sbt:8u181_2.12.6_1.2.3
+FROM hseeberger/scala-sbt:8u181_2.12.8_1.2.8
 
 
 WORKDIR /akka-http-slick-postgres
 WORKDIR /akka-http-slick-postgres
 
 
@@ -21,4 +21,4 @@ COPY akka-http-slick-postgres/src src
 
 
 RUN sbt clean compile stage
 RUN sbt clean compile stage
 
 
-CMD ["target/universal/stage/bin/akka-http-slick-postgres", "-Dakka.http.benchmark.postgres.dbhost=tfb-database", "-J-d64", "-J-server", "-J-Xms1g", "-J-Xmx1g", "-J-XX:UseG1GC", "-J-XX:ParallelGCThreads=3", "-J-XX:MetaspaceSize=192M", "-J-XX:MaxMetaspaceSize=192M", "-J-XX:+UseStringDeduplication"]
+CMD ["target/universal/stage/bin/akka-http-slick-postgres", "-Dakka.http.benchmark.postgres.dbhost=tfb-database", "-J-d64", "-J-server", "-J-Xms2g", "-J-Xmx2g", "-J-XX:UseG1GC", "-J-XX:ParallelGCThreads=4", "-J-XX:MetaspaceSize=192M", "-J-XX:MaxMetaspaceSize=192M", "-J-XX:+UseStringDeduplication", "-J-Dcom.sun.management.jmxremote=false", "-J-Dcom.sun.management.jmxremote.local.only=false", "-J-Dcom.sun.management.jmxremote.authenticate=false", "-J-Dcom.sun.management.jmxremote.ssl=false", "-J-Djava.awt.headless=true", "-J-Djava.net.preferIPv4Stack=true"]

+ 7 - 22
frameworks/Scala/akka-http/akka-http-slick-postgres/build.sbt

@@ -13,20 +13,14 @@ lazy val akkaHttpSlickPostgres =
       name := "akka-http-slick-postgres",
       name := "akka-http-slick-postgres",
       mainClass in Compile := Some("net.benchmark.akka.http.Main"),
       mainClass in Compile := Some("net.benchmark.akka.http.Main"),
       libraryDependencies ++= Seq(
       libraryDependencies ++= Seq(
-        library.akkaSlf4j,
-        library.akkaStream,
         library.akkaHttp,
         library.akkaHttp,
         library.akkaHttpCirce,
         library.akkaHttpCirce,
-        library.akkaTestkit        % Test,
-        library.akkaHttpTestkit    % Test,
-        library.akkaStreamTestkit  % Test,
+        library.akkaSlf4j,
+        library.akkaStream,
         library.logbackClassic,
         library.logbackClassic,
         library.postgresql,
         library.postgresql,
-        library.scalaCheck         % Test,
-        library.scalaTest          % Test,
         library.scalateCore,
         library.scalateCore,
         library.slick,
         library.slick,
-        library.slickPgCore,
         library.slickHikariCP,
         library.slickHikariCP,
       ),
       ),
       parallelExecution in Test := true
       parallelExecution in Test := true
@@ -35,33 +29,24 @@ lazy val akkaHttpSlickPostgres =
 lazy val library =
 lazy val library =
   new {
   new {
     object Version {
     object Version {
-      val akka              = "2.5.20"
-      val akkaHttp          = "10.1.7"
+      val akka              = "2.5.22"
+      val akkaHttp          = "10.1.8"
       val akkaHttpCirce     = "1.23.0"
       val akkaHttpCirce     = "1.23.0"
       val logback           = "1.2.3"
       val logback           = "1.2.3"
       val postgresql        = "42.2.5"
       val postgresql        = "42.2.5"
-      val scalaCheck        = "1.14.0"
-      val scalaTest         = "3.0.5"
-      val scalate           = "1.8.0"
+      val scalate           = "1.9.1"
       val slick             = "3.3.0"
       val slick             = "3.3.0"
-      val slickPg           = "0.17.2"
     }
     }
 
 
-    val akkaSlf4j           = "com.typesafe.akka"            %% "akka-slf4j"                  % Version.akka
     val akkaHttp            = "com.typesafe.akka"            %% "akka-http"                   % Version.akkaHttp
     val akkaHttp            = "com.typesafe.akka"            %% "akka-http"                   % Version.akkaHttp
-    val akkaHttpTestkit     = "com.typesafe.akka"            %% "akka-http-testkit"           % Version.akkaHttp
     val akkaHttpCirce       = "de.heikoseeberger"            %% "akka-http-circe"             % Version.akkaHttpCirce
     val akkaHttpCirce       = "de.heikoseeberger"            %% "akka-http-circe"             % Version.akkaHttpCirce
+    val akkaSlf4j           = "com.typesafe.akka"            %% "akka-slf4j"                  % Version.akka
     val akkaStream          = "com.typesafe.akka"            %% "akka-stream"                 % Version.akka
     val akkaStream          = "com.typesafe.akka"            %% "akka-stream"                 % Version.akka
-    val akkaStreamTestkit   = "com.typesafe.akka"            %% "akka-stream-testkit"         % Version.akka
-    val akkaTestkit         = "com.typesafe.akka"            %% "akka-testkit"                % Version.akka
     val logbackClassic      = "ch.qos.logback"               %  "logback-classic"             % Version.logback
     val logbackClassic      = "ch.qos.logback"               %  "logback-classic"             % Version.logback
     val postgresql          = "org.postgresql"               %  "postgresql"                  % Version.postgresql
     val postgresql          = "org.postgresql"               %  "postgresql"                  % Version.postgresql
-    val scalaCheck          = "org.scalacheck"               %% "scalacheck"                  % Version.scalaCheck
-    val scalaTest           = "org.scalatest"                %% "scalatest"                   % Version.scalaTest
     val scalateCore         = "org.scalatra.scalate"         %% "scalate-core"                % Version.scalate
     val scalateCore         = "org.scalatra.scalate"         %% "scalate-core"                % Version.scalate
     val slick               = "com.typesafe.slick"           %% "slick"                       % Version.slick
     val slick               = "com.typesafe.slick"           %% "slick"                       % Version.slick
     val slickHikariCP       = "com.typesafe.slick"           %% "slick-hikaricp"              % Version.slick
     val slickHikariCP       = "com.typesafe.slick"           %% "slick-hikaricp"              % Version.slick
-    val slickPgCore         = "com.github.tminglei"          %% "slick-pg"                    % Version.slickPg
   }
   }
 
 
 lazy val settings =
 lazy val settings =
@@ -74,7 +59,7 @@ lazy val commonSettings =
   Seq(
   Seq(
     organization := "net.benchmark.akka.http",
     organization := "net.benchmark.akka.http",
     organizationName := "Akka",
     organizationName := "Akka",
-    scalaVersion := "2.12.6",
+    scalaVersion := "2.12.8",
     scalacOptions ++= Seq(
     scalacOptions ++= Seq(
       "-deprecation",
       "-deprecation",
       "-encoding",
       "-encoding",

+ 1 - 1
frameworks/Scala/akka-http/akka-http-slick-postgres/project/build.properties

@@ -1 +1 @@
-sbt.version = 1.2.3
+sbt.version = 1.2.8

+ 1 - 1
frameworks/Scala/akka-http/akka-http-slick-postgres/project/plugins.sbt

@@ -1,7 +1,7 @@
 addSbtPlugin("com.typesafe.sbt"   % "sbt-git"             % "1.0.0")
 addSbtPlugin("com.typesafe.sbt"   % "sbt-git"             % "1.0.0")
 addSbtPlugin("com.typesafe.sbt"   % "sbt-native-packager" % "1.3.16")
 addSbtPlugin("com.typesafe.sbt"   % "sbt-native-packager" % "1.3.16")
 addSbtPlugin("com.lucidchart"     % "sbt-scalafmt"        % "1.15")
 addSbtPlugin("com.lucidchart"     % "sbt-scalafmt"        % "1.15")
-addSbtPlugin("org.wartremover"    % "sbt-wartremover"     % "2.4.0")
+addSbtPlugin("org.wartremover"    % "sbt-wartremover"     % "2.4.2")
 addSbtPlugin("io.get-coursier"    % "sbt-coursier"        % "1.0.3")
 addSbtPlugin("io.get-coursier"    % "sbt-coursier"        % "1.0.3")
 
 
 libraryDependencies += "org.slf4j" % "slf4j-nop" % "1.7.25" // Needed by sbt-git
 libraryDependencies += "org.slf4j" % "slf4j-nop" % "1.7.25" // Needed by sbt-git

+ 11 - 34
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/resources/application.conf

@@ -1,46 +1,23 @@
 akka {
 akka {
-  loggers                          = [akka.event.slf4j.Slf4jLogger]
-  logging-filter                   = "akka.event.slf4j.Slf4jLoggingFilter"
-  loglevel                         = error
-  log-dead-letters                 = 5
-  log-dead-letters-during-shutdown = on
-  logger-startup-timeout           = 30s
-  daemonic = off
-  jvm-exit-on-fatal-error = on
-  jvm-shutdown-hooks = on
+  loggers = ["akka.event.slf4j.Slf4jLogger"]
+  logging-filter = "akka.event.slf4j.Slf4jLoggingFilter"
+  loglevel = "ERROR"
+  stdout-loglevel = "ERROR"
 
 
   actor {
   actor {
-    provider = "local"
-    serialize-messages = off
-    serialize-creators = off
-    allow-java-serialization = off
-
     default-dispatcher {
     default-dispatcher {
-      type = "Dispatcher"
-      executor = "fork-join-executor"
       fork-join-executor {
       fork-join-executor {
-        parallelism-min = 8
+        parallelism-min = 1    # don't constrain parallelism statically
+        parallelism-max = 64   # --
         parallelism-factor = 1 # one thread per core is enough
         parallelism-factor = 1 # one thread per core is enough
-        parallelism-max = 64
-        task-peeking-mode = "FIFO"
       }
       }
       throughput = 64
       throughput = 64
     }
     }
-
-    debug {
-      lifecycle = off
-      receive   = off
-      unhandled = on
-    }
   }
   }
 
 
   http {
   http {
     server {
     server {
-      backlog = 1256
-      linger-timeout = 25 s
-      max-connections = 1256
-      pipelining-limit = 32
-      response-header-size-hint = 1024
+      backlog = 1024
     }
     }
   }
   }
 }
 }
@@ -57,12 +34,12 @@ akka-http-slick-postgres {
   }
   }
 
 
   database {
   database {
-    profile = "net.benchmark.akka.http.db.CustomPostgresProfile$"
+    profile = "slick.jdbc.PostgresProfile$"
     db {
     db {
       url = "jdbc:postgresql://tfb-database:5432/hello_world?user=benchmarkdbuser&password=benchmarkdbpass"
       url = "jdbc:postgresql://tfb-database:5432/hello_world?user=benchmarkdbuser&password=benchmarkdbpass"
     }
     }
-    numThreads = 40
-    queueSize = 20000
-    maxConnections = 96
+    numThreads = 512
+    queueSize = 10000
+    maxConnections = 512
   }
   }
 }
 }

+ 15 - 0
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/resources/application.ini

@@ -0,0 +1,15 @@
+-d64
+-server
+-Xmx2G
+-Xms2G
+-XX:+UseG1GC
+-XX:ParallelGCThreads=4
+-XX:MetaspaceSize=192M
+-XX:MaxMetaspaceSize=192M
+-XX:+UseStringDeduplication
+-Dcom.sun.management.jmxremote=false
+-Dcom.sun.management.jmxremote.local.only=false
+-Dcom.sun.management.jmxremote.authenticate=false
+-Dcom.sun.management.jmxremote.ssl=false
+-Djava.awt.headless=true
+-Djava.net.preferIPv4Stack=true

+ 2 - 3
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/ApiRoutes.scala

@@ -15,8 +15,7 @@ object ApiRoutes {
 
 
   private val log: Logger = LoggerFactory.getLogger(getClass)
   private val log: Logger = LoggerFactory.getLogger(getClass)
 
 
-  def routes(dbLoader: DatabaseRepositoryLoader,
-             sd: ExecutionContextExecutor)(implicit system: ActorSystem): Route =
+  def routes(dbLoader: DatabaseRepositoryLoader, sd: ExecutionContextExecutor)(implicit system: ActorSystem): Route =
     handleRejections(RejectionHandler.default) {
     handleRejections(RejectionHandler.default) {
       val eh: ExceptionHandler = ExceptionHandler {
       val eh: ExceptionHandler = ExceptionHandler {
         case ex @ (_: Exception) =>
         case ex @ (_: Exception) =>
@@ -30,7 +29,7 @@ object ApiRoutes {
       handleExceptions(eh) {
       handleExceptions(eh) {
         get {
         get {
           worldRoutes.routes() ~
           worldRoutes.routes() ~
-          fortuneRoutes.route()
+            fortuneRoutes.route()
         }
         }
       }
       }
     }
     }

+ 3 - 7
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/Main.scala

@@ -3,15 +3,11 @@ import akka.actor.{ActorRef, ActorSystem, Terminated}
 import akka.stream.ActorMaterializer
 import akka.stream.ActorMaterializer
 import com.typesafe.config.Config
 import com.typesafe.config.Config
 import net.benchmark.akka.http.ApiSupervisor.ApiMessages
 import net.benchmark.akka.http.ApiSupervisor.ApiMessages
-import net.benchmark.akka.http.db.{
-  CustomPostgresProfile,
-  DatabaseConfiguration,
-  DatabaseRepositoryLoader,
-  DatabaseRepositoryLoaderModule
-}
+import net.benchmark.akka.http.db.{DatabaseConfiguration, DatabaseRepositoryLoader, DatabaseRepositoryLoaderModule}
 import net.benchmark.akka.http.util.SameThreadDirectExecutor
 import net.benchmark.akka.http.util.SameThreadDirectExecutor
 import org.slf4j.{Logger, LoggerFactory}
 import org.slf4j.{Logger, LoggerFactory}
 import slick.basic.DatabaseConfig
 import slick.basic.DatabaseConfig
+import slick.jdbc.PostgresProfile
 
 
 import scala.concurrent.Future
 import scala.concurrent.Future
 
 
@@ -25,7 +21,7 @@ object Main {
 
 
     val config: Config = system.settings.config
     val config: Config = system.settings.config
 
 
-    val dbConfig: DatabaseConfig[CustomPostgresProfile] = DatabaseConfiguration.getDefaultDatabaseConfiguration(config)
+    val dbConfig: DatabaseConfig[PostgresProfile] = DatabaseConfiguration.getDefaultDatabaseConfiguration(config)
     val dbLoader: DatabaseRepositoryLoader = new DatabaseRepositoryLoaderModule(dbConfig)
     val dbLoader: DatabaseRepositoryLoader = new DatabaseRepositoryLoaderModule(dbConfig)
 
 
     val api: ActorRef = system.actorOf(ApiSupervisor.props(dbLoader, mat))
     val api: ActorRef = system.actorOf(ApiSupervisor.props(dbLoader, mat))

+ 0 - 22
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/db/CustomPostgresProfile.scala

@@ -1,22 +0,0 @@
-package net.benchmark.akka.http.db
-
-import com.github.tminglei.slickpg._
-import slick.basic.Capability
-import slick.jdbc.JdbcCapabilities
-
-trait CustomPostgresProfile extends ExPostgresProfile with PgArraySupport with PgDateSupport with PgDate2Support {
-
-  // Add back `capabilities.insertOrUpdate` to enable native `upsert` support; for postgres 9.5+
-  override protected def computeCapabilities: Set[Capability] =
-    super.computeCapabilities + JdbcCapabilities.insertOrUpdate
-
-  // IMPORTANT: Do not add a type annotation here or you'll trigger an error. See https://github.com/tminglei/slick-pg/issues/303#issuecomment-252403085
-  override val api = MyAPI
-
-  object MyAPI extends API with ArrayImplicits with SimpleDateTimeImplicits with DateTimeImplicits
-}
-
-/**
-  * The actual postgresql profile useable by the application.
-  */
-object CustomPostgresProfile extends CustomPostgresProfile

+ 4 - 3
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/db/DatabaseConfiguration.scala

@@ -2,6 +2,7 @@ package net.benchmark.akka.http.db
 
 
 import com.typesafe.config.Config
 import com.typesafe.config.Config
 import slick.basic.DatabaseConfig
 import slick.basic.DatabaseConfig
+import slick.jdbc.PostgresProfile
 
 
 object DatabaseConfiguration {
 object DatabaseConfiguration {
 
 
@@ -13,12 +14,12 @@ object DatabaseConfiguration {
     * @param config A configuration.
     * @param config A configuration.
     * @return A slick database configuration.
     * @return A slick database configuration.
     */
     */
-  def getDatabaseConfiguration(path: String)(config: Config): DatabaseConfig[CustomPostgresProfile] = {
-    DatabaseConfig.forConfig[CustomPostgresProfile](path, config)
+  def getDatabaseConfiguration(path: String)(config: Config): DatabaseConfig[PostgresProfile] = {
+    DatabaseConfig.forConfig[PostgresProfile](path, config)
   }
   }
 
 
   // Load the database configuration from the default path.
   // Load the database configuration from the default path.
-  val getDefaultDatabaseConfiguration: Config => DatabaseConfig[CustomPostgresProfile] = getDatabaseConfiguration(
+  val getDefaultDatabaseConfiguration: Config => DatabaseConfig[PostgresProfile] = getDatabaseConfiguration(
     "akka-http-slick-postgres.database")
     "akka-http-slick-postgres.database")
 
 
 }
 }

+ 2 - 2
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/db/DatabaseRepositoryLoader.scala

@@ -3,6 +3,7 @@ package net.benchmark.akka.http.db
 import net.benchmark.akka.http.fortune.{FortuneRepository, FortuneRepositoryModule}
 import net.benchmark.akka.http.fortune.{FortuneRepository, FortuneRepositoryModule}
 import net.benchmark.akka.http.world.{WorldRepository, WorldRepositoryModule}
 import net.benchmark.akka.http.world.{WorldRepository, WorldRepositoryModule}
 import slick.basic.DatabaseConfig
 import slick.basic.DatabaseConfig
+import slick.jdbc.PostgresProfile
 
 
 trait DatabaseRepositoryLoader {
 trait DatabaseRepositoryLoader {
 
 
@@ -14,8 +15,7 @@ trait DatabaseRepositoryLoader {
 
 
 }
 }
 
 
-final class DatabaseRepositoryLoaderModule(dbConfig: DatabaseConfig[CustomPostgresProfile])
-    extends DatabaseRepositoryLoader {
+final class DatabaseRepositoryLoaderModule(dbConfig: DatabaseConfig[PostgresProfile]) extends DatabaseRepositoryLoader {
 
 
   override def close(): Unit = dbConfig.db.close()
   override def close(): Unit = dbConfig.db.close()
 
 

+ 5 - 5
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/fortune/FortuneRepositoryModule.scala

@@ -1,11 +1,11 @@
 package net.benchmark.akka.http.fortune
 package net.benchmark.akka.http.fortune
 
 
-import net.benchmark.akka.http.db.CustomPostgresProfile
-import net.benchmark.akka.http.db.CustomPostgresProfile.api._
+import slick.jdbc.PostgresProfile
+import slick.jdbc.PostgresProfile.api._
 import slick.basic.{DatabaseConfig, DatabasePublisher}
 import slick.basic.{DatabaseConfig, DatabasePublisher}
 import slick.jdbc.{ResultSetConcurrency, ResultSetType}
 import slick.jdbc.{ResultSetConcurrency, ResultSetType}
 
 
-class FortuneRepositoryModule(val dbConfig: DatabaseConfig[CustomPostgresProfile]) extends FortuneRepository {
+class FortuneRepositoryModule(val dbConfig: DatabaseConfig[PostgresProfile]) extends FortuneRepository {
 
 
   private val db = dbConfig.db
   private val db = dbConfig.db
 
 
@@ -14,8 +14,8 @@ class FortuneRepositoryModule(val dbConfig: DatabaseConfig[CustomPostgresProfile
   override def all(): DatabasePublisher[Fortune] = {
   override def all(): DatabasePublisher[Fortune] = {
     db.stream(
     db.stream(
       fortunes.result.withStatementParameters(rsType = ResultSetType.ForwardOnly,
       fortunes.result.withStatementParameters(rsType = ResultSetType.ForwardOnly,
-                                              rsConcurrency = ResultSetConcurrency.ReadOnly,
-                                              fetchSize = 100))
+        rsConcurrency = ResultSetConcurrency.ReadOnly,
+        fetchSize = 100))
   }
   }
 
 
 }
 }

+ 1 - 1
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/fortune/FortuneTable.scala

@@ -1,6 +1,6 @@
 package net.benchmark.akka.http.fortune
 package net.benchmark.akka.http.fortune
 
 
-import net.benchmark.akka.http.db.CustomPostgresProfile.api._
+import slick.jdbc.PostgresProfile.api._
 
 
 object FortuneTable {
 object FortuneTable {
 
 

+ 3 - 3
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/world/WorldRepositoryModule.scala

@@ -1,12 +1,12 @@
 package net.benchmark.akka.http.world
 package net.benchmark.akka.http.world
 
 
-import net.benchmark.akka.http.db.CustomPostgresProfile
-import net.benchmark.akka.http.db.CustomPostgresProfile.api._
 import slick.basic.DatabaseConfig
 import slick.basic.DatabaseConfig
+import slick.jdbc.PostgresProfile
+import slick.jdbc.PostgresProfile.api._
 
 
 import scala.concurrent.Future
 import scala.concurrent.Future
 
 
-class WorldRepositoryModule(val dbConfig: DatabaseConfig[CustomPostgresProfile]) extends WorldRepository {
+class WorldRepositoryModule(val dbConfig: DatabaseConfig[PostgresProfile]) extends WorldRepository {
 
 
   private val db = dbConfig.db
   private val db = dbConfig.db
 
 

+ 1 - 2
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/world/WorldRoutes.scala

@@ -4,8 +4,7 @@ import akka.http.scaladsl.server.Route
 
 
 import scala.concurrent.ExecutionContextExecutor
 import scala.concurrent.ExecutionContextExecutor
 
 
-class WorldRoutes(wr: WorldRepository,
-                  sd: ExecutionContextExecutor) {
+class WorldRoutes(wr: WorldRepository, sd: ExecutionContextExecutor) {
 
 
   private val qr = new QueriesRoute(wr).route()
   private val qr = new QueriesRoute(wr).route()
   private val ur = new UpdateRoute(wr, sd).route()
   private val ur = new UpdateRoute(wr, sd).route()

+ 1 - 1
frameworks/Scala/akka-http/akka-http-slick-postgres/src/main/scala/net/benchmark/akka/http/world/WorldTable.scala

@@ -1,6 +1,6 @@
 package net.benchmark.akka.http.world
 package net.benchmark.akka.http.world
 
 
-import net.benchmark.akka.http.db.CustomPostgresProfile.api._
+import slick.jdbc.PostgresProfile.api._
 
 
 object WorldTable {
 object WorldTable {