~/talk

Go with the Flow!

Talkat droidcon London 2022 · 2022-10-27..10-28· [kotlin]
links:none on file
slides:none on file

Shows how to implement concrete Kotlin coroutines Flow operators: a partition operator that returns two cold flows (evens and odds) implemented with flow builders and collect, a takeUntil implemented with channelFlow and send that launches a producer coroutine and cancels it when a signal flow or duration fires, and a groupBy that creates 10 flows of 10 elements using per-key channels (uses Channel.UNLIMITED by default to avoid deadlock). Examples run and behave as expected; RxJava equivalents span thousands of lines while these implementations stay compact.

AI-written summary · about

  1. 0:00Introduction
  2. 0:27What is Kotlin Flow
  3. 1:07Why use Flow over RxJava
  4. 2:13Implementing partition operator
  5. 4:00Coroutines and structured concurrency
  6. 10:27Take until operator explained
  7. 12:37Channel flow for concurrency
  8. 19:43Flow vs RxJava implementation
  9. 21:34Group by operator introduction
  10. 22:38Using group by in practice
  11. 25:11Implementing group by operator
  12. 31:14Back pressure and channel buffers
  13. 36:10Handling exceptions and cleanup
  14. 37:17Demo of group by operator
  15. 37:42Flow vs RxJava comparison
  16. 39:08Closing and Q&A
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.