org.mortbay.jetty.plus
Class DefaultDataSourceService

java.lang.Object
  extended by org.mortbay.jetty.plus.AbstractService
      extended by org.mortbay.jetty.plus.AbstractDataSourceService
          extended by org.mortbay.jetty.plus.DefaultDataSourceService
All Implemented Interfaces:
Service, LifeCycle

public class DefaultDataSourceService
extends AbstractDataSourceService

DefaultDataSourceService An implementation of a DataSource Service using XAPool as the connection pooling implementation.

Author:
janb

Nested Class Summary
 
Nested classes/interfaces inherited from class org.mortbay.jetty.plus.AbstractDataSourceService
AbstractDataSourceService.DataSourceMap, AbstractDataSourceService.DataSourceObjectFactory
 
Field Summary
 
Fields inherited from class org.mortbay.jetty.plus.AbstractDataSourceService
dsMap
 
Fields inherited from class org.mortbay.jetty.plus.AbstractService
_jndi, _name, _started
 
Constructor Summary
DefaultDataSourceService()
           
 
Method Summary
 javax.sql.DataSource createPooledDataSource(java.lang.String jndiName, javax.sql.ConnectionPoolDataSource cpds)
          Configure a DataSource that is capable of pooling Connections.
 
Methods inherited from class org.mortbay.jetty.plus.AbstractDataSourceService
addConnectionPoolDataSource, addDataSource, getDataSource, getDataSourceReference, start
 
Methods inherited from class org.mortbay.jetty.plus.AbstractService
getJNDI, getName, isStarted, setJNDI, setName, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultDataSourceService

public DefaultDataSourceService()
Method Detail

createPooledDataSource

public javax.sql.DataSource createPooledDataSource(java.lang.String jndiName,
                                                   javax.sql.ConnectionPoolDataSource cpds)
                                            throws java.lang.Exception
Configure a DataSource that is capable of pooling Connections. This is accomplished by use of the XAPool connection pooling manager. To set up the pool configuration, call methods on the StandardPoolDataSource return object.

Specified by:
createPooledDataSource in class AbstractDataSourceService
Parameters:
jndiName - name of DataSource that client will lookup in java:comp/env
cpds - connection pool factory implementation
Returns:
StandardPoolDataSource instance that will be registered in java:comp/env
Throws:
java.lang.Exception


Copyright © 2004 Mortbay Consulting Pty. Ltd. All Rights Reserved.