In the event of an error while inserting a document into SBW DB or Analytics DB, an error message gets logged into esberr.log file. Instead of manually checking this log file for any failures while inserting the document into database, email alerts can be configured with specific log messages in the LogEmailer present at $FIORANO_HOME/esb/samples/SamplePrograms/Misc/LogEmailer.java.
To use the Log Emailer, perform the following actions after stopping the FES/FPS server:
- Start eStudio and open the Profile Management perspective.
- To enable sending of log alert in
- FES: Load FES profile and enable the LogAlertSendingEnabled option by going to Fiorano > esb > Transport > TransportManager > FESTransportManagerConfig
- FPS: Load FPS profile and and enable the LogAlertSendingEnabled option by going to Fiorano > Esb > Peer > Configuration > FPSCommonConfigLoader.
- FES: Load FES profile and enable the LogAlertSendingEnabled option by going to Fiorano > esb > Transport > TransportManager > FESTransportManagerConfig
- Start the servers.
- Set the configurations related to mail authentication and fiorano servers in the config.properties file at $FIORANO_HOME/esb/samples/SamplePrograms/Misc directory.
- Set the texts to be filtered in the filter.txt file at $FIORANO_HOME/esb/samples/SamplePrograms/Misc.
Compile the program using the command below:
Run the program using the command below:
Program subscribes to the topic given in the config.properties file and starts sending emails to the recipient in case of logs with the text given in filter.txt file.