Hibernate Ⅱ Log4j Juit
来源:互联网 发布:经典球员数据盖德穆勒 编辑:程序博客网 时间:2024/06/05 14:59
搭建Log4j
在Hibernate中使用Log4j可以显示DDL语句,输出一系列的信息
首先导入相关的Jar包之后,写一个log4j.properties即可
log4j.properties:
### direct log messages to stdout ###log4j.appender.stdout=org.apache.log4j.ConsoleAppenderlog4j.appender.stdout.Target=System.outlog4j.appender.stdout.layout=org.apache.log4j.PatternLayoutlog4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c:%L - %m%n### direct messages to file hibernate.log ####log4j.appender.file=org.apache.log4j.FileAppender#log4j.appender.file.File=hibernate.log#log4j.appender.file.layout=org.apache.log4j.PatternLayout#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n### set log levels - for more verbose logging change 'info' to 'debug' ###log4j.rootLogger=warn, stdout#log4j.logger.org.hibernate=info#log4j.logger.org.hibernate=debug### log HQL query parser activity#log4j.logger.org.hibernate.hql.ast.AST=debug### log just the SQL#log4j.logger.org.hibernate.SQL=debug### log JDBC bind parameters ####log4j.logger.org.hibernate.type=info#log4j.logger.org.hibernate.type=debug### log schema export/update ###log4j.logger.org.hibernate.tool.hbm2ddl=debug### log HQL parse trees#log4j.logger.org.hibernate.hql=debug### log cache activity ####log4j.logger.org.hibernate.cache=debug### log transaction activity#log4j.logger.org.hibernate.transaction=debug### log JDBC resource acquisition#log4j.logger.org.hibernate.jdbc=debug### enable the following line if you want to track down connection ###### leakages when using DriverManagerConnectionProvider ###
阅读全文
0 0
- Hibernate Ⅱ Log4j Juit
- JUIT
- log4j配置hibernate
- hibernate log4j配置
- hibernate-log4j配置
- Hibernate 使用 log4j
- 让hibernate跑log4j
- log4j 有关hibernate 配置
- hibernate log4j日志
- 关于hibernate使用log4j
- Hibernate-log4J错误
- Hibernate配置Log4J
- LOG4J使用Hibernate管理数据库连接
- hibernate中的LOG4J日志记录
- hibernate 的 log4j.properties 配置文件
- hibernate之使用log4j配置文件
- 适合hibernate的log4j.properties
- 6.Hibernate首例:log4j.properties
- ANSYS Workbench 技巧特点
- elasticsearch5 官方文档整理。。。。中
- hexo 博客
- Hdu 5098 Smart Software Installer【思维+拓扑排序】
- c++-----string和深浅拷贝
- Hibernate Ⅱ Log4j Juit
- 有用的博客的链接
- nutch2.3分布式搭建
- flex:多栏多列弹性布局
- 同源策略与跨域
- 单例模式(Singleton)的同步锁synchronized
- H
- 华硕ASUS台式主板 改WIN7 BIOS 设置详解
- hadoop内存不足