hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hive QA (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HIVE-20608) Incorrect handling of sql command args in hive service leading to misleading error messages
Date Sun, 07 Oct 2018 05:27:00 GMT

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

Hive QA commented on HIVE-20608:
--------------------------------

| (x) *{color:red}-1 overall{color}* |
\\
\\
|| Vote || Subsystem || Runtime || Comment ||
|| || || || {color:brown} Prechecks {color} ||
| {color:green}+1{color} | {color:green} @author {color} | {color:green}  0m  0s{color} |
{color:green} The patch does not contain any @author tags. {color} |
|| || || || {color:brown} master Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  8m 10s{color}
| {color:green} master passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 22s{color} |
{color:green} master passed {color} |
| {color:green}+1{color} | {color:green} checkstyle {color} | {color:green}  0m 12s{color}
| {color:green} master passed {color} |
| {color:blue}0{color} | {color:blue} findbugs {color} | {color:blue}  0m 36s{color} | {color:blue}
service in master has 48 extant Findbugs warnings. {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 18s{color} |
{color:green} master passed {color} |
|| || || || {color:brown} Patch Compile Tests {color} ||
| {color:green}+1{color} | {color:green} mvninstall {color} | {color:green}  0m 23s{color}
| {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  0m 24s{color} |
{color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javac {color} | {color:green}  0m 24s{color} | {color:green}
the patch passed {color} |
| {color:red}-1{color} | {color:red} checkstyle {color} | {color:red}  0m 12s{color} | {color:red}
service: The patch generated 2 new + 3 unchanged - 0 fixed = 5 total (was 3) {color} |
| {color:green}+1{color} | {color:green} whitespace {color} | {color:green}  0m  0s{color}
| {color:green} The patch has no whitespace issues. {color} |
| {color:green}+1{color} | {color:green} findbugs {color} | {color:green}  0m 43s{color} |
{color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javadoc {color} | {color:green}  0m 17s{color} |
{color:green} the patch passed {color} |
|| || || || {color:brown} Other Tests {color} ||
| {color:red}-1{color} | {color:red} asflicense {color} | {color:red}  0m 13s{color} | {color:red}
The patch generated 2 ASF License warnings. {color} |
| {color:black}{color} | {color:black} {color} | {color:black} 12m 18s{color} | {color:black}
{color} |
\\
\\
|| Subsystem || Report/Notes ||
| Optional Tests |  asflicense  javac  javadoc  findbugs  checkstyle  compile  |
| uname | Linux hiveptest-server-upstream 3.16.0-4-amd64 #1 SMP Debian 3.16.36-1+deb8u1 (2016-09-03)
x86_64 GNU/Linux |
| Build tool | maven |
| Personality | /data/hiveptest/working/yetus_PreCommit-HIVE-Build-14290/dev-support/hive-personality.sh
|
| git revision | master / 3068f03 |
| Default Java | 1.8.0_111 |
| findbugs | v3.0.0 |
| checkstyle | http://104.198.109.242/logs//PreCommit-HIVE-Build-14290/yetus/diff-checkstyle-service.txt
|
| asflicense | http://104.198.109.242/logs//PreCommit-HIVE-Build-14290/yetus/patch-asflicense-problems.txt
|
| modules | C: service U: service |
| Console output | http://104.198.109.242/logs//PreCommit-HIVE-Build-14290/yetus.txt |
| Powered by | Apache Yetus    http://yetus.apache.org |


This message was automatically generated.



> Incorrect handling of sql command args in hive service leading to misleading error messages
> -------------------------------------------------------------------------------------------
>
>                 Key: HIVE-20608
>                 URL: https://issues.apache.org/jira/browse/HIVE-20608
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Soumabrata Chakraborty
>            Assignee: Soumabrata Chakraborty
>            Priority: Major
>         Attachments: HIVE-20608.2.patch, HIVE-20608.patch
>
>
> *Steps to reproduce:*
> (1) Connect to HiveServer2 using JDBC driver (not via Beeline)
> (2) Execute a set command with a space before set – e.g. " set hive.exec.dynamic.partiton=true"
> (3) The error that is returned says: 
> {code:java}
> Caused by: org.apache.hive.service.cli.HiveSQLException: Error while processing statement:
Cannot modify set hive.exec.dynamic.partition at runtime. It is not in list of params that
are allowed to be modified at runtime
> {code}
>  (4) However on removing the space before the set command - it works fine.
>  
> *Analysis:*
> Looks like an issue with [https://github.com/apache/hive/blob/master/service/src/java/org/apache/hive/service/cli/operation/HiveCommandOperation.java] 
> In the runInternal() method, the untrimmed sql statement is split by space (\\s) but
the substring operation to get the command args is done on the trimmed sql statement.  This
causes the issue. 
> {code:java}
> String command = getStatement().trim(); 
> String[] tokens = statement.split("\\s"); 
> String commandArgs = command.substring(tokens[0].length()).trim();
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message