#include <src/main/activemq/transport/failover/BackupTransportPool.h>
|
| | BackupTransportPool (FailoverTransport *parent, const Pointer< CompositeTaskRunner > taskRunner, const Pointer< CloseTransportsTask > closeTask, const Pointer< URIPool > uriPool, const Pointer< URIPool > updates, const Pointer< URIPool > priorityUriPool) |
| |
| | BackupTransportPool (FailoverTransport *parent, int backupPoolSize, const Pointer< CompositeTaskRunner > taskRunner, const Pointer< CloseTransportsTask > closeTask, const Pointer< URIPool > uriPool, const Pointer< URIPool > updates, const Pointer< URIPool > priorityUriPool) |
| |
| virtual | ~BackupTransportPool () |
| |
| void | close () |
| | Closes down the pool and destroys any Backups contained in the pool.
|
| |
| virtual bool | isPending () const |
| | Return true if we don't currently have enough Connected Transports.
|
| |
| Pointer< BackupTransport > | getBackup () |
| | Get a Connected Transport from the pool of Backups if any are present, otherwise it return a NULL Pointer.
|
| |
| virtual bool | iterate () |
| | Connect to a Backup Broker if we haven't already connected to the max number of Backups.
|
| |
| int | getBackupPoolSize () const |
| | Gets the Max number of Backups this Task will create.
|
| |
| void | setBackupPoolSize (int size) |
| | Sets the Max number of Backups this Task will create.
|
| |
| bool | isEnabled () const |
| | Gets if the backup Transport Pool has been enabled or not, when not enabled no backups are created and any that were are destroyed.
|
| |
| void | setEnabled (bool value) |
| | Sets if this Backup Transport Pool is enabled.
|
| |
| bool | isPriorityBackupAvailable () const |
| | Returns true if there is a Backup in the pool that's on the priority backups list.
|
| |
| virtual | ~CompositeTask () |
| |
| virtual bool | isPending () const =0 |
| | Indicates whether this task has any pending work that needs to be done, if not then it is skipped and the next Task in the CompositeTaskRunner's list of tasks is checked, if none of the tasks have any pending work to do, then the runner can go to sleep until it awakened by a call to wakeup.
|
| |
| virtual | ~Task () |
| |
| virtual bool | iterate ()=0 |
| | Perform one iteration of work, returns true if the task needs to run again to complete or false to indicate that the task is now complete.
|
| |
◆ BackupTransportPool() [1/2]
◆ BackupTransportPool() [2/2]
◆ ~BackupTransportPool()
| virtual activemq::transport::failover::BackupTransportPool::~BackupTransportPool |
( |
| ) |
|
|
virtual |
◆ close()
| void activemq::transport::failover::BackupTransportPool::close |
( |
| ) |
|
Closes down the pool and destroys any Backups contained in the pool.
◆ getBackup()
Get a Connected Transport from the pool of Backups if any are present, otherwise it return a NULL Pointer.
- Returns
- Pointer to a Connected Transport or NULL
◆ getBackupPoolSize()
| int activemq::transport::failover::BackupTransportPool::getBackupPoolSize |
( |
| ) |
const |
|
inline |
Gets the Max number of Backups this Task will create.
- Returns
- the max number of active BackupTransports that will be created.
◆ isEnabled()
| bool activemq::transport::failover::BackupTransportPool::isEnabled |
( |
| ) |
const |
|
inline |
Gets if the backup Transport Pool has been enabled or not, when not enabled no backups are created and any that were are destroyed.
- Returns
- true if enable.
◆ isPending()
| virtual bool activemq::transport::failover::BackupTransportPool::isPending |
( |
| ) |
const |
|
virtual |
◆ isPriorityBackupAvailable()
| bool activemq::transport::failover::BackupTransportPool::isPriorityBackupAvailable |
( |
| ) |
const |
Returns true if there is a Backup in the pool that's on the priority backups list.
- Returns
- true if there is a priority backup available.
◆ iterate()
| virtual bool activemq::transport::failover::BackupTransportPool::iterate |
( |
| ) |
|
|
virtual |
Connect to a Backup Broker if we haven't already connected to the max number of Backups.
Implements activemq::threads::Task.
◆ setBackupPoolSize()
| void activemq::transport::failover::BackupTransportPool::setBackupPoolSize |
( |
int |
size | ) |
|
|
inline |
Sets the Max number of Backups this Task will create.
- Parameters
-
| size | - the max number of active BackupTransports that will be created. |
◆ setEnabled()
| void activemq::transport::failover::BackupTransportPool::setEnabled |
( |
bool |
value | ) |
|
Sets if this Backup Transport Pool is enabled.
When not enabled no Backups are created and any that were are destroyed.
- Parameters
-
| value | - true to enable backup creation, false to disable. |
◆ BackupTransport
The documentation for this class was generated from the following file: