voldemort.server.protocol.hadoop
Class RestHadoopAuth

java.lang.Object
  extended by voldemort.common.service.AbstractService
      extended by voldemort.server.protocol.hadoop.RestHadoopAuth
All Implemented Interfaces:
VoldemortService

public class RestHadoopAuth
extends AbstractService


Field Summary
static java.lang.String KERBEROS_KDC_PROPERTY
           
static java.lang.String KERBEROS_REALM_PROPERTY
           
static java.lang.String SERVICE_NAME
           
 
Constructor Summary
RestHadoopAuth(java.lang.String kerberosRealm, java.lang.String kerberosKdc, java.lang.String kerberosPrincipal, java.lang.String kerberosKeytabPath)
           
 
Method Summary
static void loginSecuredHdfs()
          This method is a wrapper of RestAuthService.loginUserFromKeytab(), which is thread-safe and can be called multiple times, even after the session is already logged in.
static void logoutSecuredHdfs()
          This method is a wrapper of RestAuthService.logout(), which is NOT thread-safe and shall only be called when the voldemort server is shutting down, after all build-and-push jobs are terminated on the voldemort server.
protected  void startInner()
          Invoked when start() method is called.
protected  void stopInner()
          Invoked when stop() method is called.
 
Methods inherited from class voldemort.common.service.AbstractService
getType, isStarted, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SERVICE_NAME

public static java.lang.String SERVICE_NAME

KERBEROS_REALM_PROPERTY

public static java.lang.String KERBEROS_REALM_PROPERTY

KERBEROS_KDC_PROPERTY

public static java.lang.String KERBEROS_KDC_PROPERTY
Constructor Detail

RestHadoopAuth

public RestHadoopAuth(java.lang.String kerberosRealm,
                      java.lang.String kerberosKdc,
                      java.lang.String kerberosPrincipal,
                      java.lang.String kerberosKeytabPath)
Method Detail

startInner

protected void startInner()
Invoked when start() method is called.

Specified by:
startInner in class AbstractService

stopInner

protected void stopInner()
Invoked when stop() method is called.

Specified by:
stopInner in class AbstractService

loginSecuredHdfs

public static void loginSecuredHdfs()
                             throws com.linkedin.tusk.RestFSException
This method is a wrapper of RestAuthService.loginUserFromKeytab(), which is thread-safe and can be called multiple times, even after the session is already logged in. It is currently called once when a Voldemort server starts up all its services; and it is also called when starting each build-and-push job in case the last login wasn't successful.

Throws:
com.linkedin.tusk.RestFSException

logoutSecuredHdfs

public static void logoutSecuredHdfs()
                              throws com.linkedin.tusk.RestFSException
This method is a wrapper of RestAuthService.logout(), which is NOT thread-safe and shall only be called when the voldemort server is shutting down, after all build-and-push jobs are terminated on the voldemort server. It is currently called once when a Voldemort server stops all its services

Throws:
com.linkedin.tusk.RestFSException


Jay Kreps, Roshan Sumbaly, Alex Feinberg, Bhupesh Bansal, Lei Gao, Chinmay Soman, Vinoth Chandar, Zhongjie Wu