Error Logging & Debugging in Oracle WebCenter Sites

Adding Dynamic Loggers
To add dynamic loggers, add the following code to file.

Screenshot: file


Screenshot: mylogs.log file is created inside the logs folder



Updating Maximum File size for sites.log file
Screenshot: file



Backup Files for sites.log file
Screenshot: file



Configure log4j
1. Setting up Apache log4j:

If WebCenter Sites was not set up to use log4j during the upgrade process, you can manually switch to log4j by configuring the and files in the WEB-INF/classes directory.

To set up log4j:
In the file, update the following property to set log4j as WebCenter Sites’ logging system:
org.apache.commons.logging.Log= org.apache.commons.logging.impl.Log4JLogger

2. Viewing Loggers:

Loggers that are registered in the file, in the WEB-INF/classes directory. The file is read only on system start up. If, during runtime, you make changes to the file and save them, your changes will not be displayed in the log4j Configuration form. They will be applied and displayed when WebCenter Sites is restarted.

Note: The futuretense.txt file is typically located in the WebCenter Sites installation directory.

Loggers that are detected during runtime. The loggers are detected when:

  • System features or add-on components are accessed for the first time.
  • The loggers are added to the system manually by developers using the Add Logger.

To view loggers
On the Admin tab, expand System Tools and double-click Configure log4j.
The list of loggers with explicitly assigned levels is displayed.

Screenshot: log4j configuration formviewloggers