[
https://issues.apache.org/jira/browse/HIVE-1546?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12901654#action_12901654
]
HBase Review Board commented on HIVE-1546:
------------------------------------------
Message from: "John Sichi" <[email protected]>
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://review.cloudera.org/r/713/#review1008
-----------------------------------------------------------
http://svn.apache.org/repos/asf/hadoop/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/Driver.java
<http://review.cloudera.org/r/713/#comment3232>
Can you break this out into several statements for readability?
http://svn.apache.org/repos/asf/hadoop/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/metadata/HiveUtils.java
<http://review.cloudera.org/r/713/#comment3233>
This does not belong in HiveUtils. Can't we just leave it where it is (in
SemanticAnalyzerFactory) and add a public accessor method for it so that
extensions can reuse it?
http://svn.apache.org/repos/asf/hadoop/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/BaseSemanticAnalyzer.java
<http://review.cloudera.org/r/713/#comment3234>
Why does this return a String []? The callers don't use it.
http://svn.apache.org/repos/asf/hadoop/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactoryInterface.java
<http://review.cloudera.org/r/713/#comment3231>
Putting "Interface" into the interface name is clunky.
Let's call the interface HiveSemanticAnalyzerFactory instead (matching the
convention for other plugin interfaces such as HiveStorageHandler and
HiveIndexHandler).
In addition, I think we should introduce a new interface
HiveSemanticAnalyzer and have the factory produce that, since factories should
generally produce interfaces rather than classes (e.g. so that dynamic proxies
can be used).
http://svn.apache.org/repos/asf/hadoop/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactoryInterface.java
<http://review.cloudera.org/r/713/#comment3224>
This configuration parameter needs to be defined in HiveConf.java following
the pattern already in use there.
Also, it needs a new entry in conf/hive-default.xml
http://svn.apache.org/repos/asf/hadoop/hive/trunk/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactoryInterface.java
<http://review.cloudera.org/r/713/#comment3228>
Our convention for existing Hive plugins is to make them extend
org.apache.hadoop.conf.Configurable and pass in the configuration only once via
setConf (rather than to individual methods such as get).
Inside a Configurable, you can get back to a HiveConf with:
new HiveConf(getConf(), YourClass.class)
- John
> 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
>
>
> 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.