These properties configure the output from a logging profile that uses the built-in EAS logging subsystem. The properties can be logically grouped as category properties, handler properties, and formatter properties.
Categories A category is a logical name used to categorize log messages. Internally in EAServer, different category names are used by different subsystems such as the servlet engine, as listed in “Category names”.
Categories can be arranged hierarchically by setting the parent property for handlers that should inherit settings from another handler. There is also a root category that configures the root-level settings. If you configure a category to inherit properties, but do not specify a parent, the root category settings are inherited.
Table B-8 lists
the properties that configure a category. In the log profile, you define
a category by configuring properties that begin with category.<cat-name>,
where cat-name is replaced by the category
name. For example, category.com.sybase.level configures
the log level for the com.sybase
category.
Property name |
Specifies |
---|---|
The log level for the root category. |
|
The handler for the root category. |
|
Specifies an optional description of the category. |
|
The log level for the category named <cat-name>. |
|
The handler for the category named <cat-name>. |
|
The parent handler. |
|
Whether to inherit settings from the parent handler. |
|
The resource bundle name for the category <cat-name>. Specify the name of a Java resource bundle name containing localized messages that are logged from Java code. If this property is not set, the default resource bundle is the class ResourceBundle in the package with the same name as the category. For example, the default resource bundle for the category com.sybase.jaguar.server is com.sybase.jaguar.server.ResourceBundle. |
Handlers Handlers define how messages are logged. For example, you set properties to specify whether the output goes to the console or to a file, the log file name, whether to truncate log files on start-up, and so forth. To define a handler, specify a logical name when setting the handler properties in Table B-9 with <handler-name> replaced in the property name by the handler name.
Property name |
Specifies |
---|---|
An optional description |
|
The log output type |
|
For console output, whether to use standard output or standard error |
|
For file output, the log file name |
|
For file output, whether to truncate the log file at start-up |
|
For file output, the maximum size |
|
For file output, whether to rotate log files at start-up and when the maximum size is reached |
|
The formatter name to use |
|
Whether to archive files at start-up and when the maximum size is reached |
|
The location and naming pattern for archived log files |
|
When archiving, whether to compress the log file |
|
When writing to a TCP socket, the host name for the socket connection |
|
When writing to a TCP socket, the port number for the socket connection |
Formatters Formatters specify the formatting pattern for logged messages. To define a formatter, specify a logical name when setting the handler properties in Table B-10, with <formatter-name> replaced in the property name by the formatter name.
Property name |
Specifies |
---|---|
An optional description |
|
The format for timestamps in log messages |
|
The format pattern for the message text |
Log profile properties, com.sybase.jaguar.logprofile.subsystem
Specifies an optional description of the category named <cat-name>.
The text of the description.
Specifies the handler for the category named <cat-name>.
The handler name. “Handlers” describes how to define a handler.
Specifies the log level for the category named <cat-name>.
One of the error levels listed in Table B-11. The error level specifies which messages are logged. Only messages of the specified security level or greater are logged. Table B-11 lists the levels in ascending order of severity.
Level |
To indicate |
---|---|
ALL |
All messages are logged. |
FINE |
Debug messages are logged. |
FINER |
Same effect as FINE. |
FINEST |
Same effect as FINE. |
CONFIG |
A configuration error has been detected. You should correct the problem. |
INFO |
An informational or status message. For example, the name server has finished binding components. |
WARN |
Warning messages are logged. For example, if the server is in a cluster and other members are not found. |
ERROR |
An error has occurred that prevents completion of a requested action. For example, a component has thrown an uncaught exception and its transaction is being rolled back. |
FATAL |
An error has occurred that indicates the server should terminate. |
OFF |
No messages are logged. |
“Categories”, category.<root>.level
Specifies the parent of the category named <cat-name>.
The name of the parent category. If not specified, the default is the root category.
“Categories”, category.<cat-name>.useparenthandlers
Specifies the name of the Java resource bundle containing localized messages.
The full Java class name of the resource bundle, which must extend java.util.ResourceBundle. Do not include language or country code extensions.
For the category named <cat-name>, specifies whether to inherit settings from the parent handler. The parent is specified by the category.<cat-name>.parent property. If this property is not set, the parent is the root category.
true
or false
.
“Categories”, category.<cat-name>.parent
Specifies the log level for the root category.
Same as category.<cat-name>.level.
category.<root>.handler, category.<cat-name>.level, “Categories”
Specifies the handler for the root message category.
The handler name. “Handlers” describes how to define a handler.
category.<root>.level, category.<cat-name>.handler, “Categories”
Specifies the timestamp format for the formatter named <formatter-name>.
The pattern for the timestamps embedded in log messages, as converted to strings by java.text.SimpleDateFormat. For details, see the the DateFormat API documentation.
“Formatters”, formatter.<formatter-name>.messageformat
Specifies an optional description for the formatter named <formatter-name>.
The text of the description.
Specifies the message format for the formatter named <formatter-name>.
The pattern for the message text. You can use the placeholders in Table B-12 to indicate the position of the message parts.
Placeholder |
Represents |
---|---|
|
The logging category name |
|
Message code (number) |
|
Message level (severity) |
|
Message text |
|
Sequence number |
|
Source file name |
|
Line number in the source file |
|
Method name in the source file |
|
Thread ID |
|
Exception thrown (if available) |
|
The timestamp, formatted as specified by the formatter.<formatter-name>.dateformat property |
|
A line break |
“Formatters”, formatter.<formatter-name>.dateformat
For the handler named <handler-name>, when writing to a file, specifies whether the previous log file should be archived when restarting servers or when the maximum size is reached.
true
or false
.
The default is false
. If you
enable archiving, specify the archive file name by setting handler.<handler-name>.archive.filename.
“Handlers”, handler.<handler-name>.type, handler.<handler-name>.maxsize, handler.<handler-name>.archive.filename, handler.<handler-name>.archive.compress
For the handler named <handler-name>, when file archiving is enabled, specifies whether to compress archived files.
true
or false
.
The default is false
. If you
enable compression, the resulting archive name is the value of handler.<handler-name>.archive.filename plus
the “.zip” extension.
“Handlers”, handler.<handler-name>.archive handler.<handler-name>.archive.filename
For the handler named <handler-name>, when file archiving is enabled, specifies the archive file name.
The full path to the archive file, using ‘/’ (forward slash) as the directory separator. You can use the placeholders described in Table B-13.
“Handlers”, handler.<handler-name>.archive, handler.<handler-name>.archive.compress
For the handler named <handler-name>, when writing to the console, specifies whether to write to standard error or standard output.
One of the following:
Value |
To indicate |
---|---|
stderr |
Standard error |
stdout |
Standard output |
“Handlers”, handler.<handler-name>.type
Specifies the output type for the handler named <handler-name>.
The descriptive text.
For the handler named <handler-name>, when writing to a file, specifies the file name.
The full path to the output file, using ‘/’ (forward slash) as the directory separator. You can use the placeholders described in Table B-13:
Placeholder |
Specifies |
---|---|
|
The EAServer installation directory (specified by the JAGUAR environment variable) |
|
The location of binaries in the EAServer installation ($JAGUAR/bin on most platforms) |
|
The server name, as displayed in EAServer Manager |
|
The time of day when the file was created, formatted as HHMMSS |
|
The date (month, day of month, and year) when the file was created, formatted as DDMMYYYY |
“Handlers”, handler.<handler-name>.type
For the handler named <handler-name>, specifies the formatter name.
The formatter name. See “Formatters”.
For the handler named <handler-name>, when writing to a file, specifies the maximum size the file can reach before rotation or archiving occurs.
To specify the size in kilobytes:
nk
To specify the size in megabytes:
nm
Where n is a positive integer. To specify
an unlimited size, use -1
(the
default).
If you specify a maximum size, you should enable rotation or archiving by setting the handler.<handler-name>.rotate or handler.<handler-name>.archive properties, respectively.
“Handlers”, handler.<handler-name>.type, handler.<handler-name>.archive, handler.<handler-name>.rotate
For the handler named <handler-name>, when writing to a file, specifies whether the previous log file should be renamed when restarting servers or when the maximum size is reached.
true
or false
.
The default is false
. If you
enable rotation, the log file is renamed with a sequential numeric
extension when a new file is started. For example, if the file is Jaguar.log,
previous versions are named Jaguar.log.1, Jaguar.log.2,
and so forth.
“Handlers”, handler.<handler-name>.type, handler.<handler-name>.archive.filename, handler.<handler-name>.maxsize
For the handler named <handler-name>, when writing to a TCP socket, specifies the host name for the socket connection.
The server host name or IP address.
“Handlers”, , handler.<handler-name>.serverport handler.<handler-name>.type
For the handler named <handler-name>, when writing to a TCP socket, specifies the port number for the socket connection.
The server port number.
“Handlers”, , handler.<handler-name>.serverhost handler.<handler-name>.type
For the handler named <handler-name>, when writing to a file, specifies whether the previous log file should be truncated when restarting servers.
true
or false
.
The default is false
.
“Handlers”, handler.<handler-name>.type
Specifies an optional description for the handler named <handler-name>.
One of the following:
Value |
To indicate |
---|---|
|
Output to a text file |
|
Output to the console (standard error or standard out) |
|
Output to a TCP socket |
Copyright © 2005. Sybase Inc. All rights reserved. |