Merge pull request #5551 from betagouv/fix_uninitialized_excon_constant
Fix uninitialized excon constant
This commit is contained in:
commit
7038ca6c04
2 changed files with 4 additions and 1 deletions
|
@ -1,7 +1,7 @@
|
||||||
class ApplicationJob < ActiveJob::Base
|
class ApplicationJob < ActiveJob::Base
|
||||||
DEFAULT_MAX_ATTEMPTS_JOBS = 25
|
DEFAULT_MAX_ATTEMPTS_JOBS = 25
|
||||||
|
|
||||||
retry_on Excon::Error::BadRequest
|
retry_on ::Excon::Error::BadRequest
|
||||||
|
|
||||||
before_perform do |job|
|
before_perform do |job|
|
||||||
Rails.logger.info("#{job.class.name} started at #{Time.zone.now}")
|
Rails.logger.info("#{job.class.name} started at #{Time.zone.now}")
|
||||||
|
|
3
config/initializers/excon_setup.rb
Normal file
3
config/initializers/excon_setup.rb
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
# needed as ApplicationJob retry on excon error
|
||||||
|
# and this lib is not explicity loaded by the Gemfile
|
||||||
|
require 'excon'
|
Loading…
Reference in a new issue