Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

How to enable Hibernate logging

SA-27680

Summary



How to enable Hibernate logging for the application?

Resolution



Follow the steps given below to enable the hibernate logging in the application:

1. In the location <workspace location>/ChordiantEAR/config/chordiant/hibernate/, three files, listed below, are present for out-of-the-box modules and services:

UserProfileObjects.cfg.xml
hibernate_QRST.cfg.xml
hibernate_JXB_XA.cfg.xml

Set show_sql tag to true in the files:
<property name="show_sql">true</property>

If there are any custom .cfg.xml files listed in this location, set show_sql to true in those files too.

2. In the location <workspace location>\ChordiantEAR\config\chordiant\ we have log4j.properties file, uncomment the line log4j.logger.org.hibernate.type=DEBUG in the log4j.properties file as shown below.

#Hibernate Logging
#uncomment hibernate.type=DEBUG for detailed log4j logging
#if hibernate show_sql=true is set in hibernate.cfg file
log4j.logger.org.hibernate.type=DEBUG

3. Publish and restart the server to pickup the changes. The sysout logs will have the hibernage logs as well.

Published September 16, 2016 - Updated October 8, 2020

Was this useful?

0% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Community has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice
Contact us