Lesson Learned #509: KeepAliveTime parameter in HikariCP by info.odysseyx@gmail.com September 27, 2024 written by info.odysseyx@gmail.com September 27, 2024 0 comment 12 views 12 Using network tracing, I observed that once a connection is established, the operating system sends TCP keepalives to keep it alive. This indicates how often the connection is checked to see if it remains active in the HikariCP connection pool. In this situation, my first idea for idle connections in the HikariCP pool was to configure the KeepAliveTime parameter. HikariCP sends a simple query (e.g. SELECT 1) to idle connections that have been inactive for longer than the value of this parameter. This will maintain the connection and prevent unexpected disconnection by external systems. You can view the results in the following network traces and SQL Profiler: Network settings related to firewalls have policies that close idle connections after a certain period of time. In this way, if a connection is closed and no keepalivetime is set, HikariCP will only detect the closure when the connection is requested from the pool. take pleasure in! Source link Share 0 FacebookTwitterPinterestEmail info.odysseyx@gmail.com previous post Data Science & Engineering Copilot next post New on Azure Marketplace: September 1-9, 2024 You may also like Believe Hyp about Quantum Protection: Report March 11, 2025 Google Jemi is coming to Android Auto but the rollout is hassle March 10, 2025 How the drones are transmitting security on the US southern border March 7, 2025 Remember a uninterrupted tech trailballs: Tom Mitchell March 7, 2025 New HMD X 1 ‘Safe’ Phone: Protection for Parents, Great Factors for Kids March 5, 2025 Opera adds Agent AI to his browser March 4, 2025 Leave a Comment Cancel Reply Save my name, email, and website in this browser for the next time I comment.