| org.continuent.sequoia.controller.loadbalancer.raidb2.RAIDb2 org.continuent.sequoia.controller.loadbalancer.raidb2.RAIDb2_WRR
RAIDb2_WRR | public class RAIDb2_WRR extends RAIDb2 (Code) | | RAIDb-2 Weighted Round Robin load balancer.
The read requests coming from the request manager are sent to the backend
nodes using a weighted round robin. Write requests are broadcasted to all
backends.
The weighted round-robin works as follows. If the backend weight is set to 0,
no read requests are sent to this backend unless it is the last one available
on this controller. The load balancer maintains a current weight that is
increased by one each time a new read request is executed.
If backend1 has a weight of 5 and backend2 a weight of 10, backend1 will
receive the 5 first requests and backend2 the next 10 requests. Then we
restart with backend1. Be careful that large weight values will heavily load
backends in turn but will probably not balance the load in an effective way.
author: Emmanuel Cecchet author: Julie Marguerite version: 1.0 |
RAIDb2_WRR | public RAIDb2_WRR(VirtualDatabase vdb, WaitForCompletionPolicy waitForCompletionPolicy, CreateTablePolicy createTablePolicy) throws Exception(Code) | | Creates a new RAIDb-2 Weighted Round Robin request load balancer.
Parameters: vdb - The virtual database this load balancer belongs to. Parameters: waitForCompletionPolicy - How many backends must complete beforereturning the result? Parameters: createTablePolicy - The policy defining how 'create table' statementsshould be handled exception: Exception - if an error occurs |
getInformation | public String getInformation()(Code) | | Gets information about the request load balancer.
String containing information |
Methods inherited from org.continuent.sequoia.controller.loadbalancer.raidb2.RAIDb2 | public void abort(TransactionMetaData tm) throws SQLException(Code)(Java Doc) final public void begin(TransactionMetaData tm) throws SQLException(Code)(Java Doc) public ExecuteResult callableStatementExecute(StoredProcedure proc, MetadataCache metadataCache) throws SQLException, AllBackendsFailedException(Code)(Java Doc) public ControllerResultSet callableStatementExecuteQuery(StoredProcedure proc, MetadataCache metadataCache) throws SQLException, AllBackendsFailedException(Code)(Java Doc) public ExecuteUpdateResult callableStatementExecuteUpdate(StoredProcedure proc) throws SQLException, AllBackendsFailedException(Code)(Java Doc) public void closePersistentConnection(String login, long persistentConnectionId) throws SQLException(Code)(Java Doc) public void commit(TransactionMetaData tm) throws SQLException(Code)(Java Doc) public void disableBackend(DatabaseBackend db, boolean forceDisable) throws SQLException(Code)(Java Doc) public synchronized void enableBackend(DatabaseBackend db, boolean writeEnabled) throws SQLException(Code)(Java Doc) protected ControllerResultSet executeReadRequestOnBackend(SelectRequest request, DatabaseBackend backend, MetadataCache metadataCache) throws SQLException, UnreachableBackendException(Code)(Java Doc) protected Object executeStoredProcedureOnBackend(StoredProcedure proc, boolean isExecuteQuery, DatabaseBackend backend, MetadataCache metadataCache) throws SQLException, UnreachableBackendException(Code)(Java Doc) public ControllerResultSet getPreparedStatementGetMetaData(AbstractRequest request) throws SQLException(Code)(Java Doc) abstract public String getRaidb2Xml()(Code)(Java Doc) public String getXmlImpl()(Code)(Java Doc) public void openPersistentConnection(String login, long persistentConnectionId) throws SQLException(Code)(Java Doc) public void releaseSavepoint(TransactionMetaData tm, String savepointName) throws SQLException(Code)(Java Doc) public void rollback(TransactionMetaData tm) throws SQLException(Code)(Java Doc) public void rollbackToSavepoint(TransactionMetaData tm, String savepointName) throws SQLException(Code)(Java Doc) public void setSavepoint(TransactionMetaData tm, String savepointName) throws SQLException(Code)(Java Doc) public ExecuteResult statementExecute(AbstractRequest request, MetadataCache metadataCache) throws SQLException, AllBackendsFailedException(Code)(Java Doc) abstract public ControllerResultSet statementExecuteQuery(SelectRequest request, MetadataCache metadataCache) throws SQLException(Code)(Java Doc) public ExecuteUpdateResult statementExecuteUpdate(AbstractWriteRequest request) throws AllBackendsFailedException, SQLException(Code)(Java Doc) public GeneratedKeysResult statementExecuteUpdateWithKeys(AbstractWriteRequest request, MetadataCache metadataCache) throws AllBackendsFailedException, SQLException(Code)(Java Doc)
|
|
|