Composing Schedulers using Effect Handlers
summary
Claims a concrete interface that makes different OCaml 5 effect-based schedulers interoperate: a suspend effect that captures a task continuation and a resume enqueues to target scheduler implementation, plus scheduler-agnostic sync primitives (implemented as ember.take/put on a shared mvar-like queue). Prototype uses Eio and domains (domain workers run parallel Fibonacci-45 per request), an HTTP server benchmark on a 4-core machine shows higher throughput as domains increase (with higher latencies). Notes cancellation and thread-safety as ongoing work.
AI-written summary · about
chapters (9)
- 0:00Effect handlers in OCaml 5
- 1:26Eio vs Domain.Sys schedulers
- 2:27Blocking in Eio scheduler
- 3:32Parallelism with Domain.Sys
- 4:59Unified scheduler interface
- 6:06Emba channels solution
- 9:02HTTP server benchmark
- 9:45Other languages' approaches
- 10:50Future scope
related talks
25mPicos — Interoperable effects based concurrency
30mControlled Scheduling of Concurrent Elixir Programs
36mConcurrency with Cats-effect
34mFrom OCaml 4 to 5 and from Parmap to Effects: A legacy code transition story
32mCATS EFFECT - DISPATCHER, SUPERVISOR, IOLOCAL
01h 02mStructured Concurrency: Managing the Hierarchical Cancelation and Error Handling
30mMonadic interpreters for concurrent memory models: Executable semantics of a concurrent(…)
54mStructured Concurrency: Hierarchical Cancellation & Error Handling
