For getting more information about Alfresco querys just edit
(extend) custom-log4j.properties in extension directory, for example:
(extend) custom-log4j.properties in extension directory, for example:
/opt/alfresco/tomcat/shared/classes/alfresco/extension/custom-log4j.properties
SQL queries:
log4j.logger.java.sql=debug log4j.logger.java.sql.Connection=DEBUG log4j.logger.java.sql.Statement=DEBUG log4j.logger.java.sql.PreparedStatement=DEBUG log4j.logger.java.sql.ResultSet=DEBUG
Be careful, this is pretty verbose. Be careful with caches too!.
SOLR queries:
log4j.logger.org.alfresco.repo.search.impl.solr.SolrQueryHTTPClient=DEBUG log4j.logger.org.alfresco.repo.search.impl.solr.DbOrIndexSwitchingQueryLanguage=DEBUG
Javascript API queries:
log4j.logger.org.alfresco.repo.jscript.ScriptLogger=DEBUG log4j.logger.org.alfresco.repo.jscript.Search=DEBUG
In Alfresco Enterprise, you have more options for doing this
without restarting the service:
without restarting the service:
- Use a
JMX console to enable log4j properties - Use Alfresco
support tools module to enable log4j properties
although not all classes are enabled via JMX or support tools,
for example the SQL and DbOrIndexSwitchingQueryLanguage loggers.
Tested in Alfresco 4.2.4 EE.
for example the SQL and DbOrIndexSwitchingQueryLanguage loggers.
Tested in Alfresco 4.2.4 EE.
Links:
- http://jmuras.com/blog/index.html%3Fp=1302.html
- http://smasue.github.io/alf-debug-solr/
- http://blyx.com/2014/02/18/alfresco-tip-logs/