How to set up datasource with Spring for HikariCP?

后端 未结 9 897
傲寒
傲寒 2020-11-27 02:51

Hi I\'m trying to use HikariCP with Spring for connection pool. I\'m using jdbcTempLate and JdbcdaoSupport.
This is my spring configuration file for datasource:

9条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-11-27 03:47

    Using XML configuration, your data source should look something like this:

          
          
            
                jdbc:oracle:thin:@localhost:1521:XE
                username
                password
            
            
            
          
    
          
                
          
    

    Or you could skip the HikariConfig bean altogether and use an approach like the one mentioned here

提交回复
热议问题