Async Ruby
summary
Async Ruby claims real concurrency for blocking IO by running tasks run concurrently inside an async block, using an event reactor backed by nio4r + libuv, fibers and Ruby 3 fiber scheduler. Examples show uri.open http, httparty, Redis, SSH, SQL queries and system commands all completing in parallel, with 600 concurrent operations in ~2.5s and single‑digit‑million task limits reported. ActiveRecord is not yet supported; production use and a 3x cost reduction case are cited.
AI-written summary · about
chapters (13)
- 0:00Start
- 1:04About
- 1:58Async programming?
- 3:45Why make programs async?
- 4:17Ruby is synchronous
- 4:38Threads
- 5:19Thread problems
- 7:23Async Ruby
- 17:44How does it work?
- 18:01How does it work: event reactor
- 19:17How does it work: fibers
- 20:13How does it work: fiber scheduler
- 22:58Conclusion
related talks
39mAsynchronous and Non-Blocking IO with JRuby
35mConcurrency in Ruby: Threads, Fibers and Ractors Demystified
33mAsynchronous Rails
36mModern Concurrency Practices in Ruby
30mAdvanced Multithreading in Ruby
27mIn-Depth Ruby Concurrency: Navigating the Ruby concurrency landscape
54mConcurrency: Rubies, plural
26mConcurrency in Ruby: From fork() to Fiber
