com.netflix.loadbalancer
Class AbstractServerList<T extends Server>

java.lang.Object
  extended by com.netflix.loadbalancer.AbstractServerList<T>
All Implemented Interfaces:
com.netflix.client.IClientConfigAware, ServerList<T>
Direct Known Subclasses:
ConfigurationBasedServerList

public abstract class AbstractServerList<T extends Server>
extends java.lang.Object
implements ServerList<T>, com.netflix.client.IClientConfigAware

The class includes an API to create a filter to be use by load balancer to filter the servers returned from ServerList.getUpdatedListOfServers() or ServerList.getInitialListOfServers().


Constructor Summary
AbstractServerList()
           
 
Method Summary
 AbstractServerListFilter<T> getFilterImpl(com.netflix.client.config.IClientConfig niwsClientConfig)
          Get a ServerListFilter instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.netflix.loadbalancer.ServerList
getInitialListOfServers, getUpdatedListOfServers
 
Methods inherited from interface com.netflix.client.IClientConfigAware
initWithNiwsConfig
 

Constructor Detail

AbstractServerList

public AbstractServerList()
Method Detail

getFilterImpl

public AbstractServerListFilter<T> getFilterImpl(com.netflix.client.config.IClientConfig niwsClientConfig)
                                                         throws com.netflix.client.ClientException
Get a ServerListFilter instance. It uses ClientFactory.instantiateInstanceWithClientConfig(String, IClientConfig) which in turn uses reflection to initialize the filter instance. The filter class name is determined by the value of CommonClientConfigKey.NIWSServerListFilterClassName in the IClientConfig. The default implementation is ZoneAffinityServerListFilter.

Throws:
com.netflix.client.ClientException