'How to trigger after_create_commit through run_callbacks method

Currently i am doing a bulk insert for some records and using insert_all skip all the AR callbacks i want to trigger them manually, I have found that run_callbacks dose the trick but i couldn't get it to trigger this callback after_create_commit. I tried run_callbacks(:commit) but doesn't trigger it.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source