[
https://issues.apache.org/jira/browse/HIVE-20016?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16526369#comment-16526369
]
Yongzhi Chen edited comment on HIVE-20016 at 6/28/18 2:59 PM:
--------------------------------------------------------------
The strange thing is Thread-2154 finish setupAuth() for Session
e14a5024-5241-4ae6-84f5-b5e1cbb6fa15 at 2018-06-27T22:24:46,719
2018-06-27T22:24:46,719 DEBUG [HiveServer2-Background-Pool: Thread-2154]
session.SessionState: Session is using authorization class class
org.apache.hadoop.hive.ql.security.authorization.plugin.HiveAuthorizerImpl
How could thread Thread-2128 still could not get Authorization plugins at
2018-06-27T22:24:46,720 ?
Because the setupAuth() is not synchronized, thread 2128 calls
GetSchemasOperation at:
2018-06-27T22:24:46,717 INFO [e14a5024-5241-4ae6-84f5-b5e1cbb6fa15
HiveServer2-Handler-Pool: Thread-2128] operation.GetSchemasOperation: Fetching
schema metadata
Then 2128 calls setupAuth() when 2154 is working on the same method. 2128
return right away because authenticator is not null, but authorizer and
authorizerV2 are still null(2154 has not done with the method yet). And
somehow, the error message is thrown a little late
2018-06-27T22:24:46,720 WARN [HiveServer2-Handler-Pool: Thread-2128]
thrift.ThriftCLIService: Error getting schemas:
java.lang.RuntimeException: java.lang.AssertionError: Authorization plugins not
initialized!
was (Author: ychena):
The strange thing is Thread-2154 finish setupAuth() for Session
e14a5024-5241-4ae6-84f5-b5e1cbb6fa15 at 2018-06-27T22:24:46,719
2018-06-27T22:24:46,719 DEBUG [HiveServer2-Background-Pool: Thread-2154]
session.SessionState: Session is using authorization class class
org.apache.hadoop.hive.ql.security.authorization.plugin.HiveAuthorizerImpl
How could thread Thread-2128 still could not get Authorization plugins at
2018-06-27T22:24:46,720 ?
2018-06-27T22:24:46,720 WARN [HiveServer2-Handler-Pool: Thread-2128]
thrift.ThriftCLIService: Error getting schemas:
java.lang.RuntimeException: java.lang.AssertionError: Authorization plugins not
initialized!
> Investigate random test failure
> --------------------------------
>
> Key: HIVE-20016
> URL: https://issues.apache.org/jira/browse/HIVE-20016
> Project: Hive
> Issue Type: Bug
> Components: HiveServer2
> Affects Versions: 4.0.0
> Reporter: Yongzhi Chen
> Assignee: Yongzhi Chen
> Priority: Major
>
> org.apache.hive.jdbc.TestJdbcWithMiniHS2.testParallelCompilation3 failed with:
> java.lang.AssertionError: Concurrent Statement failed:
> org.apache.hive.service.cli.HiveSQLException: java.lang.AssertionError:
> Authorization plugins not initialized!
> at org.junit.Assert.fail(Assert.java:88)
> at
> org.apache.hive.jdbc.TestJdbcWithMiniHS2.finishTasks(TestJdbcWithMiniHS2.java:374)
> at
> org.apache.hive.jdbc.TestJdbcWithMiniHS2.testParallelCompilation3(TestJdbcWithMiniHS2.java:304)
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)