You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Stamatis Zampetakis (Jira)" <ji...@apache.org> on 2022/07/25 12:37:00 UTC
[jira] [Commented] (HIVE-26426) Avoid StringIndexOutOfBoundsException in canCBOHandleAst() method.
[ https://issues.apache.org/jira/browse/HIVE-26426?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17570875#comment-17570875 ]
Stamatis Zampetakis commented on HIVE-26426:
--------------------------------------------
Thanks for working on this [~achennagiri] !
For completeness and for people who may bump into this problem in the future can you please include the stacktrace (inside noformat tags) in the description of the JIRA.
> Avoid StringIndexOutOfBoundsException in canCBOHandleAst() method.
> ------------------------------------------------------------------
>
> Key: HIVE-26426
> URL: https://issues.apache.org/jira/browse/HIVE-26426
> Project: Hive
> Issue Type: Bug
> Components: HiveServer2
> Reporter: Abhay
> Assignee: Abhay
> Priority: Minor
> Labels: pull-request-available
> Time Spent: 20m
> Remaining Estimate: 0h
>
> The call to canHandleQbForCbo() can result in an StringIndexOutOfBoundsException. The assumption in the code is that the msg can only be null and we handle that but the msg can also be an empty string if the *verbose* is set to false. This can happen if INFO Logging is not enabled. We need to handle that case.
> https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/parse/CalcitePlanner.java#L913
--
This message was sent by Atlassian Jira
(v8.20.10#820010)