[vc_row][vc_column][vc_column_text]
Configuring and Disabling log tracking in FusionReactor
[/vc_column_text][us_separator][us_image image=”57774″][us_separator][vc_column_text]
FusionReactor tracks calls to any logging implementation made within your application. These logs are captured within the request object and can be configured based on their log severity.
We capture log statements for both Java frameworks and CF log statements;
[/vc_column_text][us_separator][vc_column_text]
Java Frameworks
- SLF4J
- Log4J
- Logback
- Apache Commons Logging
CFML log tags
- ColdFusion log tags
- Lucee log tags
In this blog we will cover how to configure framework log capture and how to disable log capture all together if you believe FusionReactor log tracking is causing issues in your application.
[/vc_column_text][us_separator][vc_column_text]
Configuring Java Framework log tracking in FusionReactor
It is possible to configure the logging severity for captured requests by going to FusionReactor (Top Left) > Plugins > Active Bundles, then modifying the configuration of the FusionReactor Log Tracker Plugin.
[/vc_column_text][us_separator][us_image image=”57776″][us_separator][vc_column_text]
In the configuration, you can capture log statements for error and above, warning and above, fatal only or no log statements at all.
[/vc_column_text][us_separator][us_image image=”57779″][us_separator][vc_column_text]
Disabling log tracking in FusionReactor
If you have sensitive information in log statements, or believe that FusionReactor is causing an issue with log capture, you can disable log tracking.
To do this you will need to deploy a properties file, as well as add a system property to your application server.
[/vc_column_text][us_separator][vc_column_text]
Creating the fusionreactoragent.properties file
In order to disable pointcuts into the logging Frameworks that FusionReactor makes using ASM, you will need to create a properties file in the same directory as your fusionreactor.jar file.
By default this will be {FusionReactor Directory}/instance/{instance name}, so on your server you may see;
- /opt/fusionreactor/tomcat/fusionreactor.jar
- C:\FusionReactorinstanceCF2018fusionreactor.jar
In this directory, you should create a file with the name ‘fusionreactoragent.properties’
In this file should contain;
com.intergral.fusionreactor.agent.pointcuts.logtracker.SLF4JPointCut=false com.intergral.fusionreactor.agent.pointcuts.logtracker.Log4J2PointCut=false com.intergral.fusionreactor.agent.pointcuts.logtracker.ColdFusionCFLOGPointCut=false com.intergral.fusionreactor.agent.pointcuts.logtracker.LuceeCFLOGPointCut=false
[/vc_column_text][us_separator][vc_column_text]
Adding system properties
FusionReactor uses mixins as well as cuts into the application code to track certain frameworks. In order to disable these mixins you will need to add the following system property to your jvm arguments file;
- -Dfr.mixin.apache.commons.logging=false
In ColdFusion, your jvm arguments are typically set in the jvm.config file, which is located in the {ColdFusion Directory}/cfusion/bin directory.
In tomcat / lucee, your jvm arguments are typically located in the setenv.sh file for unix, or through running the TomcatW.exe process in Windows. These files are located under the {Tomcat Directory}/bin directory.
For a full list of configuration files for the supported application server types see Application Server Examples
[/vc_column_text][us_separator][vc_column_text]
Restarting the Application server
In order to apply these changes, you will need to restart the application server.
- On windows this would typically involve restarting the Tomcat / ColdFusion service.
- On Linux this will normally involve running the restart command on the Tomcat / ColdFusion executable file.
You should now no longer see log statements on any transactions as FusionReactor is no longer interacting with the logging frameworks.
[/vc_column_text][/vc_column][/vc_row]