Skip to content

Add the parameter: metastore.drop-partition-ignore-nonexistent to ignore exceptions when a Hive partition does not exist.#7969

Open
GangYang-HX wants to merge 1 commit into
apache:masterfrom
GangYang-HX:issue-7964
Open

Add the parameter: metastore.drop-partition-ignore-nonexistent to ignore exceptions when a Hive partition does not exist.#7969
GangYang-HX wants to merge 1 commit into
apache:masterfrom
GangYang-HX:issue-7964

Conversation

@GangYang-HX
Copy link
Copy Markdown
Contributor

Fixed a bug that caused the Partition Expire operation to fail due to a non-existent Hive partition.

…ore exceptions when a Hive partition does not exist.
Copy link
Copy Markdown
Contributor

@JingsongLi JingsongLi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few comments on this PR:

  1. .gitignore change: The .cursor-svg-check/ entry looks unrelated to this PR — likely IDE-specific. Please remove it or put it into a separate commit.

  2. Design question: When MetaException is caught with ignorePartitionNonexistent=true, the code calls partitionExistsInHms() which issues a second HMS RPC (getPartition). If HMS is unhealthy (which is likely the cause of the original MetaException), this verification call may also fail — and the fallback in that case conservatively returns true, causing the original exception to be rethrown anyway. This is a reasonable safety choice, but it means the option won't help when HMS is in a bad state.

    Consider documenting this behavior (i.e., "the option only helps when the specific partition is genuinely absent, not when HMS is having connectivity issues").

  3. Title format: The PR title doesn't follow the project convention of [module] description. Should be something like: [hive] Add metastore.drop-partition-ignore-nonexistent option.

  4. Option naming: The Paimon project typically uses shorter, more consistent option names. metastore.drop-partition-ignore-nonexistent is quite long. Have you considered metastore.drop-partition.ignore-not-exists to be more consistent with other Paimon options?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants