More Adapters, Less Implementations
In this chapter, we take a tour of the satellite frameworks of Ruby on Rails, such as Active Job and Active Storage, and learn about their design patterns and techniques. We will start by talking about the adapter pattern and how it relates to the flexibility, extensibility, and testability of code. We will also discuss the technique of object serialization in the context of Active Job. Finally, when talking about Active Storage, we will compare the adapter pattern with the plugin-based architecture.
We will cover the following topics:
- Active Job as a universal queue interface
- Active Storage and its adapters and plugins
- Adapters and wrappers at your service
This chapter aims to familiarize the reader with design techniques that could help to separate the application code from specific third-party implementations and make application code extensible and testable.