Liferay 6.0.12 registration

I reviewed some issues with registering Liferay 6.0.12 classes on JBoss 5.1.

I need to change the log level for Liferay rss portlet classes, for example. create another application or use the default (server.log) and have the logs there with the desired level of debugging ( DEBUG or WARN ).

As far as I understand, jboss-log4j.xml can override the configuration of Liferay, so I tried to modify it. I also tried to do this from log4j.properties in ROOT.war/WEB-INF/classes , tried to create portal-log4j-ext.xml , but none of them worked for me. The only thing I could do was create another appender, but it was either empty or copied server.log.

Does anyone know exactly how it works?

PS Managing log levels through the administrator portlet is not allowed.

+4
source share
1 answer

Fortunately, I solved this problem.

  • First of all, add log4j.jar to ROOT.war/WEB-INF/lib , somehow not there.
  • The second check is if log4j.xml in the classpath (only search for any of ROOT.war )
  • If you can create log4.xml in ROOT.war/WEB-INF/classes with the right levels for applications and logs.
  • If not, you can use either log4j.xml or log4j.properties (for the desired appender) and portal-log4j-ext.xml (to override the default log levels) due to the Liferay documentation.
+1
source

All Articles