KO
|
EN
gitlite — search
Search
#claude-code
#ai
#developer-tools
#ai-agent
#cli
#claude
#mcp
#macos
#typescript
#python
#ai-agents
#codex
druid-spring-boot
★ 314
Open GitHub ↗
Spring Boot Starter for Druid.
Download README (.md)
Explore Similar Repositories
DNTFrameworkCore
:
Lightweight and Extensible Infrastructure for Building Web Applications - Web Application Framework
dctc
:
🎉TypeScript Execute (tsx): Dynamically compile TSX/TS file and execute it. The easiest way to run .tsx in Nodejs.
Chatette
:
A powerful dataset generator for Rasa NLU, inspired by Chatito
nim_duilib
:
duilib界面库的改进版,支持Windows/Linux/MacOS平台(基于SDL3),支持Skia渲染引擎(支持CPU/GPU),支持DPI感知,多语言动态切换,支持SVG, PNG, GIF, JPG, BMP, APNG, WEBP, ICO图片,支持GIF/WebP/APNG动画。
tensorflow_end2end_speech_recognition
:
End-to-End speech recognition implementation base on TensorFlow (CTC, Attention, and MTL training)
// repository documentation
Was this content helpful?
★ 0
(0 ratings)
Select Rating:
★
★
★
★
★
Submit Feedback
Recent Feedback
×
Download README
Do you want to download the
README.md
file for
druid-spring-boot
?
Download (.md)
# Druid Spring Boot Starter [](https://www.travis-ci.org/drtrang/druid-spring-boot) [](https://coveralls.io/github/drtrang/druid-spring-boot?branch=master) [](https://maven-badges.herokuapp.com/maven-central/com.github.drtrang/druid-spring-boot) [](https://github.com/drtrang/druid-spring-boot/releases) [](https://github.com/drtrang/druid-spring-boot/blob/master/LICENSE) Druid Spring Boot Starter 将帮助你在 Spring Boot 中使用 Druid。 ## 依赖 ```xml <!-- spring boot 1.x --> <dependency> <groupId>com.github.drtrang</groupId> <artifactId>druid-spring-boot-starter</artifactId> <version>1.1.10</version> </dependency> <dependency> <groupId>com.github.drtrang</groupId> <artifactId>druid-spring-boot-actuator-starter</artifactId> <version>1.1.10</version> </dependency> <!-- spring boot 2.x --> <dependency> <groupId>com.github.drtrang</groupId> <artifactId>druid-spring-boot2-starter</artifactId> <version>1.1.10</version> </dependency> <dependency> <groupId>com.github.drtrang</groupId> <artifactId>druid-spring-boot2-actuator-starter</artifactId> <version>1.1.10</version> </dependency> ``` ## 意见征集 [意见征集](https://github.com/drtrang/druid-spring-boot/issues/10) ## NEW ! 1. 基于 Spring Boot 2 开发的全新 starter,与之前功能完全一致 2. 改进多数据源的声明方式,由 Starter 自动发现配置并注册到 ApplicationContext,详情请查看 [Druid 多数据源支持.md](https://github.com/drtrang/druid-spring-boot/tree/master/docs/Druid%20%E5%A4%9A%E6%95%B0%E6%8D%AE%E6%BA%90%E6%94%AF%E6%8C%81.md) 3. 新增全配置说明 [druid.yml](https://github.com/drtrang/druid-spring-boot/blob/master/druid-spring-boot-example/druid-spring-boot-mybatis-example/src/main/resources/druid.yml) ## 配置 ### 简单配置 在引入依赖的情况下,只需如下配置即可使用 Druid: ```yaml spring: datasource: url: jdbc:h2:mem:example username: root password: 123456 ``` ### Druid 连接池 Druid Spring Boot Starter 会将以 `spring.datasource.druid` 为前缀的配置注入到 DruidDataSource,且 DruidDataSource 中的所有参数均可自定义。 ```yaml spring: datasource: url: jdbc:h2:mem:example username: root password: 123456 druid: max-wait: 30000 query-timeout: 10 validation-query: SELECT 1 use-global-data-source-stat: true ``` ### Druid 高级特性 Druid Spring Boot Starter 添加了 Druid 的大部分特性,如 StatFilter、WallFilter、ConfigFilter、WebStatFilter 等,其中 StatFilter 默认打开,其它特性默认关闭,需要手动开启。 同样,每个特性的参数均可自定义,具体配置可以用 IDE 的自动提示功能或者阅读 Druid 的 [Wiki](https://github.com/alibaba/druid/wiki/%E9%A6%96%E9%A1%B5) 查看。 ```yaml spring: datasource: druid: # 开启 StatFilter,默认开启,可通过 'enabled: false' 关闭 stat: enabled: true log-slow-sql: true slow-sql-millis: 1000 # 开启 Slf4jFilter slf4j: enabled: true data-source-log-enabled: false connection-log-enabled: false statement-log-enabled: false result-set-log-enabled: false # 开启 WallFilter wall: enabled: true log-violation: true throw-exception: false ## WallConfig 配置 config: delete-where-none-check: true # 开启 ConfigFilter config: enabled: true # 开启 Web 监控 web-stat: enabled: true # 开启 Aop 监控 aop-stat: enabled: true # 开启监控页面 stat-view-servlet: enabled: true ``` ### 多数据源 1.1.2 版本改进了多数据源的声明方式,由 Starter 自动发现配置并注册到 ApplicationContext,详情请查看 [Druid 多数据源支持.md](https://github.com/drtrang/druid-spring-boot/tree/master/docs/Druid%20%E5%A4%9A%E6%95%B0%E6%8D%AE%E6%BA%90%E6%94%AF%E6%8C%81.md)。 ```yaml spring: datasource: druid: data-sources: master: url: jdbc:h2:file:./master slave: url: jdbc:h2:file:./slave ``` ### 配置示例 [application.yml](https://github.com/drtrang/druid-spring-boot/blob/master/druid-spring-boot-example/druid-spring-boot-mybatis-example/src/main/resources/application.yml) ### 全配置说明 [druid.yml](https://github.com/drtrang/druid-spring-boot/blob/master/druid-spring-boot-example/druid-spring-boot-mybatis-example/src/main/resources/druid.yml) ## 自动提示 Druid Spring Boot Starter 基于 `spring-boot-configuration-processor` 模块,支持 IDE 的自动提示。 自定义参数:<br>  参数说明:  参数枚举值:  ## 演示 [druid-spring-boot-example](https://github.com/drtrang/druid-spring-boot/tree/master/druid-spring-boot-example) 中演示了 Druid Spring Boot Starter 的使用方式,可以作为参考。 ## Change Log [Release Notes](https://github.com/drtrang/druid-spring-boot/releases) ## TODO 任何意见和建议可以提 [ISSUE](https://github.com/drtrang/druid-spring-boot/issues),我会酌情加到 [TODO List](https://github.com/drtrang/druid-spring-boot/blob/master/TODO.md),一般情况一周内迭代完毕。 ## About Me QQ:349096849<br> Email:donghao.l@hotmail.com<br> Blog:[Trang's Blog](http://blog.trang.space)