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/17 22:44:16 UTC

Review Request 16330: HIVE-6045- Beeline hivevars is broken for more than one hivevar

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16330/
-----------------------------------------------------------

Review request for hive.


Bugs: HIVE-6045
    https://issues.apache.org/jira/browse/HIVE-6045


Repository: hive-git


Description
-------

The implementation appends hivevars to the jdbc url in the form "var1=val1&var2=val2$var3-val3"

but the regex used to parse this is expecting the delimiter to be ";".  Changed the regex to fit the hivevar format.


Diffs
-----

  jdbc/src/java/org/apache/hive/jdbc/Utils.java 913dc46 

Diff: https://reviews.apache.org/r/16330/diff/


Testing
-------

Looks like TestBeelineWithArgs is no longer being run, and there are a lot of failures there due to other changes even without this change.  Probably we need to move that test, and see if we can add a unit test there for this case.


Thanks,

Szehon Ho


Re: Review Request 16330: HIVE-6045- Beeline hivevars is broken for more than one hivevar

Posted by Szehon Ho <sz...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16330/
-----------------------------------------------------------

(Updated Dec. 19, 2013, 9:49 p.m.)


Review request for hive.


Changes
-------

Rebased with trunk.


Bugs: HIVE-6045
    https://issues.apache.org/jira/browse/HIVE-6045


Repository: hive-git


Description
-------

The implementation appends hivevars to the jdbc url in the form "var1=val1&var2=val2$var3-val3"

but the regex used to parse this is expecting the delimiter to be ";".  Changed the regex to fit the hivevar format.


Diffs (updated)
-----

  beeline/src/java/org/apache/hive/beeline/DatabaseConnection.java 1de5829 
  beeline/src/test/org/apache/hive/beeline/src/test/TestBeeLineWithArgs.java b077eb5 
  itests/hive-unit/src/test/java/org/apache/hive/beeline/TestBeeLineWithArgs.java PRE-CREATION 

Diff: https://reviews.apache.org/r/16330/diff/


Testing
-------

Looks like TestBeelineWithArgs is no longer being run, and there are a lot of failures there due to other changes even without this change.  Probably we need to move that test, and see if we can add a unit test there for this case.


Thanks,

Szehon Ho


Re: Review Request 16330: HIVE-6045- Beeline hivevars is broken for more than one hivevar

Posted by Szehon Ho <sz...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16330/
-----------------------------------------------------------

(Updated Dec. 19, 2013, 7:57 p.m.)


Review request for hive.


Changes
-------

Moved the TestBeeLineWithArgs under /itests where it is run.  Added a unit test "testBeelineMultiHiveVariable" for the case of multiple hivevars.


Bugs: HIVE-6045
    https://issues.apache.org/jira/browse/HIVE-6045


Repository: hive-git


Description
-------

The implementation appends hivevars to the jdbc url in the form "var1=val1&var2=val2$var3-val3"

but the regex used to parse this is expecting the delimiter to be ";".  Changed the regex to fit the hivevar format.


Diffs (updated)
-----

  beeline/src/java/org/apache/hive/beeline/DatabaseConnection.java 1de5829 
  beeline/src/test/org/apache/hive/beeline/src/test/TestBeeLineWithArgs.java 819a28d 
  itests/hive-unit/src/test/java/org/apache/hive/beeline/TestBeeLineWithArgs.java PRE-CREATION 

Diff: https://reviews.apache.org/r/16330/diff/


Testing
-------

Looks like TestBeelineWithArgs is no longer being run, and there are a lot of failures there due to other changes even without this change.  Probably we need to move that test, and see if we can add a unit test there for this case.


Thanks,

Szehon Ho


Re: Review Request 16330: HIVE-6045- Beeline hivevars is broken for more than one hivevar

Posted by Szehon Ho <sz...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16330/
-----------------------------------------------------------

(Updated Dec. 18, 2013, 12:41 a.m.)


Review request for hive.


Changes
-------

Today the hive-var is broken because of the following:

1. Beeline constructs jdbc url fragment of hive-var with '&' delimiter
2. JDBC uses ';' delimiter to parse this hive-var fragment.

Original patch had changed JDBC parsing regex (part 2) to expect '&'.  But some test cases were manually constructing JDBC url's with ';' as delimiter and checking the parsing works on that.  One option is the change the test, which should be fine for JDBC URL backward-compatibility as this is new feature for 0.13.

But still I decided to minimize the impact and choose an alternate fix (part 1), so that beeline constructs URL fragment with ';' delimiter.


Bugs: HIVE-6045
    https://issues.apache.org/jira/browse/HIVE-6045


Repository: hive-git


Description
-------

The implementation appends hivevars to the jdbc url in the form "var1=val1&var2=val2$var3-val3"

but the regex used to parse this is expecting the delimiter to be ";".  Changed the regex to fit the hivevar format.


Diffs (updated)
-----

  beeline/src/java/org/apache/hive/beeline/DatabaseConnection.java 1de5829 

Diff: https://reviews.apache.org/r/16330/diff/


Testing
-------

Looks like TestBeelineWithArgs is no longer being run, and there are a lot of failures there due to other changes even without this change.  Probably we need to move that test, and see if we can add a unit test there for this case.


Thanks,

Szehon Ho


Re: Review Request 16330: HIVE-6045- Beeline hivevars is broken for more than one hivevar

Posted by Szehon Ho <sz...@cloudera.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/16330/
-----------------------------------------------------------

(Updated Dec. 18, 2013, 12:39 a.m.)


Review request for hive.


Changes
-------

Today the hive-var is broken because of the following:

1. Beeline constructs jdbc url fragment of hive-var with '&' delimiter
2. JDBC uses ';' delimiter to parse this hive-var fragment.

Original patch had changed JDBC parsing regex (part 2) to expect '&'.  But some test cases were manually constructing JDBC url's with ';' as delimiter and checking the parsing works on that.  One option is the change the test, which should be fine for JDBC URL backward-compatibility as this is new feature for 0.13.

But still I decided to minimize the impact and choose an alternate fix (part 1), so that beeline constructs URL fragment with ';' delimiter.


Bugs: HIVE-6045
    https://issues.apache.org/jira/browse/HIVE-6045


Repository: hive-git


Description
-------

The implementation appends hivevars to the jdbc url in the form "var1=val1&var2=val2$var3-val3"

but the regex used to parse this is expecting the delimiter to be ";".  Changed the regex to fit the hivevar format.


Diffs (updated)
-----

  jdbc/src/java/org/apache/hive/jdbc/Utils.java 913dc46 

Diff: https://reviews.apache.org/r/16330/diff/


Testing
-------

Looks like TestBeelineWithArgs is no longer being run, and there are a lot of failures there due to other changes even without this change.  Probably we need to move that test, and see if we can add a unit test there for this case.


Thanks,

Szehon Ho