Skip to content

fix: Iceberg reflection for current() on TableOperations hierarchy#3895

Open
karuppayya wants to merge 2 commits intoapache:mainfrom
karuppayya:fix-mehthod-hierarchy
Open

fix: Iceberg reflection for current() on TableOperations hierarchy#3895
karuppayya wants to merge 2 commits intoapache:mainfrom
karuppayya:fix-mehthod-hierarchy

Conversation

@karuppayya
Copy link
Copy Markdown
Contributor

Which issue does this PR close?

Closes #3894.

Rationale for this change

Fix NoSuchMethodException from Iceberg Reflection

What changes are included in this PR?

Use findMethodInHierarchy instead of getDeclaredMethod so getTableMetadata and format-version reflection work when current() is declared on a superclass (e.g. BaseMetastoreTableOperations for Hive/Glue-style ops).

How are these changes tested?

  • Added Units
  • Tested by querying Hive backed Iceberg tables where this issue is present.

@mbutrovich mbutrovich changed the title Fix Iceberg reflection for current() on TableOperations hierarchy fix: Iceberg reflection for current() on TableOperations hierarchy Apr 3, 2026
Use findMethodInHierarchy instead of getDeclaredMethod so getTableMetadata and format-version reflection work when current() is declared on a superclass (e.g. BaseMetastoreTableOperations for Hive/Glue-style ops).

Add IcebergReflectionSuite with a BaseMetastoreTableOperations stub and BaseTable.

Made-with: Cursor
@karuppayya karuppayya force-pushed the fix-mehthod-hierarchy branch from 27dac8c to 433832e Compare April 3, 2026 18:23
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.

NoSuchMethodException when reflecting Iceberg TableOperations.current()

1 participant