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

Xuefu Zhang commented on HIVE-8529:
-----------------------------------

[~ychena], I think it's fine to fix it at JDBC client. However, I'm wondering 
if it also makes sense to further fix HS2 so that it doesn't throw an 
exception. For instance, it can just return nothing if the flag isn't enabled 
and have a clear message (instead of a stacktrace) as a warning.

> HiveSessionImpl#fetchResults should not try to fetch operation log when 
> hive.server2.logging.operation.enabled is false.
> ------------------------------------------------------------------------------------------------------------------------
>
>                 Key: HIVE-8529
>                 URL: https://issues.apache.org/jira/browse/HIVE-8529
>             Project: Hive
>          Issue Type: Bug
>          Components: HiveServer2, JDBC
>    Affects Versions: 1.0.0, 1.2.0, 1.1.0, 1.3.0
>            Reporter: Vaibhav Gumashta
>            Assignee: Yongzhi Chen
>         Attachments: HIVE-8529.1.patch
>
>
> Throws this even when it is disabled:
> {code}
> 14/10/20 15:53:14 [HiveServer2-Handler-Pool: Thread-53]: DEBUG 
> security.UserGroupInformation: PrivilegedActionException as:vgumashta 
> (auth:SIMPLE) cause:org.apache.hive.service.cli.HiveSQLException: Couldn't 
> find log associated with operation handle: OperationHandle 
> [opType=EXECUTE_STATEMENT, 
> getHandleIdentifier()=b3d05ca6-e3e8-4bef-b869-0ea0732c3ac5]
> 14/10/20 15:53:14 [HiveServer2-Handler-Pool: Thread-53]: WARN 
> thrift.ThriftCLIService: Error fetching results: 
> org.apache.hive.service.cli.HiveSQLException: Couldn't find log associated 
> with operation handle: OperationHandle [opType=EXECUTE_STATEMENT, 
> getHandleIdentifier()=b3d05ca6-e3e8-4bef-b869-0ea0732c3ac5]
>       at 
> org.apache.hive.service.cli.operation.OperationManager.getOperationLogRowSet(OperationManager.java:240)
>       at 
> org.apache.hive.service.cli.session.HiveSessionImpl.fetchResults(HiveSessionImpl.java:665)
>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>       at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>       at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>       at java.lang.reflect.Method.invoke(Method.java:597)
>       at 
> org.apache.hive.service.cli.session.HiveSessionProxy.invoke(HiveSessionProxy.java:79)
>       at 
> org.apache.hive.service.cli.session.HiveSessionProxy.access$000(HiveSessionProxy.java:37)
>       at 
> org.apache.hive.service.cli.session.HiveSessionProxy$1.run(HiveSessionProxy.java:64)
>       at java.security.AccessController.doPrivileged(Native Method)
>       at javax.security.auth.Subject.doAs(Subject.java:394)
>       at 
> org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1548)
>       at 
> org.apache.hadoop.hive.shims.HadoopShimsSecure.doAs(HadoopShimsSecure.java:508)
>       at 
> org.apache.hive.service.cli.session.HiveSessionProxy.invoke(HiveSessionProxy.java:60)
>       at com.sun.proxy.$Proxy20.fetchResults(Unknown Source)
>       at 
> org.apache.hive.service.cli.CLIService.fetchResults(CLIService.java:427)
>       at 
> org.apache.hive.service.cli.thrift.ThriftCLIService.FetchResults(ThriftCLIService.java:582)
>       at 
> org.apache.hive.service.cli.thrift.TCLIService$Processor$FetchResults.getResult(TCLIService.java:1553)
>       at 
> org.apache.hive.service.cli.thrift.TCLIService$Processor$FetchResults.getResult(TCLIService.java:1538)
>       at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)
>       at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
>       at 
> org.apache.hive.service.auth.TSetIpAddressProcessor.process(TSetIpAddressProcessor.java:56)
>       at 
> org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:206)
>       at 
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
>       at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
>       at java.lang.Thread.run(Thread.java:695)
> 14/10/20 15:53:14 [HiveServer2-Handler-Pool: Thread-53]: DEBUG 
> transport.TSaslTransport: writing data length: 2525
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to