Skip to content

HIVE-29690: Fix StackOverflowError when calling get_table_objects_by_name_req API with both tablenames and pattern#6573

Open
vikramahuja1001 wants to merge 2 commits into
apache:masterfrom
vikramahuja1001:HIVE-29690
Open

HIVE-29690: Fix StackOverflowError when calling get_table_objects_by_name_req API with both tablenames and pattern#6573
vikramahuja1001 wants to merge 2 commits into
apache:masterfrom
vikramahuja1001:HIVE-29690

Conversation

@vikramahuja1001

@vikramahuja1001 vikramahuja1001 commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

Setting batching on the basis of tableNames rather than tablePattern

Why are the changes needed?

Check JIRA HIVE-29690 for the same.

Does this PR introduce any user-facing change?

No

How was this patch tested?

Tested with a custom test Program mentioned in the JIRA.

@sonarqubecloud

sonarqubecloud Bot commented Jul 8, 2026

Copy link
Copy Markdown

@vikramahuja1001

Copy link
Copy Markdown
Contributor Author

@deniskuzZ , @zabetak , @zhangbutao , @ayushtkn could someone please check this PR when you get a chance? Thanks.

if(req.getTablesPattern() != null) {
tables = ms.getTableObjectsByName(catName, dbName, tableNames, projectionsSpec, req.getTablesPattern());
// case : tableNames is empty -> return empty list
if (tableNames != null && tableNames.isEmpty()) {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

is it a valid scenario ?


// case : tableNames != null and pattern == null -> batched flow
// case : tableNames != null and pattern != null -> batched flow with pattern filter
String tablesPattern = req.getTablesPattern();

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

can we drop these comments and inline thereq.getTablesPattern() usage?

return tables;
}

if (req.getTablesPattern() != null && tableNames == null) {

@deniskuzZ deniskuzZ Jul 12, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think the original code was designed to support either the pattern or the names list
cc @saihemanth-cloudera, @dengzhhu653

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants