org.apache.hadoop.yarn.client
Class ConfiguredRMFailoverProxyProvider<T>

java.lang.Object
  extended by org.apache.hadoop.yarn.client.ConfiguredRMFailoverProxyProvider<T>
All Implemented Interfaces:
Closeable, org.apache.hadoop.io.retry.FailoverProxyProvider<T>, RMFailoverProxyProvider<T>

@InterfaceAudience.Private
@InterfaceStability.Unstable
public class ConfiguredRMFailoverProxyProvider<T>
extends Object
implements RMFailoverProxyProvider<T>


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.apache.hadoop.io.retry.FailoverProxyProvider
org.apache.hadoop.io.retry.FailoverProxyProvider.ProxyInfo<T>
 
Field Summary
protected  org.apache.hadoop.yarn.conf.YarnConfiguration conf
           
protected  String[] rmServiceIds
           
 
Constructor Summary
ConfiguredRMFailoverProxyProvider()
           
 
Method Summary
 void close()
          Close all the proxy objects which have been opened over the lifetime of this proxy provider.
 Class<T> getInterface()
           
 org.apache.hadoop.io.retry.FailoverProxyProvider.ProxyInfo<T> getProxy()
           
 void init(org.apache.hadoop.conf.Configuration configuration, RMProxy<T> rmProxy, Class<T> protocol)
          Initialize internal data structures, invoked right after instantiation.
 void performFailover(T currentProxy)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

conf

protected org.apache.hadoop.yarn.conf.YarnConfiguration conf

rmServiceIds

protected String[] rmServiceIds
Constructor Detail

ConfiguredRMFailoverProxyProvider

public ConfiguredRMFailoverProxyProvider()
Method Detail

init

public void init(org.apache.hadoop.conf.Configuration configuration,
                 RMProxy<T> rmProxy,
                 Class<T> protocol)
Description copied from interface: RMFailoverProxyProvider
Initialize internal data structures, invoked right after instantiation.

Specified by:
init in interface RMFailoverProxyProvider<T>
Parameters:
configuration - Configuration to use
rmProxy - The RMProxy instance to use
protocol - The communication protocol to use

getProxy

public org.apache.hadoop.io.retry.FailoverProxyProvider.ProxyInfo<T> getProxy()
Specified by:
getProxy in interface org.apache.hadoop.io.retry.FailoverProxyProvider<T>

performFailover

public void performFailover(T currentProxy)
Specified by:
performFailover in interface org.apache.hadoop.io.retry.FailoverProxyProvider<T>

getInterface

public Class<T> getInterface()
Specified by:
getInterface in interface org.apache.hadoop.io.retry.FailoverProxyProvider<T>

close

public void close()
           throws IOException
Close all the proxy objects which have been opened over the lifetime of this proxy provider.

Specified by:
close in interface Closeable
Throws:
IOException


Copyright © 2014 Apache Software Foundation. All Rights Reserved.