[MAGNOLIA-4359] Init log configured for deprecated class Created: 29/Mar/12  Updated: 02/Oct/17  Resolved: 30/Sep/17

Status: Closed
Project: Magnolia
Component/s: core
Affects Version/s: 4.5.1
Fix Version/s: 5.6

Type: Bug Priority: Minor
Reporter: Magnolia International Assignee: Mikaël Geljić
Resolution: Fixed Votes: 0
Labels: deprecation-free, next
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Sprint: Saigon 114, Saigon 115
Story Points: 2

 Description   

In the log4j.xml bundled in the core jar (which is used during initialization, before we load the one configured via properties), we still configure the following:

  <category name="info.magnolia.cms.servlets.MgnlServletContextListener">
    <priority value="DEBUG"/>
  </category>

As far as I can tell, that class doesn't log anything anymore; conversely, info.magnolia.init.MagnoliaServletContextListener does (albeit nothing in debug).

The reason I can across this is I was looking for the debug line printed by info.magnolia.init.DefaultMagnoliaInitPaths, so I have 3 suggestions:

  • Remove the log config for MgnlServletContextListener (it's useless), and
  • Replace it by info.magnolia.init in DEBUG level, or
  • Switch the log.debug("servername is {}, rootPath is {}, webapp is {}, contextPath is {}", new Object[]{serverName, rootPath, webappFolderName, contextPath}); line to INFO level.

Generated at Mon Feb 12 03:55:01 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.