- base64 |
-
- Base64 encoded data. The format is ${base64:Base64_encoded_data} .
- For example:
- ${base64:SGVsbG8gV29ybGQhCg==} yields Hello World! .
- |
-
-
-|base64
-|Base64 encoded data. The format is `${base64:Base64_encoded_data}`.
-For example: `${base64:SGVsbG8gV29ybGQhCg==}` yields `Hello World!`.
-
-|bundle
-|Resource bundle. The format is `${bundle:BundleName:BundleKey}`.
-The bundle name follows package naming conventions, for example:
-`${bundle:com.domain.Messages:MyKey}`.
-
-|ctx
-|Thread Context Map (MDC)
-
-|date
-|Inserts the current date and/or time using the specified format
-
-|docker
-| Returns attributes from the Docker container the application is running in. The format is ${docker:some.attribute}. See xref:log4j-docker.adoc[Docker documentation] for requirements and a list of available attributes.
-
-|env
-|System environment variables. The formats are `${env:ENV_NAME}` and `${env:ENV_NAME:-default_value}`.
-
-| event
-| Retrieves values from fields within the log event. The format is ${event:some.field}. See the Lookups manual page for a list of available fields.
-| java
-| Retrieves information about the Java environment the application is running in. The format is ${java:some.property}. See the Lookups manual page for a list of available properties.
-
-|jndi
-|A value set in the default JNDI Context.
-
-|jvmrunargs
-|A JVM input argument accessed through JMX, but not a main argument; see
-https://docs.oracle.com/javase/6/docs/api/java/lang/management/RuntimeMXBean.html#getInputArguments--[RuntimeMXBean.getInputArguments()].
-Not available on Android.
-
-| k8s
-| Returns attributes from the Kubernetes environment the application is running in. The format is ${k8s:some.attribute}. See the Lookups manual page for a list of available attributes.
-
-|log4j
-|Log4j configuration properties. The expressions
-`${log4j:configLocation}` and `${log4j:configParentLocation}`
-respectively provide the absolute path to the log4j configuration file
-and its parent folder.
-
-| lower
-| Converts the passed in argument to lower case (usually used with nested lookups). The format is ${lower:argument}.
-
-|main
-|A value set with
-../log4j-core/apidocs/org/apache/logging/log4j/core/lookup/MapLookup.html#setMainArguments-java.lang.String:A-[MapLookup.setMainArguments(String[])]
-
-|map
-|A value from a MapMessage
-
-| marker
-| Allows use of markers in configurations. The formats are ${marker:} and ${marker:some.name}. See the Lookups manual page for further details.
-
-|sd
-|A value from a StructuredDataMessage. The key "id" will return the
-name of the StructuredDataId without the enterprise number. The key
-"type" will return the message type. Other keys will retrieve individual
-elements from the Map.
-
-| spring
-| Returns values of Spring properties from the Spring configuration. The format is ${spring:some.property}. See the Lookups manual page for requirements and details.
-
-|sys
-|System properties. The formats are `${sys:some.property}` and
-`${sys:some.property:-default_value}`.
-
-| upper
-| Converts the passed in argument to upper case (usually used with nested lookups). The format is ${upper:argument}.
-| web
-| Returns values of variables associated with the Servlet Context. The format is ${spring:some.key}. See the Lookups manual page for a list of available keys.
-|===
+include::example$manual/configuration/routing.xml[tag=appender]
+----
-[#DefaultProperties]
-== Default Properties
-A default property map can be declared in the configuration file by placing a Properties
-element directly after the Configuration element and before any Loggers, Filters,
-Appenders, etc. are declared. If the value cannot be located in the specified lookup the
-value in the default property map will be used. The default map is pre-populated with a value
-for "hostName" that is the current system's host name or IP address and
-the "contextName" with is the value of the current logging context. See many places
-a Properties element is used in this section for examples.
-
-Default properties may also be specified in the Lookup by using the syntax `${lookupName:key:-defaultValue}`.
-In some cases the key might contain a leading '-'. When this is the case an escape character must be
-included, such as ``${main:\--file:-app.properties}`. This would use the
-`MainMapLookup` for a key named `--file`. If the key is not found then
-