Refinitiv / Real-Time-SDK

Other
191 stars 129 forks source link

EMA C# LoggerLevelEnum vs LoggerSeverity in docs #261

Closed lubomir-benus closed 6 months ago

lubomir-benus commented 11 months ago

Hi guys,

Looks like the definitions are not in sync (based on today 2023-12-28)

This is from EMACSharp_ConfigGuide.pdf

Possible values are: • LoggerSeverity::Verbose (0) • LoggerSeverity::Success (1) • LoggerSeverity::Warning (2) • LoggerSeverity::Error (3) • LoggerSeverity::NoLogMsg (4)

This is from EmaConfig class

//
// Summary:
//     This enumeration defines the logging severity for the Logger LoggerSeverity configuration
//     elements.
public class LoggerLevelEnum
{
    //
    // Summary:
    //     The EMA Logger will log verbose or trace events in addition to any below log
    //     events.
    public const int TRACE = 0;

    //
    // Summary:
    //     The EMA Logger will log informative events in addition to any below log events.
    public const int INFO = 2;

    //
    // Summary:
    //     The EMA Logger will log warning events in addition to any below log events.
    public const int WARNING = 3;

    //
    // Summary:
    //     The EMA Logger will log error events.
    public const int ERROR = 4;

    //
    // Summary:
    //     The EMA Logger will not log anything.
    public const int OFF = 5;

    //
    // Summary:
    //     Max defined Logger severity type.
    public const int MAX_DEFINED = 5;
}
vlevendel commented 10 months ago

Thank you for posting this issue. It is being reviewed internally.

soranat commented 10 months ago

The EMA C# configuration guide document will be updated the EMA configure to synchronize these values defined in the LoggerLevelEnum class as below.

• LoggerSeverity::Verbose (0) • LoggerSeverity::Success (2) • LoggerSeverity::Warning (3) • LoggerSeverity::Error (4) • LoggerSeverity::NoLogMsg (5)

lubomir-benus commented 10 months ago

Hi soranat,

is it correct? Because C++ implementation has it like this (it looks more reasonable):

Possible values are: • LoggerSeverity::Verbose (0) • LoggerSeverity::Success (1) • LoggerSeverity::Warning (2) • LoggerSeverity::Error (3) • LoggerSeverity::NoLogMsg (4)

soranat commented 10 months ago

Yes, this is correct as C# defines its own numeric severity values.

These numeric values are used for the programmatic configuration only such as in the Cons421 example while the EmaConfig.xml uses the string values such as below.

soranat commented 6 months ago

RTSDK 2.2.0.L1 addresses this issue by updating the EMA C# configuration guide. Please let us know if you have further concerns. Closing.