com.dynalivery.pcre
Class LoadBalancer

java.lang.Object
  |
  +--com.dynalivery.pcre.LoadBalancer

public class LoadBalancer
extends java.lang.Object


Field Summary
static int LOAD_FACTOR
           
static int MODIFIED_LOAD_FACTOR
           
static int ROUND_ROBIN
           
 
Constructor Summary
LoadBalancer()
          Thread safe constructor.
 
Method Summary
 PCREApplicationClient getConnectedClient()
          Returns a reference to a connected PCREApplicationClient object using the default load channel name "pcre_loadbalancer_p" the default load balancing algorithm of load-factor, the default medium priority,the default archiving option of false and the default idletimeout option of false.
 PCREApplicationClient getConnectedClient(int algorithm)
          Returns a reference to a connected PCREApplicationClient object using the default load channel name "pcre_loadbalancer_p" the supplied algorithm constant, the default medium priority,the default archiving option of false and the default idletimeout option of false.
 PCREApplicationClient getConnectedClient(java.lang.String chnlName)
          Returns a reference to a connected PCREApplicationClient object using the supplied channel name, default medium priority the default load balancing algorithm of load-factor the default archiving option of false and the default idletimeout option of false.
 PCREApplicationClient getConnectedClient(java.lang.String chnlName, int algorithm)
          Returns a reference to a connected PCREApplicationClient object using the supplied channel name and the supplied algorithm constant.
 PCREApplicationClient getConnectedClient(java.lang.String chnlName, int algorithm, int priority)
          Returns a reference to a connected PCREApplicationClient object using the supplied channel name, algorithm constant and priority.
 PCREApplicationClient getConnectedClient(java.lang.String channel, int algorithm, int priority, boolean archive, boolean idletimeout)
          Returns a reference to a connected PCREApplicationClient object using the supplied channel name, the supplied algorithm constant the supplied priority constant, ture if filereturn is to be archived false otherwise and true if idletimeout is to be disabled false otherwise.
 java.lang.String getReportServerName()
          Deprecated. As of Parallel Crystal 2.6, replaced by getConnectedClient()
 java.lang.String getReportServerName(int algorithm)
          Deprecated. As of Parallel Crystal 2.6, replaced by getConnectedClient(int)
 java.lang.String getReportServerName(java.lang.String chnlName)
          Deprecated. As of Parallel Crystal 2.6, replaced by getConnectedClient(String)
 java.lang.String getReportServerName(java.lang.String chnlName, int algorithm)
          Deprecated. As of Parallel Crystal 2.6, replaced by getConnectedClient(String, int)
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOAD_FACTOR

public static final int LOAD_FACTOR

ROUND_ROBIN

public static final int ROUND_ROBIN

MODIFIED_LOAD_FACTOR

public static final int MODIFIED_LOAD_FACTOR
Constructor Detail

LoadBalancer

public LoadBalancer()
Thread safe constructor.
Method Detail

getConnectedClient

public PCREApplicationClient getConnectedClient()
                                         throws PCREClientError
Returns a reference to a connected PCREApplicationClient object using the default load channel name "pcre_loadbalancer_p" the default load balancing algorithm of load-factor, the default medium priority,the default archiving option of false and the default idletimeout option of false. It is not necessary to call the connect method on the client object.

getConnectedClient

public PCREApplicationClient getConnectedClient(int algorithm)
                                         throws PCREClientError
Returns a reference to a connected PCREApplicationClient object using the default load channel name "pcre_loadbalancer_p" the supplied algorithm constant, the default medium priority,the default archiving option of false and the default idletimeout option of false. It is not necessary to call the connect method on the client object.

getConnectedClient

public PCREApplicationClient getConnectedClient(java.lang.String chnlName)
                                         throws PCREClientError
Returns a reference to a connected PCREApplicationClient object using the supplied channel name, default medium priority the default load balancing algorithm of load-factor the default archiving option of false and the default idletimeout option of false. It is not necessary to call the connect method on the client object.

getConnectedClient

public PCREApplicationClient getConnectedClient(java.lang.String chnlName,
                                                int algorithm)
                                         throws PCREClientError
Returns a reference to a connected PCREApplicationClient object using the supplied channel name and the supplied algorithm constant. Default priority is set to medium, the default archiving option is set to false and the default idletimeout option is set to false. It is not necessary to call the connect method on the client object.

getConnectedClient

public PCREApplicationClient getConnectedClient(java.lang.String chnlName,
                                                int algorithm,
                                                int priority)
                                         throws PCREClientError
Returns a reference to a connected PCREApplicationClient object using the supplied channel name, algorithm constant and priority. the default archiving option of false and the default idletimeout option of false. It is not necessary to call the connect method on the client object.

getConnectedClient

public PCREApplicationClient getConnectedClient(java.lang.String channel,
                                                int algorithm,
                                                int priority,
                                                boolean archive,
                                                boolean idletimeout)
                                         throws PCREClientError
Returns a reference to a connected PCREApplicationClient object using the supplied channel name, the supplied algorithm constant the supplied priority constant, ture if filereturn is to be archived false otherwise and true if idletimeout is to be disabled false otherwise. It is not necessary to call the connect method on the client object.

getReportServerName

public java.lang.String getReportServerName()
                                     throws PCREClientError
Deprecated. As of Parallel Crystal 2.6, replaced by getConnectedClient()

Returns the ip address of the report server to use using the default load channel name and the default load balancing algorithm of load-factor.

getReportServerName

public java.lang.String getReportServerName(int algorithm)
                                     throws PCREClientError
Deprecated. As of Parallel Crystal 2.6, replaced by getConnectedClient(int)

Returns the ip address of the report server to use using the default load channel name and the supplied load balancing algorithm (LoadBalancer constant).

getReportServerName

public java.lang.String getReportServerName(java.lang.String chnlName)
                                     throws PCREClientError
Deprecated. As of Parallel Crystal 2.6, replaced by getConnectedClient(String)

Returns the ip address of the report server to use using the supplied load channel name and the default load balancing algorithm of load-factor.

getReportServerName

public java.lang.String getReportServerName(java.lang.String chnlName,
                                            int algorithm)
                                     throws PCREClientError
Deprecated. As of Parallel Crystal 2.6, replaced by getConnectedClient(String, int)

Returns the ip address of the report server to use using the supplied load channel name and the supplied load balancing algorithm (LoadBalancer constant).