com.netflix.discovery.shared
Class EurekaJerseyClient

java.lang.Object
  extended by com.netflix.discovery.shared.EurekaJerseyClient

public final class EurekaJerseyClient
extends java.lang.Object

A wrapper for Jersey Apache Client to set the necessary configurations.


Nested Class Summary
static class EurekaJerseyClient.JerseyClient
           
 
Method Summary
static EurekaJerseyClient.JerseyClient createJerseyClient(java.lang.String clientName, int connectionTimeout, int readTimeout, int maxConnectionsPerHost, int maxTotalConnections, int connectionIdleTimeout)
          Creates a Jersey client with the given configuration parameters
static EurekaJerseyClient.JerseyClient createSSLJerseyClient(java.lang.String clientName, int connectionTimeout, int readTimeout, int maxConnectionsPerHost, int maxTotalConnections, int connectionIdleTimeout, java.lang.String trustStoreFileName, java.lang.String trustStorePassword)
          Creates the SSL based Jersey client with the given configuration parameters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

createJerseyClient

public static EurekaJerseyClient.JerseyClient createJerseyClient(java.lang.String clientName,
                                                                 int connectionTimeout,
                                                                 int readTimeout,
                                                                 int maxConnectionsPerHost,
                                                                 int maxTotalConnections,
                                                                 int connectionIdleTimeout)
Creates a Jersey client with the given configuration parameters

Parameters:
clientName -
connectionTimeout - - The connection timeout of the connection
readTimeout - - The read timeout of the connection
maxConnectionsPerHost - - The maximum number of connections to a particular host
maxTotalConnections - - The maximum number of total connections across all hosts
connectionIdleTimeout - - The idle timeout after which the connections will be cleaned up
Returns:
- The jersey client object encapsulating the connection

createSSLJerseyClient

public static EurekaJerseyClient.JerseyClient createSSLJerseyClient(java.lang.String clientName,
                                                                    int connectionTimeout,
                                                                    int readTimeout,
                                                                    int maxConnectionsPerHost,
                                                                    int maxTotalConnections,
                                                                    int connectionIdleTimeout,
                                                                    java.lang.String trustStoreFileName,
                                                                    java.lang.String trustStorePassword)
Creates the SSL based Jersey client with the given configuration parameters

Parameters:
clientName -
connectionTimeout - - The connection timeout of the connection
readTimeout - - The read timeout of the connection
maxConnectionsPerHost - - The maximum number of connections to a particular host
maxTotalConnections - - The maximum number of total connections across all hosts
connectionIdleTimeout - - The idle timeout after which the connections will be cleaned up
trustStoreFileName - - The full path to the trust store file
trustStorePassword - - The password of the trust store file
Returns:
- The jersey client object encapsulating the connection