I was going to name this Documentum vs Logging configuration, but this seems to be a recurrent error on Opentext where their engineers fail to understand how logging works (exactly this same issue can be seen in Appworks, for example).
If you check the catalina.out file from latest DCTM 22.4 you’ll see a recurrent trace, which is extremely annoying and it will fill up the log as it writes constantly the same lines:
20:13:28.071 [ActiveMQ Journal Checkpoint Worker] DEBUG org.apache.activemq.store.kahadb.MessageDatabase - Checkpoint started.
20:13:28.071 [ActiveMQ Journal Checkpoint Worker] DEBUG org.apache.activemq.store.kahadb.MessageDatabase - Checkpoint done.
20:13:31.639 [ActiveMQ InactivityMonitor WriteCheckTimer] DEBUG org.apache.activemq.transport.AbstractInactivityMonitor - WriteChecker: 10000ms elapsed since last write check.
20:13:31.639 [ActiveMQ InactivityMonitor Worker] DEBUG org.apache.activemq.transport.AbstractInactivityMonitor - Running WriteCheck[tcp://127.0.0.1:9084]
This comes from ACS using ActiveMQ, which is deployed under tomcat/shared/dc_lib. You can try modifying log4j.properties under ACS application or logging.properties in Tomcat, nothing will work. Why? Because in the dc_lib folder OT also added the logback libraries, without any configuration whatsoever. So by doing this, besides having a nice mix of every single logging library known to men and women, we’ll get a ton of crap on catalina.out.
So how do we solve this?
Brute force approach: Remove the logback jars 😀
Common sense developer approach: Add the following parameter to JMS startup: -Dlogback.configurationFile=file:/opt/documentum/tomcat9.0.65/bin/logback.xml
And the file should have the following contents:
<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true" debug="true">
<appender name="stdout" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>[%t] [%4p] [%d{ISO8601}] %c{1}: %m%n</pattern>
</encoder>
</appender>
<appender name="R" class="ch.qos.logback.core.rolling.RollingFileAppender">
<File>/opt/documentum/tomcat9.0.65/logs/activemq.log</File>
<encoder>
<pattern>[%t] [%4p] [%d{ISO8601}] %c{1}: %m%n</pattern>
</encoder>
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<fileNamePattern>/opt/documentum/tomcat9.0.65/logs/activemq.log.%d{yyyy-MM-dd-HH}</fileNamePattern>
</rollingPolicy>
</appender>
<logger name="org.apache.activemq.spring" additivity="false">
<level value="WARN"/>
<appender-ref ref="R" />
<appender-ref ref="stdout" />
</logger>
<logger name="org.apache.activemq.web.handler" additivity="false">
<level value="WARN"/>
<appender-ref ref="R" />
<appender-ref ref="stdout" />
</logger>
<logger name="org.apache.activemq.xbean" additivity="false">
<level value="WARN"/>
<appender-ref ref="R" />
<appender-ref ref="stdout" />
</logger>
<logger name="org.apache.activemq" additivity="false">
<level value="INFO"/>
<appender-ref ref="R" />
<appender-ref ref="stdout" />
</logger>
<root level="INFO">
<appender-ref ref="stdout"/>
<appender-ref ref="R"/>
</root>
</configuration>
Now you’ve removed useless logging from catalina.out, configured it properly, and placed it on its own file. Not so difficult, right?