问题很大,故障描述.
- Dominant language
- Java
- Stars
- 28.2k
- Forks
- 8.6k
- PR merge metrics
- No merged PRs in 30d
Description
采用druid作为数据库的连接池,做了一个**数据访问服务**。该服务的就是让前端所有应用的sql查询都走数据访问服务数据库有(gauss200,oracle,mysql,gbase).整个项目运行后,每日的访问量最高峰3000万左右。目前(MPP)数据库的数据最多的40亿+的量,并且前端应用有较多的统计行语句或者慢sql语句,导致数据库响应很慢,然后连接池通道,长时间占用,导致获取不到最新的连接。出现
**get connection timeout retry :1,jdbc errorcode 17002 state 08006,IO error,connection reset by peer..**异常信息.当出现这种情况的时候,**整个服务的cpu 占用处于4000 的样子(64核的CPU),然后整个服务处于假死的状态**。但是数据库本身用连接工具连接是可以正常连接的。
请问druid 对这种高并发,大量统计或者慢sql 语句数据库本身响应就很慢的情况下,有什么好的解决办法,保证整个程序的能够正常平稳运行。
Contributor guide
Research direction
The report names no files or tests; start by reviewing Druid's connection-pool configuration and the reported JDBC error under the described high-concurrency, slow-SQL workload. Done would require a reproducible diagnosis and a documented change that prevents the service from entering the reported stalled state.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- backend, database
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 18/100