各数据库连接池性能对比

测试结果

c3p0

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.1      0       1
Processing:    17   63  29.7     54     178
Waiting:       17   63  29.7     54     177
Total:         18   63  29.7     54     178

dbcp

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.1      0       0
Processing:    21   52  31.8     42     282
Waiting:       21   52  31.8     42     281
Total:         21   52  31.8     42     282

druid

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.1      0       0
Processing:    48   83  19.1     80     200
Waiting:       47   83  19.1     80     199
Total:         48   83  19.1     80     200

hikari

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.1      0       0
Processing:    21   51  39.3     34     265
Waiting:       21   50  39.3     34     265
Total:         22   51  39.3     35     266

no-pool

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.1      0       0
Processing:    25   54  21.5     51     221
Waiting:       25   54  21.4     50     220
Total:         25   54  21.4     51     221

结论

hikari 性能在插入 1000 条数据最佳

仓库代码

GitCode - 全球开发者的开源社区,开源代码托管平台

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值