Skip to content
DevTest Solutions - 10.4
Documentation powered by DocOps

Logging Properties File

Last update November 6, 2017

DevTest uses the Apache log4j logging framework. The logging.properties file, located either in the user-specified data directory (DevTest Workstation only) or in the LISA_HOME directory, lets you configure the logging behavior. This file is your main source for manipulating what is being logged across the multiple components of DevTest.

DevTest Workstation and logging.properties

The DevTest application uses logging.properties file to initialize the logging. When the Workstation starts up in 10.1 or lower, it looks for the logging.properties file in the installation directory also known as LISA_HOME. In 10.2, if you specify a different data directory than LISA_HOME during installation, then the Workstation looks for logging.properties in the user-specified data directory. If it doesn’t find a logging.properties file in the data directory that was specified, then the application falls back to LISA_HOME. This change doesn’t affect the server components like Registry, VSE, Portal, Simulator, and Coordinator.


To get more logging information from DevTest, you can change the logging level in log4j.rootCategory:

log4j.rootCategory=INFO,A1

The logging.properties file contains a set of loggers for third-party components that are included in DevTest. The default log levels for these loggers are intended to prevent the third-party components from flooding the log files with too many messages. You typically do not need to change the log levels.

log4j.logger.com.teamdev=WARN

log4j.logger.EventLogger=WARN

...

The default appender is com.itko.util.log4j.TimedRollingFileAppender. Log statements for a component are appended to a file that is backed up when it reaches a certain size. The default maximum file size is 10 MB. The default number of backup files is 5.

log4j.appender.A1=com.itko.util.log4j.TimedRollingFileAppender

log4j.appender.A1.File=${lisa.tmpdir}/${LISA_LOG}

log4j.appender.A1.MaxFileSize=10MB

log4j.appender.A1.MaxBackupIndex=5

log4j.appender.A1.layout=org.apache.log4j.EnhancedPatternLayout

log4j.appender.A1.layout.ConversionPattern=%d{ISO8601}{UTC}Z (%d{HH:mm}) [%t] %-5p %-30c - %m%n

To perform log rotation by date or time, use the DailyRollingFileAppender. For more information, see the log4j documentation.

log4j.appender.A1=org.apache.log4j.DailyRollingFileAppender

log4j.appender.A1.File=${lisa.tmpdir}/${LISA_LOG}

log4j.appender.A1.Append=true

log4j.appender.A1.DatePattern='.'yyyy-MM-dd

The backup files are placed in the same directory as the log file. For example, if the log file for the registry has been backed up three times, the directory contains the following files:

  • registry.log
  • registry.log.1
  • registry.log.2
  • registry.log.3

Layouts control the format of log statements. The default layout is org.apache.log4j.EnhancedPatternLayout. The default conversion pattern is %d{ISO8601}{UTC}Z (%d{HH:mm}) [%t] %-5p %-30c - %m%n. This conversion pattern specifies that a log statement includes the date, thread, priority, category, and message. For example:

2014-11-20 14:09:08,152Z (07:09) [main] INFO  com.itko.lisa.net.ActiveMQFactory - Starting amq broker

The date uses Coordinated Universal Time (UTC). This convention makes it easier to follow log events when the registry is running in a different time zone than DevTest Workstation.

For information about the thread dump properties, see Automatic Thread Dumps.

Was this helpful?

Please log in to post comments.