FileDocCategorySizeDatePackage
JamesConnectionManager.javaAPI DocApache James 2.3.14692Fri Jan 12 12:56:26 GMT 2007org.apache.james.services

JamesConnectionManager

public interface JamesConnectionManager implements org.apache.avalon.cornerstone.services.connection.ConnectionManager
This interface extends the standard ConnectionManager interface to allow connectionLimits to be specified on a per service basis

Fields Summary
String
ROLE
The component role used by components implementing this service
Constructors Summary
Methods Summary
public voidconnect(java.lang.String name, java.net.ServerSocket socket, org.apache.avalon.cornerstone.services.connection.ConnectionHandlerFactory handlerFactory, org.apache.excalibur.thread.ThreadPool threadPool, int maxOpenConnections)
Start managing a connection. Management involves accepting connections and farming them out to threads from pool to be handled.

param
name the name of connection
param
socket the ServerSocket from which to
param
handlerFactory the factory from which to acquire handlers
param
threadPool the thread pool to use
param
maxOpenConnections the maximum number of open connections allowed for this server socket.
exception
Exception if an error occurs

public voidconnect(java.lang.String name, java.net.ServerSocket socket, org.apache.avalon.cornerstone.services.connection.ConnectionHandlerFactory handlerFactory, int maxOpenConnections)
Start managing a connection. This is similar to other connect method except that it uses default thread pool.

param
name the name of connection
param
socket the ServerSocket from which to
param
handlerFactory the factory from which to acquire handlers
param
maxOpenConnections the maximum number of open connections allowed for this server socket.
exception
Exception if an error occurs

public voidconnect(java.lang.String name, java.net.ServerSocket socket, org.apache.avalon.cornerstone.services.connection.ConnectionHandlerFactory handlerFactory, org.apache.excalibur.thread.ThreadPool threadPool)
Start managing a connection. Management involves accepting connections and farming them out to threads from pool to be handled.

param
name the name of connection
param
socket the ServerSocket from which to
param
handlerFactory the factory from which to acquire handlers
param
threadPool the thread pool to use
exception
Exception if an error occurs

public voidconnect(java.lang.String name, java.net.ServerSocket socket, org.apache.avalon.cornerstone.services.connection.ConnectionHandlerFactory handlerFactory)
Start managing a connection. Management involves accepting connections and farming them out to threads from pool to be handled.

param
name the name of connection
param
socket the ServerSocket from which to
param
handlerFactory the factory from which to acquire handlers
exception
Exception if an error occurs

public intgetMaximumNumberOfOpenConnections()
Returns the default maximum number of open connections supported by this SimpleConnectionManager

return
the maximum number of connections