ProgMan:Logging

From Mca2
Jump to navigationJump to search

Configuration

Configuration of the logging framework is done using the configuration framework. All configuration definitions are located "below" the /IclCore/Logging hierarchy. There are basically two things to configure:

  • Log output streams are configured with an OutputStream* tag. It has subtags for
    • OutputStreamName
    • Name
    • LogLevel
    • Format
    • Argument
    • LogLevel*
  • Log streams are configured with a LogStream* tag. It has subtags for
    • Name
    • LogLevel

Here is a short example:

<Config>
    <IclCore>
        <Logging>
            <OutputStream1>
                <OutputStreamName>Stdout</OutputStreamName>
                <Name>Stdout</Name>
                <LogLevel>Trace</LogLevel>
                <Format>~T ~S(~L): ~E</Format>
                <LogStream1>TestA</LogStream1>
                <LogStream2>TestB</LogStream2>
            </OutputStream1>
            <LogStream1>
                <Name>TestA</Name>
                <LogLevel>Trace</LogLevel>
            </LogStream1>
            <LogStream2>
                <Name>TestB</Name>
                <LogLevel>Debug</LogLevel>
            </LogStream2>
        </Logging>
    </IclCore>
</Config>