hadoop-hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Sichi (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HIVE-1546) Ability to plug custom Semantic Analyzers for Hive Grammar
Date Thu, 26 Aug 2010 20:46:53 GMT

    [ https://issues.apache.org/jira/browse/HIVE-1546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12903035#action_12903035
] 

John Sichi commented on HIVE-1546:
----------------------------------

Thanks, I took a look.  But factory producing factory seems like overkill here.

What I was thinking in my previous comment was as follows:

* only one level of factory
* define new interface HiveSemanticAnalyzer (not an abstract class):  copy signatures of interface
methods from public methods on BaseSemanticAnalyzer; add Javadoc (I can help with that if
any of them are non-obvious)
* when callers get new analyzer instance from factory, they refer to it via the HiveSemanticAnalyzer
interface only

If that doesn't work for some reason, then we can just use your original pattern where the
factory returns a class (BaseSemanticAnalyzer) instead of an interface.

Regarding handleGenericFileFormat:  I still don't understand.  Your code in Hive is ignoring
the return value (and the only implementation doesn't return anything, it just throws).  
So, either

(a) you're planning to do something inside of Howl with it; in that case, the Hive method
is just a hook for you to intercept, and it should return void

or

(b) you're planning to add some more code inside of Hive which actually does something with
the return value (e.g. sets the serde+inputformat+outputformat); in that case, you need to
keep working on the patch to make this happen


> Ability to plug custom Semantic Analyzers for Hive Grammar
> ----------------------------------------------------------
>
>                 Key: HIVE-1546
>                 URL: https://issues.apache.org/jira/browse/HIVE-1546
>             Project: Hadoop Hive
>          Issue Type: Improvement
>          Components: Metastore
>    Affects Versions: 0.7.0
>            Reporter: Ashutosh Chauhan
>            Assignee: Ashutosh Chauhan
>             Fix For: 0.7.0
>
>         Attachments: hive-1546.patch, hive-1546_2.patch
>
>
> It will be useful if Semantic Analysis phase is made pluggable such that other projects
can do custom analysis of hive queries before doing metastore operations on them. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message