exception-notifier

Error reporting when sending emails with delayed_job

流过昼夜 提交于 2020-01-12 14:26:23
问题 What's the proper way to get error reports, when using a tool like AirBrake or ExceptionNotifier from mailing delayed jobs? I tried to creating my own delayed job class, but the mail object created by Mailer.welcome() (or similar) is not serialized correctly. I also tried adding an error(job, exception) method to the PerformableMailer and PerformableMethod classes, but I got more errors generally related to serializing I believe. I tried both psych and sych for the serialization. 回答1: Updated

Error reporting when sending emails with delayed_job

对着背影说爱祢 提交于 2019-12-04 03:23:39
What's the proper way to get error reports, when using a tool like AirBrake or ExceptionNotifier from mailing delayed jobs? I tried to creating my own delayed job class, but the mail object created by Mailer.welcome() (or similar) is not serialized correctly. I also tried adding an error(job, exception) method to the PerformableMailer and PerformableMethod classes, but I got more errors generally related to serializing I believe. I tried both psych and sych for the serialization. Updated Solution Overall the solution is quite simple. If you have are doing delayed_job on an Object (like MyClass