delayed_jobs_verify_db_connection.rb 291 B

123456789101112
  1. # Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. require 'delayed_job'
  3. module Delayed
  4. class Job < ::ActiveRecord::Base # rubocop:disable Rails/ApplicationRecord
  5. def self.recover_from(_error)
  6. ::ActiveRecord::Base.connection.verify!
  7. end
  8. end
  9. end