Pattern Layout |
specifies the name of the log for the specified appender that the formatted log events are directed to.
See Also: | For the appender class names, see Appender Reference. |
specifies the header text that the appender uses when it starts a new log.
specifies the pattern layout that is used to identify, order, and format information in a header for a log event. A conversion pattern consists of optional literal text and optional format-control directives, which are called conversion specifiers. Each conversion specifier begins with a percent sign (%) and is followed by optional format modifiers and one or more instances of the S conversion character. The format modifiers control field width, padding, and left and right justification.
Here is the syntax for a header pattern:
[literal-text] %[format-modifier-1] system-conversion-character-1 [... [literal-text] %[format-modifier-n] system-conversion-character-n] /> |
Valid in: | XML configuration files for any appender class. |
Restriction: | The header pattern is limited to the S conversion character in a logging configuration file. |
Tips: |
The specification of format modifiers is
optional.
There is no explicit separator between literal text and the conversion specifier. The pattern parser recognizes the end of a conversion specifier when it detects the S conversion character. |
Example: | <param name="HeaderPattern" value="%S{os_name} %S{jobid} %S{host_name} %S{user_name}"/> |
See: | S Conversion Character |
specifies the pattern layout that is used to identify, order, and format information in the log event. A conversion pattern consists of literal text and format-control directives called conversion specifiers. Each conversion specifier begins with a percent sign (%) and is followed by optional format modifiers and a conversion character. The conversion character specifies the type of data (for example, category, priority, date, and thread name). The format modifiers control field width, padding, and left and right justification.
Here is the syntax for a conversion pattern:
[literal-text] %[format-modifier-1] conversion-character-1 [... [literal-text] %[format-modifier-n] conversion-character-n] /> |
Valid in: | XML configuration files for any appender class. |
Default: | "%d %-5p [%t] %X{Client.ID}:%u - %m" |
Restriction: |
Conversion specifiers are case sensitive.
Do not use these problematic characters, known as variants, in pattern layouts in EBCDIC encoding environments: ! # $ @ \ []^`{}|~ \n Note: \n represents the use of the New Line (or Enter) key. These characters are problematic because they might occupy different code positions in various encodings that are supported by SAS. For example, the EBCDIC code point location 5A (hexadecimal) represents the exclamation point (!) in U.S. English and the right bracket ( ] ) in Spanish. |
Tips: |
The specification of format modifiers is
optional.
There is no explicit separator between literal text and a conversion specifier. The pattern parser recognizes the end of a conversion specifier when it detects a conversion character. |
Example: | <param name="ConversionPattern" value="%d; %-5p; %t; %c; (%F:%L); %m"/> |
See: | Conversion Characters |
See Also: | For more information about variant characters, see the SAS National Language Support (NLS): Reference Guide. |
specifies the footer text that the appender uses when it starts a new log.
specifies the pattern layout that is used to identify, order, and format information in a footer for a log event. A conversion pattern consists of optional literal text and optional format-control directives, which are called conversion specifiers. Each conversion specifier begins with a percent sign (%) and is followed by optional format modifiers and one or more instances of the S conversion character. The format modifiers control field width, padding, and left and right justification.
Here is the syntax for a footer pattern:
[literal-text] %[format-modifier-1] system-conversion-character-1 [... [literal-text] %[format-modifier-n] system-conversion-character-n] /> |
Valid in: | XML configuration files for any appender class. |
Restriction: | The footer pattern is limited to the S conversion character in a logging configuration file. |
Tips: |
The specification of format modifiers is
optional.
There is no explicit separator between literal text and the conversion specifier. The pattern parser recognizes the end of a conversion specifier when it detects the S conversion character. |
Example: | <param name="FooterPattern" value="%S{host_name}"/> |
See: | S Conversion Character |
specifies whether certain characters that can be specified in the m, x, X, and S conversion specifiers are converted to their entity representations.
specifies that the following characters are converted when they are used in the m, x, X, and S conversion specifiers:
"<" is converted to "<" | |
"<" is converted to ">" | |
"" is converted to """ | |
"'" is converted to "'" | |
"&" is converted to "&" |
specifies that no character conversion to entity representations is performed.
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.