i have found from the document, and seems that spring-boot only support tomcat-jdbc,HikariCP and DBCP connection pool, if i want to use druid(https://github.com/alibaba/druid/wiki/FAQ) in my project with spring-boot, may i know how to do?

This kind of question is best asked on stackoverflow.com (use the spring-boot tag).

We don't currently offer any auto-configuration support for druid, but you should be able to configure directly as you would any other Spring Bean. Probably something like this:

@Bean
public DruidDataSource dataSource() {
    DruidDataSource ds = new DruidDataSource();
    ds.setUrl(...);
    ds.setUserName(...);
    ds.setPassword(...);
    // any other configuration
    return ds;
}

https://github.com/spring-projects/spring-boot/issues/2301

 

 

https://github.com/Lzw2016/druid-spring-boot-starter

https://github.com/CrazyApeDX/spring-boot-starter-druid

https://github.com/xubinux/spring-boot-starter-druid  gd

 

https://eacdy.gitbooks.io/spring-cloud-book/content/

 

https://github.com/zalando/spring-boot-etcd

 

相关文章:

  • 2021-07-18
  • 2021-09-01
  • 2022-12-23
  • 2021-11-21
  • 2021-11-09
  • 2022-12-23
  • 2021-10-21
  • 2022-01-03
猜你喜欢
  • 2021-06-24
  • 2022-12-23
  • 2022-12-23
  • 2021-11-13
  • 2021-12-07
  • 2022-01-29
相关资源
相似解决方案