loggingnxbre

Logging with NxBRE


How do I instruct NxBRE engine to log some message? I know there is <log> tag available, which can be used as follows:

<Log level="INFO" msg="blabla"/>

But I cannot find any documentation on it. Mainly, I need answers to these questions:

  1. How do I specify which logging engine to use (e.g., I want to use log4net - how do I let NxBRE know this)?

  2. What are supported values of level attribute?

Thanks!


Solution

  • NxBRE relies on System.Diagnostics for its logging needs, and therefore is configured via the standard .NET mechanism. This is documented in section 5 of the user guide, from which the following is taken:

    Here is the list of available sources and switches:

    Source / Switch Name | Purpose

    NxBRE.FlowEngine | Trace events emitted by the Flow Engine.

    NxBRE.FlowEngine.RuleBase | Trace events emitted by rule base level operations (log, exceptions).

    NxBRE.InferenceEngine | Trace events emitted by the Inference Engine. NxBRE.Util | Trace events emitted by the utility classes.

    If you want to use log4net, you will have to fork the project and switch to this logging framework.