Talks
Speakers
Events
Topics
Sign in
Home
Talks
Speakers
Events
Topics
Leaderboard
Use
Analytics
Sign in
Suggest modification to this talk
Title
Description
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 this talk titled 'Caching with MessagePack,' Chris Salzberg, a staff developer for the Ruby and Rails core team at Shopify, explores the nuances and challenges of caching in web applications using MessagePack as a serialization format. The discussion is rooted in a past incident where an object's versioning issue led to a production failure, prompting the need for a more robust caching strategy that would allow for safer serialization and deserialization. Key Points Discussed: - Overview of caching in web applications, including the types of data that can be cached, such as actions, pages, query results, and API responses. - Examination of traditional caching methods using Marshal, its benefits, and the inherent security risks involved, particularly when dealing with user-generated data. - Introduction to MessagePack as an alternative to Marshal, highlighting its efficiency as a binary serialization format that does not attempt to capture the entire state of the universe, hence mitigating versioning conflicts after deployments. - Features of MessagePack that set it apart from Marshal, including its focus on efficient serialization without tracking instance variables, resulting in reduced overhead and smaller serialized sizes. - Practical experiences at Shopify, including significant reductions in cache size when switching from Marshal to MessagePack, with specific examples demonstrating a ratio improvement in serialization sizes. - Solutions developed to handle complex structures in ActiveRecord and customizable behaviors with subclassed hashes, enhancing the serialization capabilities - Overall impact of integrating MessagePack into their workflow, leading to improved efficiency and productivity in their development processes. The talk highlights how understanding the mechanics of serialization can lead to better caching strategies, thereby promoting smoother transitions for developers working with Ruby and Rails.
Suggest modifications
Cancel