Talks
Speakers
Events
Topics
Sign in
Home
Talks
Speakers
Events
Topics
Leaderboard
Use
Analytics
Sign in
Suggest modification to this talk
Title
Description
The majority of performance improvements in modern processors are due to increased core count rather than increased instruction execution frequency. To maximise hardware utilization, applications need to use multiple processes and threads. Servers that process discrete requests are a good candidate for both parallelization and concurrency improvements. We discuss different ways in which servers can improve processor utilization and how these different approaches affect application code. We show that fibers require minimal changes to existing application code and are thus a good approach for retrofitting existing systems. RubyKaigi 2019 https://rubykaigi.org/2019/presentations/ioquatix.html#apr18
Date
Summarized using AI?
If this talk's summary was generated by AI, please check this box. A "Summarized using AI" badge will be displayed in the summary tab to indicate that the summary was generated using AI.
Show "Summarized using AI" badge on summary page
Summary
Markdown supported
In the talk titled "Fibers Are the Right Solution," Samuel Williams addresses the scalability of Ruby applications, emphasizing the importance of optimizing performance in the context of modern processor architectures. The presentation begins by defining scalability as a system's capability to proportionally increase job processing capacity by adding more hardware. Williams highlights that Ruby web applications often suffer from significant latency due to blocking I/O operations, which leads to inefficient hardware utilization. To tackle these issues, he discusses key strategies for improving utilization, such as concurrency and parallelism, before focusing on the potential of fibers as a solution. ### Key Points Discussed: - **Definition of Scalability:** The ability of a system to efficiently process increased workloads through proportional hardware enhancement. - **Blocking I/O as a Bottleneck:** Ruby applications often face performance hurdles due to excessive waiting times for I/O operations, making efficient processing challenging. - **Historical Context of Utilization Improvement:** Reference to time-sharing in early computing to underscore the evolution of concurrency and parallelism in systems. - **Comparison of Concurrency Approaches:** The advantages and disadvantages of processes and threads in Ruby, particularly under the constraints of the global interpreter lock (GIL). - **Event-Driven vs Traditional Approaches:** The effectiveness of an event-driven, non-blocking I/O model over traditional synchronous models in handling large numbers of connections directly impacts scalability. - **Advantages of Fibers:** Unlike callbacks, fibers treat I/O operations more seamlessly, allowing programs to maintain a clear logical structure without becoming overly convoluted through nested callbacks. - **Practical Implementation Using Async:** Incorporating non-blocking I/O implementations into existing Ruby applications with minimal alterations, increasing scalability without sacrificing code readability. - **Performance Demonstrations:** Comparisons between traditional Ruby servers and Falcon, a new server that employs the async framework, showing significant performance improvements. ### Conclusions: Samuel concludes that adopting fibers enables Ruby developers to enhance the scalability of their applications with minimal changes. By transforming blocking operations into non-blocking calls, developers can maximize hardware capabilities in I/O-bound scenarios. The presentation encapsulates a strong recommendation for the Ruby community to embrace fibers as a forward-looking approach to scaling Ruby applications effectively and sustainably.
Suggest modifications
Cancel