You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2023/09/29 22:31:00 UTC

[jira] [Updated] (HIVE-27756) expose Lifetime in HikariConfig

     [ https://issues.apache.org/jira/browse/HIVE-27756?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

ASF GitHub Bot updated HIVE-27756:
----------------------------------
    Labels: pull-request-available  (was: )

> expose Lifetime in HikariConfig
> -------------------------------
>
>                 Key: HIVE-27756
>                 URL: https://issues.apache.org/jira/browse/HIVE-27756
>             Project: Hive
>          Issue Type: Improvement
>          Components: Standalone Metastore
>         Environment: hive-2.3.4+,
> hikaricp-2.5.1+;
> postgres 13.0
> pgbouncer 1.17
>            Reporter: Mingmin Xu
>            Assignee: Mingmin Xu
>            Priority: Minor
>              Labels: pull-request-available
>
> We run into an issue with HikariCP on Postgres with PgBouncer, that the connection in local pool is expired already, temporally we move to none_cp mode to mitigate the issue. By exposing [maxLifetime|https://github.com/brettwooldridge/HikariCP/blob/8c1a7c29341348b3ea71ccfe35d4858b378160e2/src/main/java/com/zaxxer/hikari/HikariConfig.java#L121C7-L121C18] in HikariConfig, we would be able to fix it.
> Regarding to the issue:
> * PgBouncer has one conf [server_lifetime|https://www.pgbouncer.org/config.html], named as T0, to expire long idle connections;
> *  HikariCP has maxLifetime with default as 1800_s, named as T1;
> When T1 > T0, HMS connection_pool would hold connections which is expired by pgbouncer already. For operation reasons, we prefer to keep a short conn_lifetime instead of increasing T0.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)