Alpakka sample
Read from a database and publish to Elasticsearch
This example uses Alpakka Slick to read from a database, and stores the data in Elasticsearch.
Browse the sources at Github.
To try out this project clone the Alpakka Samples repository and find it in the alpakka-sample-jdbc-to-elasticsearch
directory.
Dependencies
- Dependencies (sbt notation)
-
source
val AkkaVersion = "2.9.0" val AlpakkaVersion = "7.0.2" val AkkaDiagnosticsVersion = "2.1.0" "com.typesafe.akka" %% "akka-stream" % AkkaVersion, "com.typesafe.akka" %% "akka-actor-typed" % AkkaVersion, "com.lightbend.akka" %% "akka-stream-alpakka-elasticsearch" % AlpakkaVersion, "com.lightbend.akka" %% "akka-stream-alpakka-slick" % AlpakkaVersion, "com.lightbend.akka" %% "akka-diagnostics" % AkkaDiagnosticsVersion, // for JSON in Scala "io.spray" %% "spray-json" % "1.3.6", // Logging "com.typesafe.akka" %% "akka-slf4j" % AkkaVersion, "ch.qos.logback" % "logback-classic" % "1.2.11",
All Alpakka samples
Show Alpakka samples listing.