<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Logger configuration in Alfresco Forum</title>
    <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85956#M26038</link>
    <description>&lt;P&gt;Just a more or less generic question: Do we really want to discuss such basic programming questions here in the Alfresco forum? We're all busy people and I would &lt;SPAN class="tlid-translation translation"&gt;&lt;SPAN class=""&gt;appreciate it to focus on questions with stronger Alfresco focus and apply some rules similar to stack overflow ...&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 21 Feb 2020 11:18:47 GMT</pubDate>
    <dc:creator>heiko_robert</dc:creator>
    <dc:date>2020-02-21T11:18:47Z</dc:date>
    <item>
      <title>Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85948#M26030</link>
      <description>&lt;P&gt;Hi there ,&lt;/P&gt;&lt;P&gt;Is there&amp;nbsp; a specific onfiguration for logger to print &lt;FONT face="courier new,courier"&gt;log.info()&lt;/FONT&gt; message&amp;nbsp; ?&amp;nbsp;&amp;nbsp; I have action classes extended quatz class as shown below .&amp;nbsp; but the log is not printing out in log file - alfresco.log . I can see system.out.println in tomcat log .&lt;/P&gt;&lt;P&gt;please let me know if there are any configuration changes reuired in log4j.properties&amp;nbsp; ? I have kept all the config default didnt make any changes in log4j&lt;/P&gt;&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="image.png" style="width: 879px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://connect.hyland.com/t5/image/serverpage/image-id/443iDD4829D82636D550/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 19 Feb 2020 12:59:39 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85948#M26030</guid>
      <dc:creator>brijeshnk</dc:creator>
      <dc:date>2020-02-19T12:59:39Z</dc:date>
    </item>
    <item>
      <title>Re: Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85949#M26031</link>
      <description>&lt;P&gt;Is there a reason why you had to extend Object class ?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Have you enabled logging for your package or class in log4j.properties? If not,&amp;nbsp;Try adding log setting in following format:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;log4j.logger.com.github.mycms.action=INFO&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;where "com.github.mycms.action" is the package where you class resides.&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;OR&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;log4j.logger.com.github.mycms.action.MoveMonthlyDataAction=INFO&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;where "com.github.mycms.action.MoveMonthlyDataAction" is the fqn of the class.&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;U&gt;You can add the settings either in :&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;$TOMCAT_HOME/shared/classes/alfresco/extension/custom-log4j.properties&lt;/STRONG&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;OR&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;U&gt;You can add the settings either in your custom module which you are applying to alfresco.war:&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&amp;lt;yourCustomModule&amp;gt;/src/main/resources/alfresco/module/&amp;lt;custom-module&amp;gt;/log4j.properties&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;OR&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;U&gt;Use admin console to add the log settings, if you are using enterprise version (Note, when you restart server these settings won't persist):&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;&lt;A href="https://cert.cms.hmhco.com/alfresco/s/enterprise/admin/admin-log-settings" target="_blank" rel="noopener nofollow noreferrer"&gt;http://&amp;lt;HOST : PORT&amp;gt;/alfresco/s/enterprise/admin/admin-log-settings&lt;/A&gt;&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 19 Feb 2020 15:12:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85949#M26031</guid>
      <dc:creator>abhinavmishra14</dc:creator>
      <dc:date>2020-02-19T15:12:47Z</dc:date>
    </item>
    <item>
      <title>Re: Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85950#M26032</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/16965"&gt;@brijeshnk&lt;/A&gt;,&lt;/P&gt;
&lt;P&gt;Just a note about the name of your class - there is no such word as "monthily" in the English language. I think you mean "monthly"? So it might be worth renaming your class to MoveMonthlyDataAction, and the methods accordingly - MoveMonthlyDataThreadRunner, setMoveMonthlyDataThreadRunner, etc. This may make usage and maintenance of your code easier in the long run.&lt;/P&gt;
&lt;P&gt;HTH,&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 19 Feb 2020 16:17:03 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85950#M26032</guid>
      <dc:creator>EddieMay</dc:creator>
      <dc:date>2020-02-19T16:17:03Z</dc:date>
    </item>
    <item>
      <title>Re: Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85951#M26033</link>
      <description>&lt;P&gt;thanks for alerting this &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 20 Feb 2020 10:03:39 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85951#M26033</guid>
      <dc:creator>brijeshnk</dc:creator>
      <dc:date>2020-02-20T10:03:39Z</dc:date>
    </item>
    <item>
      <title>Re: Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85952#M26034</link>
      <description>&lt;P&gt;Hi thanks a lot for the response. I have configured this as mentioned below&lt;/P&gt;&lt;P&gt;I&amp;nbsp; have added following configuration in&amp;nbsp; &lt;EM&gt;&lt;STRONG&gt;$TOMCAT_HOME/shared/classes/alfresco/extension/custom-log4j.properties&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;PRE&gt;log4j.logger.com.uia.archive.movedata.MoveMonthilyDataAction=INFO
log4j.logger.com.uia.archive.movedata.MoveMonthilyDataThreadRunner=INFO
log4j.logger.com.uia.archive.movedata.MoveMonthilyData=INFO&lt;/PRE&gt;&lt;P&gt;Result was :-&lt;/P&gt;&lt;P&gt;logs are printing out , but the in different&amp;nbsp; logs. ( alfresco.lg and alfrescotomcat-stdout.2020-02-20.log)&lt;/P&gt;&lt;P&gt;logs from 'com.uia.archive.movedata.MoveMonthilyDataAction'&amp;nbsp; class is printed in 'alfreso.log'.&lt;/P&gt;&lt;P&gt;Other class logs are printed in 'alfrescotomcat-stdout.2020-02-20.log'&amp;nbsp; . Though all classes are same package and location .&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there any specific reason for this or this behaviour is expected&amp;nbsp; ?&lt;/P&gt;&lt;P&gt;thanks a lot&lt;/P&gt;</description>
      <pubDate>Thu, 20 Feb 2020 12:36:52 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85952#M26034</guid>
      <dc:creator>brijeshnk</dc:creator>
      <dc:date>2020-02-20T12:36:52Z</dc:date>
    </item>
    <item>
      <title>Re: Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85953#M26035</link>
      <description>&lt;P&gt;One thing I have noticed in your job class is that you are using JUL instead of Log4J, Commons Logging, or - way more ideal - SLF4J. While Commons Logging and SLF4J are both set up to log via Log4J in the backend, I do not think that JUL is set up in the same way. I can only recommend to ALWAYS use SLF4J logging APIs to ensure that a) you are logging to the same file(s) that Alfresco logs to and b) you are not dependent on any specific log backend implementation, and could switch to whatever (e.g. I switched to Logback instead of Log4J in one project).&lt;/P&gt;
&lt;P&gt;Also, everything you output via System.out will land in the catalina.out, unless you configure Tomcat to ignore System.out. Generally speaking though, System.out should be forbidden under threat of severe penalties...&lt;/P&gt;</description>
      <pubDate>Thu, 20 Feb 2020 13:53:33 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85953#M26035</guid>
      <dc:creator>afaust</dc:creator>
      <dc:date>2020-02-20T13:53:33Z</dc:date>
    </item>
    <item>
      <title>Re: Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85954#M26036</link>
      <description>&lt;P&gt;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/16045"&gt;@afaust&lt;/A&gt;&amp;nbsp; , Awesome !&lt;/P&gt;&lt;P&gt;that was perfect .&amp;nbsp; &amp;nbsp; I was using multiple logging package. I replaced all with log4j packages in all classes ,&amp;nbsp; All logs is are now visible in alfresco.log.&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks a lot for this answer&lt;/P&gt;&lt;P&gt;Brijesh&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 20 Feb 2020 14:27:07 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85954#M26036</guid>
      <dc:creator>brijeshnk</dc:creator>
      <dc:date>2020-02-20T14:27:07Z</dc:date>
    </item>
    <item>
      <title>Re: Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85955#M26037</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/16965"&gt;@brijeshnk&lt;/A&gt;,&lt;/P&gt;
&lt;P&gt;Thanks for reporting back on how&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/16045"&gt;@afaust&lt;/A&gt;&amp;nbsp;helped you out - this feedback is really useful for other users encountering similar problems.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 20 Feb 2020 14:51:04 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85955#M26037</guid>
      <dc:creator>EddieMay</dc:creator>
      <dc:date>2020-02-20T14:51:04Z</dc:date>
    </item>
    <item>
      <title>Re: Logger configuration</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85956#M26038</link>
      <description>&lt;P&gt;Just a more or less generic question: Do we really want to discuss such basic programming questions here in the Alfresco forum? We're all busy people and I would &lt;SPAN class="tlid-translation translation"&gt;&lt;SPAN class=""&gt;appreciate it to focus on questions with stronger Alfresco focus and apply some rules similar to stack overflow ...&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 21 Feb 2020 11:18:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/logger-configuration/m-p/85956#M26038</guid>
      <dc:creator>heiko_robert</dc:creator>
      <dc:date>2020-02-21T11:18:47Z</dc:date>
    </item>
  </channel>
</rss>

