org.apache.geronimo.connector.outbound
Class SinglePoolMatchAllConnectionInterceptor

java.lang.Object
  extended byorg.apache.geronimo.connector.outbound.SinglePoolMatchAllConnectionInterceptor
All Implemented Interfaces:
ConnectionInterceptor

public class SinglePoolMatchAllConnectionInterceptor
extends Object
implements ConnectionInterceptor

This pool is the most spec-compliant pool. It can be used by itself with no partitioning. It is apt to be the slowest pool. For each connection request, it synchronizes access to the pool and asks the ManagedConnectionFactory for a match from among all managed connections. If none is found, it may discard a random existing connection, and creates a new connection.

Version:
$Revision: 1.2 $ $Date: 2004/05/24 19:10:34 $

Constructor Summary
SinglePoolMatchAllConnectionInterceptor(ConnectionInterceptor next, int maxSize, int blockingTimeout)
           
 
Method Summary
 void getConnection(ConnectionInfo connectionInfo)
           
 void returnConnection(ConnectionInfo connectionInfo, ConnectionReturnAction connectionReturnAction)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SinglePoolMatchAllConnectionInterceptor

public SinglePoolMatchAllConnectionInterceptor(ConnectionInterceptor next,
                                               int maxSize,
                                               int blockingTimeout)
Method Detail

getConnection

public void getConnection(ConnectionInfo connectionInfo)
                   throws javax.resource.ResourceException
Specified by:
getConnection in interface ConnectionInterceptor
Throws:
javax.resource.ResourceException

returnConnection

public void returnConnection(ConnectionInfo connectionInfo,
                             ConnectionReturnAction connectionReturnAction)
Specified by:
returnConnection in interface ConnectionInterceptor


Copyright © 2003-2005 Apache Software Foundation. All Rights Reserved.