You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "Michael Smith (Jira)" <ji...@apache.org> on 2025/04/23 23:17:00 UTC

[jira] [Work started] (IMPALA-13989) ALTER TABLE RENAME can fail with concurrent INVALIDATE METADATA

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

Work on IMPALA-13989 started by Michael Smith.
----------------------------------------------
> ALTER TABLE RENAME can fail with concurrent INVALIDATE METADATA
> ---------------------------------------------------------------
>
>                 Key: IMPALA-13989
>                 URL: https://issues.apache.org/jira/browse/IMPALA-13989
>             Project: IMPALA
>          Issue Type: Bug
>          Components: Catalog
>    Affects Versions: Impala 5.0.0
>            Reporter: Michael Smith
>            Assignee: Michael Smith
>            Priority: Minor
>
> IMPALA-13631 removes holding the catalog's versionLock_ writeLock during the whole operation (including HMS RPC). That introduces a possible failure mode where {{ALTER TABLE RENAME}} fails with
> {quote}Table/view rename succeeded in the Hive Metastore, but failed in Impala's Catalog Server.{quote}
> when {{INVALIDATE METADATA}} is run concurrently. This shows up in the new statements added to test_concurrent_ddls.py.
> I can reproduce this error by adding a delay after HMS {{alter_table}} RPC completes (and before we {{getNextMetastoreEventsForTableIfEnabled}}) and running {{INVALIDATE METADATA}} from another session. I think that suggests the scenario as:
> # {{alter_table}} RPC completes
> # Impala {{invalidate metadata}} executes and processes {{alter_table}} event
> # {{alterTableOrViewRename}} runs {{catalog_.alterTable}}, but old table has already been removed from the catalog so it fails
> This should be pretty rare. Running a global {{invalidate metadata}} is a bad idea in a production environment as it's akin to restarting catalogd. However I think we can address this with better error handling in {{alterTableOrViewRename}}.



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

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org