eestrada/psyllium: A Ruby gem making it easier to use Fibers.
22-Mar-2025 63
Psyllium is a library to make it easier to use Ruby Fibers for everyday programming.
Ruby 3.0 introduced the Fiber Scheduler interface, making it easier to use Fibers for concurrent programming. However, native Thread objects still have several useful methods that Fibers do not have.
The Psyllium library adds many of these methods to the builtin Fiber class such as start, join, value, and others to make it easier to replace Thread usage with Fiber usage, or to mix and match Thread and Fiber usage without concern for which concurrency primitive is being used.
Assuming that a Fiber Scheduler is set, Psyllium Fibers can be used in ways similar to Threads, with a similar interface, and with the added benefit of much lower memory usage compared to native Threads.
eestrada/psyllium: A Ruby gem making it easier to use Fibers. #ruby #rubydeveloper #rubyonrails #eestrada/psyllium: #making #easier #Fibers. #gem https://rubyonrails.ba/link/eestrada-psyllium-a-ruby-gem-making-it-easier-to-use-fibers