Problem You want to have a way to skip all callbacks for all models in Rails. Before we begin Two things: Skip callbacks if this is a debugging session Don't try to skip all callbacks in your business logic or production code. This is a strong hint...

Markdown supported · ⌘↵ to post
Hassan Latif
Approach 3 is not correct for production applications. As we know that production applications is multi threaded and handles multiple requests at a single time. So If I have used this approach for a model lets say User and lets say my piece of code is running for one thread and same model is being called from another call then its validations and callbacks will be skipped for the second call as well. This approach can work for single threaded applications but this is not thread safe approach.