Class: SidekiqUniqueJobs::OnConflict::Log

Inherits:
OnConflict::Strategy
  • Object
show all
Includes:
Logging
Defined in:
lib/sidekiq_unique_jobs/on_conflict/log.rb

Overview

Strategy to log information about conflict

Author:

Instance Method Summary collapse

Methods included from Logging

#build_message, included, #log_debug, #log_error, #log_fatal, #log_info, #log_warn, #logger, #logging_context, #with_configured_loggers_context, #with_logging_context

Instance Method Details

#callvoid

This method returns an undefined value.

Logs an informational message about that the job was not unique



17
18
19
20
21
# File 'lib/sidekiq_unique_jobs/on_conflict/log.rb', line 17

def call
  log_info(<<~MESSAGE.chomp)
    Skipping job with id (#{item[JID]}) because lock_digest: (#{item[LOCK_DIGEST]}) already exists
  MESSAGE
end