Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8033469
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T01:42:27+00:00 2026-06-05T01:42:27+00:00

It appears that we have access to Rails.logger and logger inside Rails applications. I

  • 0

It appears that we have access to Rails.logger and logger inside Rails applications. I understand that the two logger are different, but wouldnt it be ideal to create on TaggedBufferedLogger and have a single instance for logger. Why are there two instances and what is the proper time to use which?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T01:42:29+00:00Added an answer on June 5, 2026 at 1:42 am

    BufferedLogger is the default Rails logger. Its purpose is to make logging thread-safe.
    Optionally, you can wrap this logger into a TaggedBufferedLogger and use it, if you want to ‘tag’ your logging output.

    Straight from the weblog.rails

    Tagged logger
    
    When you’re running a multi-user, multi-account application, it’s a great help to be able to filter the log by who did what. Enter the TaggedLogging wrapper. It works like this:  
    
    Logger = ActiveSupport::TaggedLogging.new(Logger.new(STDOUT))
    Logger.tagged("BCX") { Logger.info "Stuff" } # Logs "[BCX] Stuff"
    Logger.tagged("BCX") do
      Logger.tagged("Jason") do
        Logger.info "Stuff" # Logs "\[BCX\] \[Jason\] Stuff"
      end
    end
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying out Intel MKL and it appears that they have their own
It appears that we will have to build/deploy one of our new JBoss apps
I have been investigating transactions and it appears that they take care of themselves
I have an object that I am serializing to xml. It appears that a
Looking at the DateTimeFormatInfo documentation, it appears that all the standard formats have colons
I have a jQuery dialog that appears and loads an external page. In that
I have an activity that appears as a dialog using the following custom theme:
I have a problem that appears and disappears for mysterious reasons. A while back
In Lion, source list group items now have a Hide/Show button that appears when
We have this bug that only appears 30% of the time for the Release

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.