Talks
Speakers
Events
Topics
Sign in
Home
Talks
Speakers
Events
Topics
Leaderboard
Use
Analytics
Sign in
Suggest modification to this talk
Title
Description
RailsConf 2017: In Relentless Pursuit of REST by Derek Prior "That's not very RESTful." As a Rails developer you've probably heard or even spoken that proclamation before, but what does it really mean? What's so great about being RESTful anyway? RESTful architecture can narrow the responsibilities of your Rails controllers and make follow-on refactorings more natural. In this talk, you'll learn to refactor code to follow RESTful principles and to identify the positive impact those changes have throughout your application stack.
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 presentation "In Relentless Pursuit of REST" by Derek Prior at RailsConf 2017, the focus is on the significance of RESTful architecture in improving Rails applications. Derek emphasizes the benefits of adhering to REST principles, arguing that they lead to clearer, more maintainable code, which aids developers in managing the growth of Rails applications effectively. Key Points: - **Understanding REST:** Derek begins by addressing the misinterpretation of REST and the debate over its implementation, indicating that while many feel they are not adhering to REST, the primary value lies in consistency rather than strict semantic adherence. - **Importance of Nouns and Verbs:** Emphasizing the distinction between resources (nouns) and actions (verbs), he advocates for a focus on these elements to simplify code structure. This approach leads to the creation of smaller, well-defined controllers and models, countering Rails anti-patterns. - **Common Anti-Patterns:** Derek identifies several common anti-patterns in Rails applications: - **Custom Actions**: He suggests avoiding unnecessary complexity by utilizing standard REST actions instead of creating custom ones. - **Complex Actions**: He highlights problems with overly complex controller actions and promotes the use of smaller service objects to encapsulate business logic. - **Ambiguous Language**: The need for a ubiquitous language throughout the application is underlined to prevent confusion and miscommunication. - **State Machines:** Derek critiques the common implementation of state machines in Rails, which tend to become bloated. He suggests that breaking complex logic into smaller objects can lead to cleaner, more understandable code. - **Refactorings for Clarity:** The speaker illustrates how refactoring code to better align with REST principles can lead to clearer language and more maintainable applications. - **Boring Code Philosophy:** The talk concludes on the idea that boring code—simple, predictable functions and classes—is desirable in a Rails project for reducing errors and easing maintenance. Derek’s final takeaway is that every Rails developer should embrace RESTful design principles and aim to create boring, straightforward code that inherently improves the application's longevity and reduces the likelihood of bugs. By being methodical and consistent in how REST is applied, developers can harness the full power of the Rails framework, emphasizing business logic instead of convoluted implementation details.
Suggest modifications
Cancel