-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Description
The current default behavior of the quebert worker loop is to exit the quebert process when an exception is raised:
https://github.com/polleverywhere/quebert/blob/master/lib/quebert/worker.rb#L33
Change the default to log the exception and bury the job for later inspection. Also make the object passed into the error proc a custom struct/class for better error encapsulation.
- Change the default behavior at https://github.com/polleverywhere/quebert/blob/master/lib/quebert/worker.rb#L33 to log the error to
Quebert.logger.errorand bury the job. - Create a
Quebert::Worker::Errorobject that's passed into the exception handler proc via https://github.com/polleverywhere/quebert/blob/master/lib/quebert/worker.rb#L26.-
#to_smethod returns all of the info needed for thelogger.errorcall (e.g.Quebert.logger.error(worker_error)
-
Since this breaks the 3.0 error handler API this should belong on Quebert 4.0.