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 7072119
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T05:46:12+00:00 2026-05-28T05:46:12+00:00

According to be Spring Framework documentation, logging is the only mandatory dependency of Spring.

  • 0

According to be Spring Framework documentation, logging is the only mandatory dependency of Spring. It uses Apache Commons Logging by default, or can be configured to use SLF4J or Log4J instead. My question is for the application I am writing using Spring, instead of using a differnt logger class and instantiating a new logger object in my application, is it possible to get a reference to the logger Spring is using for itself?

  • 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-05-28T05:46:12+00:00Added an answer on May 28, 2026 at 5:46 am

    Sure – loggers are only referenced by name. So if Spring uses “org.springframework.beans.abc” (for example) as a logger name, you can also ask for a logger of the same name. (Spring doesn’t log using just one logger / name – it uses several, depending upon what you’re using in Spring – as it should.)

    However, I would strongly recommend against doing this. The cost of instantiating a new logger object should be minimal – and any savings in doing this would be more than offset by the additional confusion of doing so. Spring logs to Spring logger names. Your code should log to a logger name unique to your code. Otherwise, if something is logged, how do you know if it is coming from Spring code or your code? This would completely defeat the purpose of logger / category names.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

According to this article , you can use the AbstractRoutingDataSource from Spring Framework to
According to what I have found so far, I can use the following code:
According to Spring framework API UrlFilenameViewController's purpose is: Transforms the virtual path of a
I am trying to create a form using the Spring Framework, but according to
I am facing an issue while trying to use the spring android framework. I
According to the Spring Documentation here : While HTTP defines these four methods, HTML
According to the documentation, they're pretty much interchangeable. Is there a stylistic reason to
I am trying to send mail through grails mail plugin. I configured according to
The Spring Framework API doc says: The convention used is to return the uncapitalized
According to the NHibernate Validator documentation here: http://nhforge.org/wikis/validator/nhibernate-validator-1-0-0-documentation.aspx I should be able to pass

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.