Configuring named user and component logging

You can enable named user and component type logging by specifying properties in the log4j.properties file.

Named user logging enables you to target specific users for detailed logging without changing the general logging level for the rest of the user base. Filtering log information for individual users helps troubleshoot issues in a production environment with minimal performance overhead.

Component logging enables you to log specific components of the model for troubleshooting purposes. For example, you can enable logging for a class in the business model layer, such as the user class.

To configure logging:
  1. Open the log4j.properties file using a text editor.
    By default, the log4j.properties file is located in the SERVER_HOME\conf directory.
  2. Add properties to the file for the users and components that you want to log.
    Note: Named user logging occurs only for users identified in the log4j.properties file who are authenticated in the NexJ application.
  3. Save your changes and close the log4j.properties file.
Log messages for each user and each component specified in the log4j.properties file will be output in the application's log file.

Changes to the log4j configuration file can take up to one minute to take effect.