apache / apache/gravitino

[Improvement] Release resource in Iceberg catalog to make the associated class loader can be clean up

Open
#4,118 1 comment 0 reactions 0 assignees View on GitHub
improvement
Dominant language
Java
Stars
3.2k
Forks
935
Avg merge
1d 15h
Merged PRs (30d)
315

Description

### What would you like to be improved?

As the Iceberg catalog with the Hive backend (Hive catalog) does not provide a mechanism to close resources such as threads or connections, it's likey there will be resource leakage when catalog is dropped or recycled. please refer to:
https://github.com/apache/gravitino/issues/2527, https://github.com/apache/gravitino/pull/2548, https://github.com/apache/gravitino/pull/2548/commits/ab876b69b7e094bbd8c174d48a2365a18ed5176d

#2548 has fixed resource leakage in JDBC catalog, Hive catalog but NOT Iceberg catalog with Hive backend and the Iceberg community is reluctant to do such a job: see https://github.com/apache/iceberg/issues/10100, so we need to handle resource leakage in Gravitino

### How should we improve?

_No response_

Contributor guide

Open the contributing guide

Research direction

No file or test is named. Start by reading Gravitino issues #2527 and #2548 and the referenced Iceberg issue to trace how catalog resources are created and recycled. Done means the Iceberg catalog with the Hive backend releases its threads or connections when the catalog is dropped or recycled, with regression coverage identified during investigation.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.