Log4j configuration is correct, but logs cannot be printed on the console

Source: Internet
Author: User

I recently worked on a project and encountered a problem. I am dizzy! Log4j configuration is correct, but logs cannot be printed on the console! It was initially considered a configuration problem because the project was managed using Maven, and the package issue was not taken into account! I haven't found the reason for this for a long time! It's always the next step in debug mode to find the wrong location! It is a pain. The key is to deploy it on a test machine. You cannot do this! A bug has been found for you, and you do not know where to locate it! Oh, my God! Yes, but do you want to tell me where the error is ?! After a lot of unremitting efforts!

Slf4j-log4j12.jar package missing! Search online! It turns out to be really rare! I don't know how the architect can get rid of it? Let us call this development a pain! Share it!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.