Functional programming in Kotlin: exploring Arrow
summary
Walks through concrete Arrow usage: error handling with Either.left / Either.right where left holds a sealed BadState (NotFound or CatchAll) and right holds values, shows Either.catch for exception wrapping, and replaces nested flatMap with a Either.eager and .bind monad comprehension to keep service code imperative. Demonstrates a pseudo Spring/Micronaut booking example where controller pattern matches to return 404 or 500. Shows optics with @optics-generated lenses to immutably update deep fields. Notes Arrow 1.0 ships last year and is production ready.
AI-written summary · about
chapters (7)
- 0:00Introduction
- 3:20What is functional programming
- 10:26Introducing Arrow library
- 18:25Error handling with Either
- 23:03Monad comprehensions in practice
- 25:01Immutability and optics
- 29:17Conclusion and Q&A
related talks
47mFunctional programming in Kotlin: exploring Arrow
41mAn Arrow to the Kotlin
27mLeveraging the power of Arrow
40mArchitecting Typed FP Applications & Libraries in Kotlin with Arrow
48mKotlin & Functional Programming: pick the best, skip the rest
34mFunctional Programming in Kotlin for AndroidDevs
32mFrom Exception Hell to Typed Bliss: Real-World Error Handling with Kotlin and Arrow
51mFunctional fashion for Kotlin projects
