~/talk

Using Kotlin Coroutines for Asynchronous and Concurrent Programming

Talkat NDC Porto 2019 · 2019-02-26..03-01· [kotlin]
links:none on file
slides:none on file

Kotlin 1.3 uses suspend functions and coroutine builders to get sequential-looking code that suspends without blocking threads, demonstrated with Spring + Tomcat where 500 rps × 2s latency would otherwise mean ~1000 blocked threads (~1GB stack). Legacy futures are bridged via suspendCoroutine and lightweight async/await-style extension functions; structured cancellation is enforced by coroutine scope so request timeouts cancel child coroutines within milliseconds. Also shows mutexes, channels and confinement (single-coroutine ownership) for safe concurrency.

AI-written summary · about

  1. 0:00Intro
  2. 2:50Why Asynchronous?
  3. 11:02Callbacks, Futures, Observables
  4. 13:10The challenge
  5. 17:24Kotlin Coroutines
  6. 30:54A Spring controller
  7. 38:33Coroutine Scope
  8. 39:43Parent-child coroutine relations
  9. 40:59What is a scope?
  10. 47:12How about concurrency?
  11. 58:34Resources
~/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.