question

Upvotes
Accepted
95 7 12 25

How to limit the number of generated logs in EMA?

Hi,

when using the EMA (C++) Library for a server application, it is normally useful to enable the logs generation to file with standard level for the consumer(s) and provider(s) used.

However, the generated logs are always in the form <FileName>_pid.log (default: “emaLog_pid.log”).

With time, this causes the generation of several logs in the application's working directory (one for each instance of the application). Suppose for instance an application restarted on a daily basis..

Is there in EMA any rolling mechanism that allows to control the number of generated logs?

Thanks

Best Regards,

Paolo

elektronrefinitiv-realtimeelektron-sdkema-apirrtelektron-message-apilogging
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
25.3k 87 12 25

Hi @Paolo Parlapiano

In that case, I recommend you log a change request as an Issue on the Github page for the Elektron SDK - asking the development team to add more control over the Log file creation.


icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
25.3k 87 12 25

Hi @Paolo Parlapiano

The logging related parameters are covered in section 3.5 of the EMACPP_ConfigGuide which is also included in PDF form with the Elektron SDK.

As you will note there is a FileName parameter which allows you to override the default 'emaLog_pid.log'

If you need to vary the filename programmatically you can use the Programmatic Config functionality demonstrated in example 421__MarketPrice__ProgrammaticConfig.

Programmatic Config is also described in section 4.5 of the above config guide.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
95 7 12 25

Hi @Umer Nalla,


if I override the FileName parameter, the final result is anyway myFileName_pid.log, which doesn't resolve the issue.


Thanks

Regards,

Paolo

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.