Java Code Examples for org.apache.hadoop.security.authentication.server.AuthenticationHandler#init()
The following examples show how to use
org.apache.hadoop.security.authentication.server.AuthenticationHandler#init() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: LogsearchKrbFilter.java From ambari-logsearch with Apache License 2.0 | 5 votes |
private void initializeAuthHandler(String authHandlerClassName) throws ServletException { try { Class<?> klass = Thread.currentThread().getContextClassLoader().loadClass(authHandlerClassName); authHandler = (AuthenticationHandler) klass.newInstance(); authHandler.init(config); } catch (ClassNotFoundException | InstantiationException | IllegalAccessException ex) { throw new ServletException(ex); } }
Example 2
Source File: RangerKrbFilter.java From ranger with Apache License 2.0 | 5 votes |
protected void initializeAuthHandler(String authHandlerClassName, FilterConfig filterConfig) throws ServletException { try { Class<?> klass = Thread.currentThread().getContextClassLoader().loadClass(authHandlerClassName); authHandler = (AuthenticationHandler) klass.newInstance(); authHandler.init(config); } catch (ClassNotFoundException | InstantiationException | IllegalAccessException ex) { throw new ServletException(ex); } }