Tame Your Data with Akka Streams and Java 8
summary
Live coding shows a working Akka Streams pipeline (Java 8) that reads gzipped CSVs, framing delimiter splits ByteString by newline, and uses mapAsync to parse lines into a domain Reading (handles invalid lines with Vavr Try/List), groups pairs by ID, computes averages (default −1 for missing values), and writes results to Cassandra via async saves. Pipeline runs on the default ActorMaterializer with a custom graph DSL balancer to process multiple files in parallel; demo runs against Cassandra in Docker and logs invalid lines while completing successfully.
AI-written summary · about
chapters (13)
- 0:00Introduction to Akka Streams
- 1:04Reactive streams and backpressure
- 5:16Why Akka Streams with Java
- 6:40Use case and domain model
- 12:01Parsing CSV files with Akka
- 22:27Computing averages from readings
- 28:53Combining processing flows
- 31:02Saving data to Cassandra
- 37:15Building the full pipeline
- 41:16Parallel file processing
- 44:32Creating a load balancer
- 50:40Demo and results
- 51:20Further resources and Q&A
