[ 
https://issues.apache.org/jira/browse/HIVE-25812?focusedWorklogId=699601&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-699601
 ]

ASF GitHub Bot logged work on HIVE-25812:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 21/Dec/21 19:10
            Start Date: 21/Dec/21 19:10
    Worklog Time Spent: 10m 
      Work Description: scarlin-cloudera closed pull request #2883:
URL: https://github.com/apache/hive/pull/2883


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 699601)
    Time Spent: 0.5h  (was: 20m)

> GetResultSchema service called in ERROR state
> ---------------------------------------------
>
>                 Key: HIVE-25812
>                 URL: https://issues.apache.org/jira/browse/HIVE-25812
>             Project: Hive
>          Issue Type: Improvement
>          Components: CLI
>            Reporter: Steve Carlin
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> After the "Execute" call is made from an HS2 client, the "GetResultsMetaData" 
> is called, followed by the "Fetch" call.
> If the "Execute" sets the error state to "ERROR" before the 
> GetResultsMetaData has been called, an exception is thrown since it only 
> expects the state to be RUNNING or FINISHED.
> The code affecting it is SQLOperation:
>  
> {code:java}
>   @Override
>   public TableSchema getResultSetSchema() throws HiveSQLException {
>     // Since compilation is always a blocking RPC call, and schema is ready 
> after compilation,
>     // we can return when are in the RUNNING state.
>     assertState(Arrays.asList(OperationState.RUNNING, 
> OperationState.FINISHED));
>     if (resultSchema == null) {
>       resultSchema = new TableSchema(driver.getSchema());
>     }   
>     return resultSchema;
>   }
> {code}
>  
> Adding ERROR to "assertState" should fix the problem.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to