Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow user to disable default job logging #6200

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mperham
Copy link
Collaborator

@mperham mperham commented Feb 16, 2024

This PR adds a new configuration knob, :skip_default_job_logging, to disable job logging out of the box, see #6199.

The user can choose when and where to disable the logging. I would recommend leaving it enabled for a reasonable developer experience but in environments like a high-volume production setup, logging output can be significant. This allows the user to opt-out of the logging if it becomes an issue.

Sidekiq.configure_server do |config|
  # disable job logging in production
  config[:skip_default_job_logging] = (config[:environment] == "production")

  # disable sidekiq's job logging everywhere
  config[:skip_default_job_logging] = true
end

@mperham
Copy link
Collaborator Author

mperham commented Feb 16, 2024

This does change the JobLogger constructor. Since that's a breaking change to an internal component, it'll need a minor version bump to 7.3.0.

@mperham mperham added this to the 7.3 milestone Apr 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant