NonStop Servlets for JavaServer Pages (NSJSP) 6.1 System Administrator's Guide

Logging in NSJSP
NonStop Servlets for JavaServer Pages (NSJSP) 6.1 System Administrator’s Guide596210-006
5-20
Configuring the logging.properties File
Configuring the logging.properties File
This section describes the contents of the logging.properties file.
You can use the logging.properties file to configure log-related settings, such as,
which logs must be written, where the logs must be written, and when the logs must
rollover. The file contains java.util.logging elements, such as loggers and
handlers, and various attributes to which you can assign values to control the logs.
You can specify the location of the logging.properties file by configuring the Java
system property, java.util.logging.config.file. By default, the directory
location is <NSJSP 6.1 installation directory>/conf.
The logging.properties file contains handlers and loggers.
Handlers in the logging.properties File
The following lines indicate the handlers defined in the logging.properties file:
handlers = 1nsjsp.com.tandem.servlet.logging.NSJSPLogHandler,
2console.com.tandem.servlet.logging.NSJSPLogHandler,
1catalina.org.apache.juli.FileHandler,
2localhost.org.apache.juli.FileHandler,
3manager.org.apache.juli.FileHandler,
4admin.org.apache.juli.FileHandler, 5host-
manager.org.apache.juli.FileHandler
In the given example, the handlers attribute is assigned seven values. Each of the
seven handlers has its own settings. However, among the seven handlers, only two
handler implementation classes are used. They are
com.tandem.servlet.logging.NSJSPLogHandler and
org.apache.juli.FileHandler. These handler implementation classes are
loaded during the NSJSP startup.
The following line sets the handlers property for the root logger. The root logger is an
empty string. The complete attribute name is <root logger>.handlers. This is the
default handler. If no defined handler meets the requirements to enable logging, the
default handler is used.
.handlers = 1nsjsp.com.tandem.servlet.logging.NSJSPLogHandler
The following lines denote the configuration settings of the handler, called
1nsjsp.com.tandem.servlet.logging.NSJSPLogHandler:
1nsjsp.com.tandem.servlet.logging.NSJSPLogHandler.destination =
${catalina.base}/logs/nsjsp
1nsjsp.com.tandem.servlet.logging.NSJSPLogHandler.level = INFO
1nsjsp.com.tandem.servlet.logging.NSJSPLogHandler.datePattern =
'.'yyyy-MM-dd
1nsjsp.com.tandem.servlet.logging.NSJSPLogHandler.archiveDirecto
ry = ${catalina.base}/logs/archive