Vladan Vasić created SPARK-62296:
------------------------------------

             Summary: Extract reusable DESCRIBE analysis helpers
                 Key: SPARK-62296
                 URL: https://issues.apache.org/jira/browse/SPARK-62296
             Project: Spark
          Issue Type: Improvement
          Components: SQL
    Affects Versions: 5.0.0
            Reporter: Vladan Vasić


DESCRIBE analysis is spread across private analyzer-rule methods and match 
arms. Reusing one operation currently requires duplicating the logic or 
invoking a rule that traverses a plan.

Extract the current behavior into reusable helpers and retain the existing 
rules as callers:
* V1 lowering of table, partition, column, namespace and function descriptions;
* namespace metadata resolution, with name selection retained by the rule;
* builtin, temporary and persistent function metadata lookup;
* resolved DDL-target validation;
* not-found search-path formatting with the caller's error formatter;
* legacy namespace output naming, with the configuration gate retained by the 
rule.

This is an internal refactor. Preserve catalog precedence, V1/V2 fall-through, 
function lookup order, errors and their origins, lazy error-path evaluation, 
output schemas and expression IDs. Procedure resolution already has a shared 
helper and needs no change.

Add focused tests in the existing analysis and command suites, then run the 
affected Catalyst, SQL and Hive suites and style checks.

Validation: JDK 21 and SBT with Hive enabled. All 602 tests passed across 14 
Catalyst, SQL and Hive suites. Catalyst and SQL production/test scalastyle 
checks passed with zero errors or warnings.




--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to