Logging properties files

Endeca Server and Data Enrichment have default Log4j configuration files that set their logging properties.

Both files are located in the $DOMAIN_HOME/config directory.

Endeca Server logging properties

The Endeca Server properties file is named EndecaServerLog4j.properties. The default version of the file is as follows:
log4j.rootLogger=WARN, stdout, ODL

# Console Appender
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%d [%p] [%c] %L - %m%n

# ODL-format Log Appender
log4j.appender.ODL=com.endeca.logging.ODLAppender
log4j.appender.ODL.MaxSize=104857600
log4j.appender.ODL.MaxSegmentSize=10485760
log4j.appender.ODL.encoding=UTF-8

# Log level per packages
log4j.logger.com.endeca=INFO
log4j.logger.org.apache.zookeeper=WARN

The file defines two appenders (stdout and ODL) for the root logger and also sets log levels for two packages.

The file has the following properties:
Logging property Description
log4j.rootLogger=WARN, stdout, ODL The level of the root logger is defined as WARN and attaches the Console Appender (stdout) and ODL-format Log Appender (ODL) to it.
log4j.appender.stdout=org.apache.log4j.ConsoleAppender Defines stdout as a Log4j ConsoleAppender
log4j.appender.stdout.layout.ConversionPattern Sets the PatternLayout class for the stdout layout.
log4j.appender.stdout.layout.ConversionPattern Defines the log entry conversion pattern as:
  • %d is the date of the logging event.
  • %p outputs the priority of the logging event.
  • %c outputs the category of the logging event.
  • %L outputs the line number from where the logging request was issued.
  • %m outputs the application-supplied message associated with the logging event while %n is the platform-dependent line separator character.

For other conversion characters, see: https://logging.apache.org/log4j/1.2/apidocs/org/apache/log4j/PatternLayout.html

log4j.appender.ODL=com.endeca.util.ODLAppender Defines ODL as an ODL Appender. ODL (Oracle Diagnostics Logging) is the logging format for Oracle applications.
log4j.appender.ODL.MaxSize Sets the maximum amount of disk space to be used by the AdminServer-diagnositic.log file and the logging rollover files. The default is 1048576000 (about 1GB). Older log files are deleted to keep the total log size under the given limit.
log4j.appender.ODL.MaxSegmentSize Sets the maximum size (in bytes) of the log file. When the log file reaches this size, a rollover file is created. The default is 104857600 (about 10 MB).
log4j.appender.ODL.encoding Sets character encoding the log file. The default UTF-8 value prints out UTF-8 characters in the file.
log4j.logger.com.endeca Sets the default log level for the Endeca Server log messages. INFO is the default log level.
log4j.logger.org.apache.zookeeper Sets the default log level for the Cluster Coordinator (ZooKeeper) client logger. WARN is the default log level.

Data Enrichment logging properties

The Data Enrichment properties file is named DataEnrichmentLog4j.properties. It does not use ODL, but is otherwise very similar to the Endeca Server Log4j configuration file.

The file sets INFO as the default log level for the log4j.logger.oracle.endeca.enrichment package.

Logging levels

The WebLogic logger for Endeca Server is configured with the type of information written to log files, by specifying the log level. When you specify the type, WebLogic returns all messages of that type, as well as the messages that have a higher severity. For example, if you set the message type to WARN, WebLogic also returns messages of type FATAL and ERROR.

The log levels (in decreasing order of severity) are:
Java Log Level ODL Log Level Meaning
OFF N/A Has the highest possible rank and is used to turn off logging.
FATAL INCIDENT_ERROR Indicates a serious problem that may be caused by a bug in the product and that should be reported to Oracle Support. In general, these messages describe events that are of considerable importance and which will prevent normal program execution.
ERROR ERROR Indicates a serious problem that requires immediate attention from the administrator and is not caused by a bug in the product.
WARN WARNING Indicates a potential problem that should be reviewed by the administrator.
INFO NOTIFICATION A message level for informational messages. This level typically indicates a major lifecycle event such as the activation or deactivation of a primary sub-component or feature. This is the default level.
DEBUG TRACE Debug information for events that are meaningful to administrators, such as public API entry or exit points.

These levels allow you to monitor events of interest at the appropriate granularity without being overwhelmed by messages that are not relevant. When you are initially setting up your application in a development environment, you might want to use the INFO level to get most of the messages, and change to a less verbose level in production.