org.apache.avalon.excalibur.datasource.cluster
Interface IndexedDataSourceCluster
- All Superinterfaces:
- Component, Configurable, DataSourceComponent, ThreadSafe
- All Known Implementing Classes:
- DefaultIndexedDataSourceCluster
- public interface IndexedDataSourceCluster
- extends DataSourceComponent
- Since:
- 4.1
- Version:
- CVS $Revision: 1.6 $ $Date: 2003/05/20 20:44:43 $
- Author:
- Leif Mortenson
Field Summary |
static String |
ROLE
The name of the role for convenience |
ROLE
public static final String ROLE
- The name of the role for convenience
getClusterSize
public int getClusterSize()
- Returns the number of DataSources in the cluster.
- Returns:
- size of the cluster.
getConnectionForIndex
public Connection getConnectionForIndex(int index)
throws SQLException
- Gets a Connection to a database given an index.
- Parameters:
index
- Index of the DataSource for which a connection is to be returned.
- Throws:
NoValidConnectionException
- when there is no valid Connection wrapper
available in the classloader or when the index is not valid.
NoAvailableConnectionException
- when there are no more available
Connections in the pool.
SQLException
Copyright © 2000-2003 Apache Avalon Project. All Rights Reserved.