A Dive Into Akka Streams
summary
Collector service migrates to Akka Streams to enforce backpressure on the network and stop prolific sensors from exhausting memory, using framing + chunk buffer to split lines, a custom persistent buffer GraphStage to retain events during Kinesis outages, and a Kinesis publisher actor wired via mapAsync + ask pattern with retries. Materialized TestSource/TestSink make flow testing simpler. The result is a reactive pipeline that prevents data loss, bounds ingestion speed, runs many concurrent streams, and recovers unsent events when Kinesis comes back.
AI-written summary · about
chapters (19)
- 0:00Introduction and speakers
- 1:13Problem and agenda overview
- 2:15Original data pipeline architecture
- 3:21Actor model limitations
- 5:53Reactive system requirements
- 7:22Recovery mechanism design
- 8:46Back pressure benefits
- 11:02Akka Streams fundamentals
- 14:37Web server integration
- 16:02Chunk processing and framing
- 17:08Persistent buffer implementation
- 18:10Custom stage development
- 21:48Kinesis publisher setup
- 23:56Side effects and metrics
- 24:39Threading and async boundaries
- 27:30Error handling and supervision
- 28:55Stream shapes and graphs
- 30:00Key learnings summary
- 32:54Q&A session
