MicroStrategy ONE
Logging Examples
This section provides typical examples on customizing logging, including logging error messages to different output sources and reducing the amount of information logged.
The recommended practice when customizing logging is to do the following:
-
First, set any desired logging preferences on the MicroStrategy Web Administrator Page.
Open the MicroStrategy Web Administrator Page. On the WEB SERVER panel on the left side of the MicroStrategy Web Administrator Page, choose Diagnostics -> Configuration. On the Diagnostics Configuration panel on the right side of the page, make sure that the Internal diagnostic setup radio button is selected. Set the desired logging preferences and click the Save button.
-
Create a new plug-in and give it a meaningful name. For example: MyCustomLogging.
-
Exit the Web Customization Editor.
-
Navigate to the WEB-INF/xml folder inside your MicroStrategy Web installation.
-
Make a copy of logger.properties and save it in your new customization plug-in folder (plugins/MyCustomLogging/WEB-INF/xml) inside the plugins folder of the MicroStrategy Web installation. This file includes any preferences that you set and saved in the previous step.
-
Edit this custom logger.properties file from the plug-in folder to make the customizations and save the modified file. Links to a number of common customizations are provided here.
-
Save your changes.
-
If the Web Customization Editor is closed, launch it again and access your plug-in.
-
Click on MicroStrategy Web Configuration inside the Application Settings view to expand the hierarchical tree. The expanded list comprises the different settings that can be modified to perform customizations.
-
Click Web Configuration Settings.
-
Double-click MicroStrategy Configuration Settings to launch the Global Settings editor.
-
Click ... for Server Log Properties to point to the edited logger.properties in plugins/MyCustomLogging/WEB-INF/xml.
-
Save your changes.
For specific settings that affect whether customization changes are applied automatically or require a restart of the Web server, see Applying customization changes to the application.
Before you begin to customize logging, it is useful to understand the logging infrastructure used by MicroStrategy Web. The nature of messages logged is determined by specifying components such as handlers, formatters and filters for the logger. The following examples show how different components are used to achieve the desired level of logging.
These examples show how you can modify the custom logger.properties file to log messages to a particular destination.
These examples show how you can modify the custom logger.properties file to log messages to a particular destination for individual packages.
This example shows how you can modify the custom logger.properties file to reduce the amount of information written to the log file.
See Also