cancel
Showing results for 
Search instead for 
Did you mean: 

Has Logging (logger.log()) settings changed

darkredd
Star Contributor
Star Contributor

Good day,

Has Logging (logger.log()) settings changed, I have set up the logging settings on both the Repo and Share log4j files but still there are no entries in the logs when I invoke the logger.

log4j.logger.org.alfresco.repo.jscript.ScriptLogger=debug -- for Repo

log4j.logger.org.springframework.extensions.webscripts.ScriptLogger=debug -- for Repo

log4j.logger.org.springframework.extensions.webscripts.ScriptLogger=debug -- for share

Are there new settings or is this a bug?

I am running the 201609 EA (5.2.0 (r130497-b277)) build.

1 ACCEPTED ANSWER

afaust
Legendary Innovator
Legendary Innovator

Your configurations are actually sligthly incorrect. The Surf WebScripts ScriptLogger class is actually using the same logger as the Repository-tier implementation, so in both Log4J configurations you only need

log4j.logger.org.alfresco.repo.jscript.ScriptLogger=debug

View answer in original post

4 REPLIES 4

kaynezhang
World-Class Innovator
World-Class Innovator

No ,It has not change ,where did you place your log4j file and how did you name it?

afaust
Legendary Innovator
Legendary Innovator

Your configurations are actually sligthly incorrect. The Surf WebScripts ScriptLogger class is actually using the same logger as the Repository-tier implementation, so in both Log4J configurations you only need

log4j.logger.org.alfresco.repo.jscript.ScriptLogger=debug

darkredd
Star Contributor
Star Contributor

Hi Axel,

My configuration were indeed off. However, should Alfresco have not just ignored them and accept the correct one? Just a side thought.

afaust
Legendary Innovator
Legendary Innovator

That has little to do with Alfresco and all with Log4J. It likely has ignored the incorrect configuration which really only affected Share. Since you haven't mentioned where you are using logger.log() I would assume it was on Share tier.