Writing Audit Logs to the Console
When you start a Docker container for Integration Server, you can instruct the Integration Server to write some or all of the audit logs to the console (STDOUT). Writing audit log entries to the console provides streamlined logging which can be especially useful when Integration Server runs in a Docker container. When working with multiple containers, you can obtain the log entries generated by the containers from the console. This may be preferable to retrieving the log files from the file system inside each container.
Each audit log entry written to the console includes the following:
The logger name as the identifier. For example, WMERROR is the identifier for the error log and WMSESSION is the identifier for the session log.
The ‖ (double pipe) character serves as the field delimiter. You can change the field delimiter using the watt.server.audit.stdout.fieldDelimiter server configuration parameter.
The && symbol serves as the record delimiter. You can change the record delimiter using the watt.server.audit.stdout.recordDelimiter server configuration parameter.
Following is an example of a session log entry written to the console:
jvm 1 | &&WMSESSION||a8d3b287-42bc-4f01-9110-22100f7bd514||?||
a8d3b287-42bc-4f01-9110-22100f7bd514||9f1b2585-db1b-5b47-39f0-d2651aacf8c9||
host:5555||2018-06-26T16:55:19.916Z||2018-06-26T16:55:19.917Z||1||Default||
internal connection||0||0||8798bcf3e47849368c42677bd76bba91||?&&
To write some or all of the audit logs to the console when Integration Server runs in a Docker container, set the SAG_IS_AUDIT_STDOUT_LOGGERS environment variable when you start the Docker container with the docker run command.
Set the SAG_IS_AUDIT_STDOUT_LOGGERS to one of the following values:
A comma-separated list of the audit loggers that you want to write to STDOUT. For example: WMSESSION,WMERROR
The audit logger name is the first portion of the audit log file name. For a list of audit log files names, see webMethods Audit Logging Guide.
A comma-separated list of the logger names as they appear in the
Settings > Logging page in
Integration Server Administrator. For example: Session Logger,Error Logger
ALL to write all log entries for all file-based audit loggers to STDOUT.
NONE to indicate that none of the file-based audit loggers will write to STDOUT. This is the default value.
Note:
The value of SAG_IS_AUDIT_STDOUT_LOGGERS is not case-sensitive.
Integration Server considers writing audit log entries to STDOUT to be an auxiliary output which means the logger still writes to the specified audit log destination of file or database.