You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by Szehon Ho <sz...@cloudera.com> on 2013/12/10 01:54:20 UTC
Review Request 16146: HIVE-5993: JDBC Driver should not hard-code the
database name
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16146/
-----------------------------------------------------------
Review request for hive and Prasad Mujumdar.
Bugs: HIVE-5993
https://issues.apache.org/jira/browse/HIVE-5993
Repository: hive-git
Description
-------
Method HiveDatabaseMetadata.getDatabaseProductName() returns a hard-coded string "Hive".
This should instead call the existing Hive-server2 api to return the db name. Incidentally, the server returns "Apache Hive".
Diffs
-----
itests/hive-unit/src/test/java/org/apache/hive/jdbc/TestJdbcDriver2.java 1ba8ad3
jdbc/src/java/org/apache/hive/jdbc/HiveDatabaseMetaData.java 5087ded
Diff: https://reviews.apache.org/r/16146/diff/
Testing
-------
Ran TestJdbcDriver2.
Thanks,
Szehon Ho
Re: Review Request 16146: HIVE-5993: JDBC Driver should not hard-code the
database name
Posted by Prasad Mujumdar <pr...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16146/#review30246
-----------------------------------------------------------
Ship it!
Thanks for addressing the feedback.
Looks fine to me.
- Prasad Mujumdar
On Dec. 11, 2013, 10:33 p.m., Szehon Ho wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16146/
> -----------------------------------------------------------
>
> (Updated Dec. 11, 2013, 10:33 p.m.)
>
>
> Review request for hive and Prasad Mujumdar.
>
>
> Bugs: HIVE-5993
> https://issues.apache.org/jira/browse/HIVE-5993
>
>
> Repository: hive-git
>
>
> Description
> -------
>
> Method HiveDatabaseMetadata.getDatabaseProductName() returns a hard-coded string "Hive".
>
> This should instead call the existing Hive-server2 api to return the db name. Incidentally, the server returns "Apache Hive".
>
>
> Diffs
> -----
>
> itests/hive-unit/src/test/java/org/apache/hive/jdbc/TestJdbcDriver2.java 1ba8ad3
> jdbc/src/java/org/apache/hive/jdbc/HiveDatabaseMetaData.java 5087ded
>
> Diff: https://reviews.apache.org/r/16146/diff/
>
>
> Testing
> -------
>
> Ran TestJdbcDriver2.
>
>
> Thanks,
>
> Szehon Ho
>
>
Re: Review Request 16146: HIVE-5993: JDBC Driver should not hard-code the
database name
Posted by Szehon Ho <sz...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16146/
-----------------------------------------------------------
(Updated Dec. 11, 2013, 10:33 p.m.)
Review request for hive and Prasad Mujumdar.
Changes
-------
Thanks for the suggestion. Refactored the getInfo logic into a single method.
Bugs: HIVE-5993
https://issues.apache.org/jira/browse/HIVE-5993
Repository: hive-git
Description
-------
Method HiveDatabaseMetadata.getDatabaseProductName() returns a hard-coded string "Hive".
This should instead call the existing Hive-server2 api to return the db name. Incidentally, the server returns "Apache Hive".
Diffs (updated)
-----
itests/hive-unit/src/test/java/org/apache/hive/jdbc/TestJdbcDriver2.java 1ba8ad3
jdbc/src/java/org/apache/hive/jdbc/HiveDatabaseMetaData.java 5087ded
Diff: https://reviews.apache.org/r/16146/diff/
Testing
-------
Ran TestJdbcDriver2.
Thanks,
Szehon Ho
Re: Review Request 16146: HIVE-5993: JDBC Driver should not hard-code the
database name
Posted by Prasad Mujumdar <pr...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16146/#review30215
-----------------------------------------------------------
The patch look fine.
It would be better to avoid duplicating the code to call GetInfo().
jdbc/src/java/org/apache/hive/jdbc/HiveDatabaseMetaData.java
<https://reviews.apache.org/r/16146/#comment57827>
I think it would be better to add a helper method to call GetInfo() with given InfoType. We'll endup duplicating this code in multiple places.
- Prasad Mujumdar
On Dec. 10, 2013, 12:54 a.m., Szehon Ho wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/16146/
> -----------------------------------------------------------
>
> (Updated Dec. 10, 2013, 12:54 a.m.)
>
>
> Review request for hive and Prasad Mujumdar.
>
>
> Bugs: HIVE-5993
> https://issues.apache.org/jira/browse/HIVE-5993
>
>
> Repository: hive-git
>
>
> Description
> -------
>
> Method HiveDatabaseMetadata.getDatabaseProductName() returns a hard-coded string "Hive".
>
> This should instead call the existing Hive-server2 api to return the db name. Incidentally, the server returns "Apache Hive".
>
>
> Diffs
> -----
>
> itests/hive-unit/src/test/java/org/apache/hive/jdbc/TestJdbcDriver2.java 1ba8ad3
> jdbc/src/java/org/apache/hive/jdbc/HiveDatabaseMetaData.java 5087ded
>
> Diff: https://reviews.apache.org/r/16146/diff/
>
>
> Testing
> -------
>
> Ran TestJdbcDriver2.
>
>
> Thanks,
>
> Szehon Ho
>
>