The inherent unreliability of after_commit callbacks and most service objects
Service objects and/or after_commit
callbacks are ubiquitous in most real-world Rails applications. Whether it’s a good idea or not (ActiveRecord callbacks - I’m looking at you) is a different story, but one thing that is notoriously overlooked in the application design is reliability. And yes, the service objects are equally bad as after_commit
callbacks in that regard.
Let’s explore the concept of reliability and also some solutions that can help solve the problem.
Post a comment