In this example, we will be discussing the steps to turn on cache refresh debug from the log4j2.properties file. Below are the steps to enable debugging:
(1) Back up the file <TDV_SERVER>/conf/server/log4j2.properties on the TIBCO Data Virtualization Server.
(2) Append the following lines to the 'log4j2.properties' file or uncomment the existing lines, which will enable debug logging specifically for cache refresh:
logger.server_cache.name = com.compositesw.server.cache
logger.server_cache.level = DEBUG
(3) To activate the debug trace, you should restart the TDV Server. However, if you prefer not to restart it, you can use an alternative approach:
- Navigate to Studio > Administration > Configuration > Server > Configuration > Debugging > Debug Output Enabled.
- Change the value to “True”.
- Click “Apply” but don’t close the window.
- Immediately change the value back to “False”.
- Click “Apply” and close the window.
(4) Once debugging is enabled, you can proceed to reproduce the issue you're troubleshooting. The debug entries will be reflected in the 'cs_server.log' file.
Sample Entries:
DEBUG [Cache Task Processor] 2023-10-31 18:23:23.410 -0400 CacheSql - loaded cs:Status: UNKNOWN message: [ probe set{} active=[5002,/shared/IB_externalcaching/Oracle19c/SUPPORT1/Prajakta_cacheview0] refresh set{} inactive=4017(C) lastFailedLoadTime=none lastSuccessLoadTime=Tue Oct 31 18:23:22 EDT 2023]
DEBUG [Cache Task Processor] 2023-10-31 18:23:23.510 -0400 CacheStatus - Cache status loaded for /shared/IB_externalcaching/Cache_view
DEBUG [Cache Task Processor] 2023-10-31 18:23:23.510 -0400 CacheTaskThread - Cache task thread going to sleep until next
(5) To disable debug logging, comment the .level=DEBUG lines in the log4j2.properties / if new lines were added, then remove them. Carry out Step (3) once more to reload the log4j2 file to disable debug.