org.apache.hadoop.hbase.ipc
Class SecureRpcEngine

java.lang.Object
  extended by org.apache.hadoop.hbase.ipc.SecureRpcEngine

public class SecureRpcEngine
extends Object

A loadable RPC engine supporting SASL authentication of connections, using GSSAPI for Kerberos authentication or DIGEST-MD5 for authentication via signed tokens.

This is a fork of the org.apache.hadoop.ipc.WriteableRpcEngine from secure Hadoop, reworked to eliminate code duplication with the existing HBase WritableRpcEngine.

See Also:
SecureClient, SecureServer

Nested Class Summary
static class SecureRpcEngine.Server
          An RPC Server.
 
Field Summary
protected static org.apache.hadoop.hbase.ipc.SecureRpcEngine.ClientCache CLIENTS
           
protected static org.apache.commons.logging.Log LOG
           
 
Method Summary
 Object[] call(Method method, Object[][] params, InetSocketAddress[] addrs, Class<? extends VersionedProtocol> protocol, User ticket, org.apache.hadoop.conf.Configuration conf)
          Expert: Make multiple, parallel calls to a set of servers.
 VersionedProtocol getProxy(Class<? extends VersionedProtocol> protocol, long clientVersion, InetSocketAddress addr, User ticket, org.apache.hadoop.conf.Configuration conf, SocketFactory factory, int rpcTimeout)
          Construct a client-side proxy object that implements the named protocol, talking to a server at the named address.
 SecureRpcEngine.Server getServer(Class<? extends VersionedProtocol> protocol, Object instance, Class<?>[] ifaces, String bindAddress, int port, int numHandlers, int metaHandlerCount, boolean verbose, org.apache.hadoop.conf.Configuration conf, int highPriorityLevel)
          Construct a server for a protocol implementation instance listening on a port and address, with a secret manager.
protected static void log(String value)
           
 void stopProxy(VersionedProtocol proxy)
          Stop this proxy and release its invoker's resource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG

protected static final org.apache.commons.logging.Log LOG

CLIENTS

protected static final org.apache.hadoop.hbase.ipc.SecureRpcEngine.ClientCache CLIENTS
Method Detail

getProxy

public VersionedProtocol getProxy(Class<? extends VersionedProtocol> protocol,
                                  long clientVersion,
                                  InetSocketAddress addr,
                                  User ticket,
                                  org.apache.hadoop.conf.Configuration conf,
                                  SocketFactory factory,
                                  int rpcTimeout)
                           throws IOException
Construct a client-side proxy object that implements the named protocol, talking to a server at the named address.

Parameters:
protocol - interface
clientVersion - version we are expecting
addr - remote address
ticket - ticket
conf - configuration
factory - socket factory
Returns:
proxy
Throws:
IOException - e

stopProxy

public void stopProxy(VersionedProtocol proxy)
Stop this proxy and release its invoker's resource

Parameters:
proxy - the proxy to be stopped

call

public Object[] call(Method method,
                     Object[][] params,
                     InetSocketAddress[] addrs,
                     Class<? extends VersionedProtocol> protocol,
                     User ticket,
                     org.apache.hadoop.conf.Configuration conf)
              throws IOException,
                     InterruptedException
Expert: Make multiple, parallel calls to a set of servers.

Throws:
IOException
InterruptedException

getServer

public SecureRpcEngine.Server getServer(Class<? extends VersionedProtocol> protocol,
                                        Object instance,
                                        Class<?>[] ifaces,
                                        String bindAddress,
                                        int port,
                                        int numHandlers,
                                        int metaHandlerCount,
                                        boolean verbose,
                                        org.apache.hadoop.conf.Configuration conf,
                                        int highPriorityLevel)
                                 throws IOException
Construct a server for a protocol implementation instance listening on a port and address, with a secret manager.

Throws:
IOException

log

protected static void log(String value)


Copyright © 2012 The Apache Software Foundation. All Rights Reserved.