0
votes

I suddenly get a lot of very verbose debug information when running de Playframework with Debug logging. I don't know how this came about, and cannot see how to change it. I use the DEBUG level for my own logging, but my own log messages are now swallowed up big the DEBUG output of the framework, which is fast.

The only thing I have done (I think) is called the 'play dependencies' which might have downloaded maybe never versions of loggers etc.

Also, as I added a dependency myself I used the --verbose command while running 'dependencies' but this should not influence the running of the framework itself I would think. I cannot find anything in the documentation. Anybody who can help me to change this. I attached a small sample of the DEBUG output for illustration.

(edit: I am using Play! 1.2.4. Whatever logging level I set in the config file, the DEBUG info keeps displaying)

14:32:26.626 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to open ResultSet (open ResultSets: 0, globally: 0) 14:32:26.627 [play-thread-1] DEBUG org.hibernate.loader.Loader - result row: EntityKey[models.User#1] 14:32:26.627 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close ResultSet (open ResultSets: 1, globally: 1) 14:32:26.627 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1) 14:32:26.627 [play-thread-1] DEBUG o.h.e.StatefulPersistenceContext - initializing non-lazy collections 14:32:26.630 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to open PreparedStatement (open PreparedStatements: 0, globally: 0) 14:32:26.630 [play-thread-1] DEBUG org.hibernate.SQL - select user0_.id as id5_, user0_.addDate as addDate5_, user0_.lastUpdate as lastUpdate5_, user0_.app_id as app11_5_, user0_.blocked as blocked5_, user0_.email as email5_, user0_.firstName as firstName5_, user0_.lastName as lastName5_, user0_.passwordHash as password8_5_, user0_.userName as userName5_, user0_.userType as userType5_ from User user0_ where user0_.userName=? limit ? 14:32:26.631 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to open ResultSet (open ResultSets: 0, globally: 0) 14:32:26.631 [play-thread-1] DEBUG org.hibernate.loader.Loader - result row: EntityKey[models.User#1] 14:32:26.631 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close ResultSet (open ResultSets: 1, globally: 1) 14:32:26.631 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1) 14:32:26.631 [play-thread-1] DEBUG o.h.e.StatefulPersistenceContext - initializing non-lazy collections 14:32:26.634 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to open PreparedStatement (open PreparedStatements: 0, globally: 0) 14:32:26.634 [play-thread-1] DEBUG org.hibernate.SQL - select user0_.id as id5_, user0_.addDate as addDate5_, user0_.lastUpdate as lastUpdate5_, user0_.app_id as app11_5_, user0_.blocked as blocked5_, user0_.email as email5_, user0_.firstName as firstName5_, user0_.lastName as lastName5_, user0_.passwordHash as password8_5_, user0_.userName as userName5_, user0_.userType as userType5_ from User user0_ where user0_.userName=? limit ? 14:32:26.635 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to open ResultSet (open ResultSets: 0, globally: 0) 14:32:26.635 [play-thread-1] DEBUG org.hibernate.loader.Loader - result row: EntityKey[models.User#1] 14:32:26.635 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close ResultSet (open ResultSets: 1, globally: 1) 14:32:26.635 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1) 14:32:26.635 [play-thread-1] DEBUG o.h.e.StatefulPersistenceContext - initializing non-lazy collections 14:32:26.637 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to open PreparedStatement (open PreparedStatements: 0, globally: 0) 14:32:26.637 [play-thread-1] DEBUG org.hibernate.SQL - select user0_.id as id5_, user0_.addDate as addDate5_, user0_.lastUpdate as lastUpdate5_, user0_.app_id as app11_5_, user0_.blocked as blocked5_, user0_.email as email5_, user0_.firstName as firstName5_, user0_.lastName as lastName5_, user0_.passwordHash as password8_5_, user0_.userName as userName5_, user0_.userType as userType5_ from User user0_ where user0_.userName=? limit ? 14:32:26.638 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to open ResultSet (open ResultSets: 0, globally: 0) 14:32:26.638 [play-thread-1] DEBUG org.hibernate.loader.Loader - result row: EntityKey[models.User#1] 14:32:26.638 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close ResultSet (open ResultSets: 1, globally: 1) 14:32:26.638 [play-thread-1] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1)

2

2 Answers

1
votes

These log messages are from the logback library. Add logback.xml configuration file to the classpath.

0
votes

You can create a log4j.properties file and place it in your conf folder.Then modify it as per your requirement.