I’m trying to use RFA built-in logging as described in the Reuters’ “ROBUST FOUNDATION API V7.6 CONFIGURATION AND LOGGING GUIDE” but I can’t figure out how to rotate the log files based on size or a date: unless I restart my application, the log file will not rotate and grow indefinitely.
Could you please help?
Here are the settings that I use:
<entry key="mountTrace" value="true"/> <entry key="logFileName" value="RFA_RSSL.%u.%g.log"/> <entry key="traceMsgDomains" value="NORMAL"/> <entry key="ipcTraceFlags" value="31"/>
Your configuration is to enable RFA trace log file(showing incoming and outgoing messages sent/received to RFA) which rotating log file is not supported. Even you can set “%g” which specify the generation number to distinguish rotated logs in the filename, RFA still writes only one log file with no limit size. For example, if you set logFileName to be RFA_RSSL%u%g.log, there will be only one RFA log file e.g. RFA_RSSL00.log while RFAJ application runs.
If you are running RFA Java, use Java logging, not RFA specific, to define:
"RFA Java Edition uses the Java Preferences API and the Java Logging API to manage its configuration and logging", you can use
java.util.logging.FileHandler.count = 5
java.util.logging.FileHandler.limit = 50000
If you are running RFA C++, use Config Database, to define:
"Configuration for the AppLogger component is retrieved from the Config Database with the same name as the logger itself". You can define
which will determine log file rotation into .OLD
Depending on how you are configuring your Config Database, in registry on Windows, or if you are configuring from file, or build config in code, please refer to App Logger section of the Config guide for the detailed description.