REX: HikariCP Optimizations in Java/Spring Boot/OpenShift
summary
Examines HikariCP connection-pool contention when running Spring Boot (Java 17) on OpenShift: default Hikari settings (maxPoolSize=10, connectionTimeout=30s) let an 11th request block and timeout while each DB connection spawns server processes that increase CPU/memory and kernel load. Recommends concrete fixes proven in production: keep defaults but tune SQL and pool sizing, enable leakDetectionThreshold and maxLifetime/keepalive, export Hikari metrics to APM/Grafana, and combine HPA with appropriate pod CPU/memory requests, limits and QoS so autoscaling reduces rather than increases DB contention.
AI-written summary · about
chapters (17)
- 0:00Introduction
- 1:08Conference context
- 4:41Connection timeouts problem
- 6:28HikariCP overview
- 10:03Connection pool sizing
- 14:19Pool sizing guidelines
- 17:08Connection timeout effects
- 18:30HikariCP connection lifecycle
- 22:03Connection resource management
- 24:27Pool observability
- 27:57Vertical and horizontal scaling
- 31:07OpenShift resource management
- 34:59Resource limits and QoS
- 39:11Pod count impact
- 40:37Horizontal Pod Autoscaler
- 42:41Observability and optimization
- 44:49Conclusion
related talks
30mHikari Connection Pooling with Spring Boot
51mWhen ORM Becomes OMG: Performance Pitfalls in JPA and Friends
44mPerformance oriented Spring Data JPA & Hibernate
45mWhen ORM Becomes OMG: Performance Pitfalls in JPA and Friends
49mPerformance oriented Spring Data JPA & Hibernate
52mHibernate performance tuning
39mDatabase Connection Pool Sizing - Demystified!
52mJava Persistence and Hibernate Tips that can boost up your application performance
