Usage of P6Spy with datasource in Spring applicationContext.xml

后端 未结 2 1308
庸人自扰
庸人自扰 2021-01-03 05:06

I am using Hibernate 4, Spring 3, JSF 2.0 and Weblogic 10.3.6 as server.

I have created datasource on Weblogic server and in applicationContext.xml I have defined d

2条回答
  •  醉梦人生
    2021-01-03 05:28

    You need to create bean of session factory in applicationContext.xml file as follows:

    
            
                
            
        
        
            
            
            
            
        
    

    Please refer to: http://www.mkyong.com/hibernate/how-to-display-hibernate-sql-parameter-values-solution/ for more about P6Spy library.

    We can omit "dataSource" bean and directly write properties. Ref: how to configure hibernate config file for sql server

提交回复
热议问题