Show/Hide Toolbars

Navigation: Application Server > Administration > Logging

Custom logging configuration

Scroll Prev Up Next More

If you want to use a custom logging configuration you can do so by creating an NLog configuration file named nlog.config in the Application directory.

On start-up the Application Server will search for an NLog configuration file named nlog.config in the Application directory. If such a file is found, can be read and parsed the Application Server will use that configuration instead of its default configuration.

An nlog.config file is a pure XML file having the <nlog /> element as its root. The use of namespaces is optional. You can use the following elements as sub element to <nlog />. The first two elements from the list are required to be present in all NLog configuration files, the remaining ones are optional and can be useful in advanced scenarios.

<targets /> – defines log targets/outputs

<rules /> – defines log routing rules

<extensions /> – loads NLog extensions from the *.dll file

<include />– includes external configuration file

<variable /> – sets the value of a configuration variable

For more information on how to write nLog configuration files please refer to the NLog documentation at http://nlog-project.org/

The Redbex Application Server also supports an NLog Target for logentries.com that can be used to log data in the cloud. To use this online service you will have to create a logentries.com account, which might come at additional cost.

© 2021 AFRY Austria GmbH, www.redbex.com