|
GemFire 6.6.3 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface Gateway
A Gateway represents a local proxy for a remote
WAN (or distributed system).
| Nested Class Summary | |
|---|---|
static interface |
Gateway.Endpoint
An Endpoint represents a proxy to a remote host |
static class |
Gateway.OrderPolicy
The order policy. |
| Field Summary | |
|---|---|
static int |
DEFAULT_CONCURRENCY_LEVEL
The default number of parallel threads dispatching events from one member. |
static int |
DEFAULT_SOCKET_BUFFER_SIZE
The default buffer size for socket buffers from a sending Gateway to its receiving Gateway. |
static int |
DEFAULT_SOCKET_READ_TIMEOUT
The default amount of time in milliseconds that a socket read between a sending Gateway and its receiving Gateway will
block. |
static String |
STARTUP_POLICY_PRIMARY
The 'primary' startup policy. |
| Method Summary | |
|---|---|
void |
addEndpoint(String id,
String host,
int port)
Add an Endpoint to this Gateway. |
void |
addListener(GatewayEventListener listener)
Add a GatewayEventListener to this Gateway. |
int |
getConcurrencyLevel()
Returns the concurrency level (number of parallel threads) processing GatewayEvents |
boolean |
getEarlyAck()
Deprecated. EarlyAck communication is unsafe and no longer supported |
List |
getEndpoints()
Returns the list of Endpoints |
String |
getGatewayHubId()
Returns this Gateway's GatewayHub identifier. |
String |
getId()
Returns this Gateway's identifier. |
List<GatewayEventListener> |
getListeners()
Returns the list of GatewayEventListeners |
Gateway.OrderPolicy |
getOrderPolicy()
Returns the OrderPolicy for this Gateway. |
GatewayQueueAttributes |
getQueueAttributes()
Returns the GatewayQueueAttributess for this Gateway |
int |
getQueueSize()
Returns the number of entries in this Gateway's queue. |
int |
getSocketBufferSize()
Returns the configured buffer size of the socket connection between this Gateway and its receiving Gateway. |
int |
getSocketReadTimeout()
Optional operation. |
boolean |
hasEndpoints()
Returns whether this Gateway has Endpoints |
boolean |
hasListeners()
Returns whether this Gateway has GatewayEventListeners |
boolean |
isConnected()
Returns whether or not this Gateway is connected to its
remote Gateway. |
boolean |
isPaused()
Returns whether or not this Gateway is running. |
boolean |
isRunning()
Returns whether or not this Gateway is running |
void |
pause()
Pauses this Gateway. |
void |
resume()
Resumes this paused Gateway. |
void |
setEarlyAck(boolean earlyAck)
Deprecated. EarlyAck communication is unsafe and no longer supported |
void |
setOrderPolicy(Gateway.OrderPolicy orderPolicy)
Sets the OrderPolicy for this Gateway. |
void |
setQueueAttributes(GatewayQueueAttributes queueAttributes)
Sets the GatewayQueueAttributess for this
Gateway. |
void |
setSocketBufferSize(int socketBufferSize)
Sets the buffer size in bytes of the socket connection between this Gateway and its receiving Gateway. |
void |
setSocketReadTimeout(int socketReadTimeout)
Optional operation. |
void |
start()
Starts this Gateway. |
void |
stop()
Stops this Gateway. |
| Field Detail |
|---|
static final int DEFAULT_SOCKET_BUFFER_SIZE
Gateway to its receiving Gateway.
static final int DEFAULT_SOCKET_READ_TIMEOUT
Gateway and its receiving Gateway will
block.
static final int DEFAULT_CONCURRENCY_LEVEL
static final String STARTUP_POLICY_PRIMARY
GatewayHub. If it can become the primary
GatewayHub, it will. If not, then it will log a warning
and become a secondary GatewayHub.
| Method Detail |
|---|
String getGatewayHubId()
Gateway's GatewayHub identifier.
Gateway's GatewayHub identifier.String getId()
Gateway's identifier.
Gateway's identifier.
void addEndpoint(String id,
String host,
int port)
throws GatewayException
Endpoint to this Gateway.
id - The id of the endpointhost - The host of the endpointport - The port that the endpoint is listening on
GatewayException - if this Gateway already defines
an Endpoint with this idList getEndpoints()
Endpoints
Endpointsboolean hasEndpoints()
Gateway has Endpoints
Gateway has Endpoints
void addListener(GatewayEventListener listener)
throws GatewayException
GatewayEventListener to this Gateway.
listener - The GatewayEventListener to add
GatewayException - if this Gateway already defines
any EndpointsList<GatewayEventListener> getListeners()
GatewayEventListeners
GatewayEventListenersboolean hasListeners()
Gateway has GatewayEventListeners
Gateway has GatewayEventListeners@Deprecated void setEarlyAck(boolean earlyAck)
Gateway's
queue.
earlyAck - Whether or not to enable early acknowledgement for
batches sent from this Gateway to its corresponding
Gateway.
UnsupportedOperationException - because of deprecation@Deprecated boolean getEarlyAck()
Gateway's
queue.
Gateway to its corresponding Gateway.void setSocketBufferSize(int socketBufferSize)
Gateway and its receiving Gateway. The
default is 32768 bytes.
socketBufferSize - The size in bytes of the socket bufferint getSocketBufferSize()
Gateway and its receiving Gateway. The default
is 32768 bytes.
Gateway and its receiving Gatewayvoid setSocketReadTimeout(int socketReadTimeout)
Gateway and its receiving Gateway will
block. The default is 10000 seconds.
socketReadTimeout - The amount of time to blockint getSocketReadTimeout()
Gateway and its receiving Gateway will
block. The default is 10000 seconds.
Gateway and its receiving Gateway will
blockvoid setQueueAttributes(GatewayQueueAttributes queueAttributes)
GatewayQueueAttributess for this
Gateway. Calling setQueueAttributes on a stopped
Gateway will destroy the existing queue and create a new
empty queue.
queueAttributes - The GatewayQueueAttributes to useGatewayQueueAttributes getQueueAttributes()
GatewayQueueAttributess for this Gateway
GatewayQueueAttributess for this Gateway
void start()
throws IOException
Gateway. Once the hub is running, its
configuration cannot be changed.
IOException - If an error occurs while starting the Gatewayboolean isRunning()
Gateway is running
void stop()
Gateway. Note that the
Gateway can be reconfigured and restarted if
desired.
boolean isConnected()
Gateway is connected to its
remote Gateway.
int getQueueSize()
Gateway's queue.
Gateway's queuevoid pause()
Gateway.
void resume()
Gateway.
boolean isPaused()
Gateway is running.
int getConcurrencyLevel()
GatewayEvents
GatewayEventsDEFAULT_CONCURRENCY_LEVELvoid setOrderPolicy(Gateway.OrderPolicy orderPolicy)
OrderPolicy for this Gateway.
orderPolicy - the OrderPolicy for this GatewayGateway.OrderPolicy getOrderPolicy()
OrderPolicy for this Gateway.
OrderPolicy for this Gateway
|
GemFire 6.6.3 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||