You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@impala.apache.org by "Tim Armstrong (Code Review)" <ge...@cloudera.org> on 2018/06/06 20:50:07 UTC

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Hello Tianyi Wang, Impala Public Jenkins,

I'd like you to do a code review. Please visit

    http://gerrit.cloudera.org:8080/10617

to review the following change.


Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................

IMPALA-7012: Fix NPE when parsing unexpected tokens

Currently some token are not added to tokenIdMap in the sql scanner and
an NPE will be thrown if such are parsed as unexpected tokens. This
patch fixes this bug and adds a case to ParserTest.

Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Reviewed-on: http://gerrit.cloudera.org:8080/10512
Reviewed-by: Tianyi Wang <tw...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
M fe/src/main/jflex/sql-scanner.flex
M fe/src/test/java/org/apache/impala/analysis/ParserTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
3 files changed, 36 insertions(+), 21 deletions(-)



  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/17/10617/1
-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: newchange
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 1
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Posted by "Tim Armstrong (Code Review)" <ge...@cloudera.org>.
Tim Armstrong has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/10617 )

Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................

IMPALA-7012: Fix NPE when parsing unexpected tokens

Currently some token are not added to tokenIdMap in the sql scanner and
an NPE will be thrown if such are parsed as unexpected tokens. This
patch fixes this bug and adds a case to ParserTest.

Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Reviewed-on: http://gerrit.cloudera.org:8080/10512
Reviewed-by: Tianyi Wang <tw...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
Reviewed-on: http://gerrit.cloudera.org:8080/10617
Reviewed-by: Tim Armstrong <ta...@cloudera.com>
Tested-by: Tim Armstrong <ta...@cloudera.com>
---
M fe/src/main/jflex/sql-scanner.flex
M fe/src/test/java/org/apache/impala/analysis/ParserTest.java
M fe/src/test/java/org/apache/impala/common/FrontendTestBase.java
3 files changed, 36 insertions(+), 21 deletions(-)

Approvals:
  Tim Armstrong: Looks good to me, approved; Verified

-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: merged
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 2
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Posted by "Tianyi Wang (Code Review)" <ge...@cloudera.org>.
Tianyi Wang has posted comments on this change. ( http://gerrit.cloudera.org:8080/10617 )

Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................


Patch Set 1:

So we need to manually verify it, right? I will build it and test the parser part.


-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 1
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Wed, 06 Jun 2018 22:22:57 +0000
Gerrit-HasComments: No

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Posted by "Tianyi Wang (Code Review)" <ge...@cloudera.org>.
Tianyi Wang has posted comments on this change. ( http://gerrit.cloudera.org:8080/10617 )

Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................


Patch Set 1:

Aren't clean picks automatic?


-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 1
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Wed, 06 Jun 2018 22:01:43 +0000
Gerrit-HasComments: No

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Posted by "Tim Armstrong (Code Review)" <ge...@cloudera.org>.
Tim Armstrong has posted comments on this change. ( http://gerrit.cloudera.org:8080/10617 )

Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................


Patch Set 1: Verified+1

Verified with https://gerrit.cloudera.org/#/c/10623/


-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 1
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Thu, 07 Jun 2018 00:23:37 +0000
Gerrit-HasComments: No

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Posted by "Tianyi Wang (Code Review)" <ge...@cloudera.org>.
Tianyi Wang has posted comments on this change. ( http://gerrit.cloudera.org:8080/10617 )

Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................


Patch Set 1:

Sorry I got it wrong. We should be able to merge it if the parser test passed in the build you mentioned.


-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 1
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Wed, 06 Jun 2018 22:27:17 +0000
Gerrit-HasComments: No

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Posted by "Tim Armstrong (Code Review)" <ge...@cloudera.org>.
Tim Armstrong has posted comments on this change. ( http://gerrit.cloudera.org:8080/10617 )

Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................


Patch Set 1: Code-Review+2

Clean pick


-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 1
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Wed, 06 Jun 2018 21:05:36 +0000
Gerrit-HasComments: No

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Posted by "Tim Armstrong (Code Review)" <ge...@cloudera.org>.
Tim Armstrong has posted comments on this change. ( http://gerrit.cloudera.org:8080/10617 )

Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................


Patch Set 1:

I'm running the precommit job on the head of all these commits. When that passes, I'll submit all of them together: https://gerrit.cloudera.org/#/c/10623/


-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 1
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Wed, 06 Jun 2018 22:27:45 +0000
Gerrit-HasComments: No

[Impala-ASF-CR](2.x) IMPALA-7012: Fix NPE when parsing unexpected tokens

Posted by "Tim Armstrong (Code Review)" <ge...@cloudera.org>.
Tim Armstrong has posted comments on this change. ( http://gerrit.cloudera.org:8080/10617 )

Change subject: IMPALA-7012: Fix NPE when parsing unexpected tokens
......................................................................


Patch Set 1:

A test failed while merging: https://jenkins.impala.io/job/cherrypick-2.x-and-test/ so I'm falling back to doing this manually.


-- 
To view, visit http://gerrit.cloudera.org:8080/10617
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: 2.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I9c846fdfb22ba37bfc3b1985b9a044014ab58968
Gerrit-Change-Number: 10617
Gerrit-PatchSet: 1
Gerrit-Owner: Tim Armstrong <ta...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Tianyi Wang <tw...@cloudera.com>
Gerrit-Reviewer: Tim Armstrong <ta...@cloudera.com>
Gerrit-Comment-Date: Wed, 06 Jun 2018 22:21:34 +0000
Gerrit-HasComments: No