IBM WebSphereTM eXtreme Scale, Release 8.6
API Specification

com.ibm.websphere.objectgrid.client
Interface ClientProperties


public interface ClientProperties

The set of properties used to define various preference for ObjectGrid clients.

See the package summary for details on how to use the ClientProperties class and properties file.

Since:
WAS XD 6.1.0.3, XC10

Field Summary
static String CLIENT_PROPS_FILE_PATH_KEY
          The system property key to override the location of the client properties file.
static String DEFAULTCLIENTPROPERTYFILE
          The default name of client property file
static String PROP_LISTENER_HOST
          Listener host property key for the client properties file.
static String PROP_LISTENER_PORT
          Listener port property key for the client properties file.
static String PROP_PREFER_LOCAL_HOST
          Currently, this property is not used.
static String PROP_PREFER_LOCAL_PROCESS
          Currently, this property is not used.
static String PROP_PREFER_ZONES
          Prefer zones property key for the client properties file.
static String PROP_REQUEST_RETRY_TIMEOUT
          The requestRetryTimeout which indicates how long to retry a request (in milliseconds).
static String PROP_SHUFFLE_BOOTSTRAP_ADDRESSES
          The shuffleBoostrapAddresses property is used to determine if the catalog service grid addresses should be randomized when used by a client when bootstrapping to the grid.
 
Method Summary
 String getListenerHost()
          Retrieves the host to be used by the ORB.
 int getListenerPort()
          Retrieves the port to be used by the ORB.
 String[] getPreferZones()
          Retrieve the preferred zones.
 long getRequestRetryTimeout()
          Retrieves the current request retry timeout.
 boolean isBootStrapListShuffled()
          Retrieves the value of the BootStrapListShuffled property.
 boolean isPreferLocalHost()
          This method is reserved for future use.
 boolean isPreferLocalProcess()
          This method is reserved for future use.
 void setBootStrapListShuffled(boolean shuffle)
          Sets the value of the BootStrapListShuffled property.
 void setPreferLocalHost(boolean localHost)
          This method is reserved for future use.
 void setPreferLocalProcess(boolean localProcess)
          This method is reserved for future use.
 void setPreferZones(String[] zones)
          Prefer routing to specific zones.
 void setRequestRetryTimeout(long requestRetryTimeout)
          Set the request retry timeout to indicate how long to retry a request (in milliseconds) when recoverable failures occur, such as fail-over exceptions.
 

Field Detail

DEFAULTCLIENTPROPERTYFILE

static final String DEFAULTCLIENTPROPERTYFILE
The default name of client property file

See Also:
Constant Field Values

CLIENT_PROPS_FILE_PATH_KEY

static final String CLIENT_PROPS_FILE_PATH_KEY
The system property key to override the location of the client properties file.

Since:
7.0
See Also:
Constant Field Values

PROP_PREFER_LOCAL_PROCESS

static final String PROP_PREFER_LOCAL_PROCESS
Currently, this property is not used. It is reserved for future use.

See Also:
setPreferLocalProcess(boolean), Constant Field Values

PROP_PREFER_LOCAL_HOST

static final String PROP_PREFER_LOCAL_HOST
Currently, this property is not used. It is reserved for future use.

See Also:
setPreferLocalHost(boolean), Constant Field Values

PROP_PREFER_ZONES

static final String PROP_PREFER_ZONES
Prefer zones property key for the client properties file. Each specified zone is separated by a comma in the form: preferZones=ZoneA,ZoneB,ZoneC

See Also:
setPreferZones(String[]), Constant Field Values

PROP_REQUEST_RETRY_TIMEOUT

static final String PROP_REQUEST_RETRY_TIMEOUT
The requestRetryTimeout which indicates how long to retry a request (in milliseconds). A 0 indicates that the request should fail fast and skip over in internal retry logic. Exceptions that cannot succeed even if tried again such as DuplicateException will be returned immediately.

Since:
7.0
See Also:
setRequestRetryTimeout(long), Constant Field Values

PROP_LISTENER_HOST

static final String PROP_LISTENER_HOST
Listener host property key for the client properties file.

Since:
XS 7.1
See Also:
getListenerHost(), Constant Field Values

PROP_LISTENER_PORT

static final String PROP_LISTENER_PORT
Listener port property key for the client properties file.

Since:
XS 7.1
See Also:
getListenerPort(), Constant Field Values

PROP_SHUFFLE_BOOTSTRAP_ADDRESSES

static final String PROP_SHUFFLE_BOOTSTRAP_ADDRESSES
The shuffleBoostrapAddresses property is used to determine if the catalog service grid addresses should be randomized when used by a client when bootstrapping to the grid. The default value of the property is true.

Since:
7.1.0.3
See Also:
Constant Field Values
Method Detail

setPreferZones

void setPreferZones(String[] zones)
Prefer routing to specific zones.

When zones are enabled on an ObjectGrid, requests will be routed to the specified zones.

Parameters:
zones - array of zone names. If null or an empty array, then requests are routed to all zones.

setPreferLocalProcess

void setPreferLocalProcess(boolean localProcess)
This method is reserved for future use. Calls to the method will not result in any performed operation.

Parameters:
localProcess -

setPreferLocalHost

void setPreferLocalHost(boolean localHost)
This method is reserved for future use. Calls to the method will not result in any performed operation.

Parameters:
localHost -

getPreferZones

String[] getPreferZones()
Retrieve the preferred zones.

Returns:
the preferred zones.

isPreferLocalProcess

boolean isPreferLocalProcess()
This method is reserved for future use. The returned value should be ignored by the user.

Returns:
false

isPreferLocalHost

boolean isPreferLocalHost()
This method is reserved for future use. The returned value should be ignored by the user.

Returns:
false

setRequestRetryTimeout

void setRequestRetryTimeout(long requestRetryTimeout)
Set the request retry timeout to indicate how long to retry a request (in milliseconds) when recoverable failures occur, such as fail-over exceptions. A request will timeout when either the request timeout expires or the transaction timeout expires, whichever expires first.

A value of 0 indicates that all requests should fail immediately and avoid any retry logic. Exceptions that cannot succeed even if tried again such as DuplicateKeyException exceptions will be thrown immediately.

A value of -1 indicates that the request retry timeout is not set, meaning that the request duration is governed by the transaction timeout.

The request retry timeout can be overridden using the Session.setRequestRetryTimeout(long) method.

Parameters:
requestRetryTimeout - the duration in milliseconds retry a client request, 0 if the request should fail immediately or -1 if the request timeout is not set.
Since:
7.0
See Also:
Session.setRequestRetryTimeout(long), ObjectGrid.setTxTimeout(int)

getRequestRetryTimeout

long getRequestRetryTimeout()
Retrieves the current request retry timeout. Returns -1 if it was not set.

Returns:
requestRetryTimeout in milliseconds, 0 to fail immediately or -1 if not set.
Since:
7.0

getListenerHost

String getListenerHost()
Retrieves the host to be used by the ORB. The listener host property defaults to 'localhost'. This property can only be set in the client.properties file.

Returns:
The host that the ORB will bind to.
Since:
7.1

getListenerPort

int getListenerPort()
Retrieves the port to be used by the ORB. The listener port property defaults to the corbaloc port, 2809. This property can only be set in the client.properties file.

Returns:
The port that the ORB will bind to.
Since:
7.1

isBootStrapListShuffled

boolean isBootStrapListShuffled()
Retrieves the value of the BootStrapListShuffled property.

Returns:
true if the value of BootStrapListeShuffled was set to true. false if the value of BootStrapListeShuffled was set to false.
Since:
7.1.0.3

setBootStrapListShuffled

void setBootStrapListShuffled(boolean shuffle)
Sets the value of the BootStrapListShuffled property.

Parameters:
shuffle - true the bootstrap list will be shuffled providing each client a random distribution of catalog servers to select from. false the first viable address in the list of catalog servers will be used.
Since:
7.1.0.3

IBM WebSphereTM eXtreme Scale, Release 8.6
API Specification

© Copyright International Business Machines Corp 2005,2012. All rights reserved.