Ractor Enhancements, 2024
summary
Introduces an interrupt_exec API that runs a block on the main ractor by creating a helper thread so child ractors can perform require safely (handles return values and load errors), notes compatibility issues with overrides like RubyGems/Bundler and proposes a prepend guard. Adds a timer native thread to register/unregister cross‑ractor timeouts; benchmark with 1,000,000 zero‑second tasks shows previous per‑ractor monitors take ~5 minutes versus ~3m03s for the native timer (coarse clock halves overhead). Finds GC pain when creating 50,000 ractors and calls for ractor‑aware GC tuning and local GC.
AI-written summary · about
chapters (7)
- 0:00Introduction to Ractor
- 1:36Ractor limitations
- 5:58Implementing require in Ractor
- 10:35Ractor execution mechanics
- 17:43Debugging in Ractor
- 19:16Timeout mechanisms
- 24:12Memory management and GC
related talks
30mRactor on Ruby 3.4
28mCome Discuss Ractors and Concurrency with 'The Dude'!
25mRactor Demonstration
28mRactors in Ruby 4.0: Message Passing Without the Pain
29mMillion-Agent Ruby: Ractor-Local GC in the Age of AI
27mParallel testing with Ractors - Putting CPU's to work
29mUsing Ractors and Making Ractors Usable
35mConcurrency in Ruby: Threads, Fibers and Ractors Demystified
