[ https://issues.apache.org/jira/browse/HIVE-4778?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13739428#comment-13739428 ]
Hive QA commented on HIVE-4778: ------------------------------- {color:red}Overall{color}: -1 at least one tests failed Here are the results of testing the latest attachment: https://issues.apache.org/jira/secure/attachment/12597852/HIVE-4778.D12213.1.patch {color:red}ERROR:{color} -1 due to 1 failed/errored test(s), 2857 tests executed *Failed tests:* {noformat} org.apache.hadoop.hive.cli.TestMinimrCliDriver.testCliDriver_infer_bucket_sort_reducers_power_two {noformat} Test results: https://builds.apache.org/job/PreCommit-HIVE-Build/431/testReport Console output: https://builds.apache.org/job/PreCommit-HIVE-Build/431/console Messages: {noformat} Executing org.apache.hive.ptest.execution.PrepPhase Executing org.apache.hive.ptest.execution.ExecutionPhase Executing org.apache.hive.ptest.execution.ReportingPhase Tests failed with: TestsFailedException: 1 tests failed {noformat} This message is automatically generated. > hive.server2.authentication CUSTOM not working > ---------------------------------------------- > > Key: HIVE-4778 > URL: https://issues.apache.org/jira/browse/HIVE-4778 > Project: Hive > Issue Type: Bug > Components: Authentication > Affects Versions: 0.11.0 > Environment: CentOS release 6.2 x86_64 > java version "1.6.0_31" > Java(TM) SE Runtime Environment (build 1.6.0_31-b04) > Java HotSpot(TM) 64-Bit Server VM (build 20.6-b01, mixed mode) > Reporter: Zdenek Ott > Assignee: Azrael Park > Attachments: HIVE-4778.D12207.1.patch, HIVE-4778.D12213.1.patch > > > I have created my own class PamAuthenticationProvider that implements > PasswdAuthenticationProvider interface. I have puted jar into hive lib > directory and have configured hive-site.xml in following way: > <property> > <name>hive.server2.authentication</name> > <value>CUSTOM</value> > </property> > <property> > <name>hive.server2.custom.authentication.class</name> > <value>com.avast.ff.hive.PamAuthenticationProvider</value> > </property> > I use SQuireL and jdbc drivers to connect to hive. During authentication Hive > throws following exception: > java.lang.RuntimeException: java.lang.NoSuchMethodException: > org.apache.hive.service.auth.PasswdAuthenticationProvider.<init>() > at > org.apache.hadoop.util.ReflectionUtils.newInstance(ReflectionUtils.java:128) > at > org.apache.hive.service.auth.CustomAuthenticationProviderImpl.<init>(CustomAuthenticationProviderImpl.java:20) > at > org.apache.hive.service.auth.AuthenticationProviderFactory.getAuthenticationProvider(AuthenticationProviderFactory.java:57) > at > org.apache.hive.service.auth.PlainSaslHelper$PlainServerCallbackHandler.handle(PlainSaslHelper.java:61) > at > org.apache.hive.service.auth.PlainSaslServer.evaluateResponse(PlainSaslServer.java:127) > at > org.apache.thrift.transport.TSaslTransport$SaslParticipant.evaluateChallengeOrResponse(TSaslTransport.java:509) > at > org.apache.thrift.transport.TSaslTransport.open(TSaslTransport.java:264) > at > org.apache.thrift.transport.TSaslServerTransport.open(TSaslServerTransport.java:41) > at > org.apache.thrift.transport.TSaslServerTransport$Factory.getTransport(TSaslServerTransport.java:216) > at > org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:189) > at > java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) > at > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) > at java.lang.Thread.run(Thread.java:662) > Caused by: java.lang.NoSuchMethodException: > org.apache.hive.service.auth.PasswdAuthenticationProvider.<init>() > at java.lang.Class.getConstructor0(Class.java:2706) > at java.lang.Class.getDeclaredConstructor(Class.java:1985) > at > org.apache.hadoop.util.ReflectionUtils.newInstance(ReflectionUtils.java:122) > ... 12 more > I have done small patch for > org.apache.hive.service.auth.CustomAuthenticationProviderImpl , that have > solved my problem, but I'm not sure if it's the best solution. Here is the > patch: > --- CustomAuthenticationProviderImpl.java 2013-06-20 14:55:22.473995184 > +0200 > +++ CustomAuthenticationProviderImpl.java.new 2013-06-20 14:57:36.549012966 > +0200 > @@ -33,7 +33,7 @@ > HiveConf conf = new HiveConf(); > this.customHandlerClass = (Class<? extends PasswdAuthenticationProvider>) > conf.getClass( > - > HiveConf.ConfVars.HIVE_SERVER2_CUSTOM_AUTHENTICATION_CLASS.name(), > + > HiveConf.ConfVars.HIVE_SERVER2_CUSTOM_AUTHENTICATION_CLASS.varname, > PasswdAuthenticationProvider.class); > this.customProvider = > ReflectionUtils.newInstance(this.customHandlerClass, conf); -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira