public class ConnectionPool
extends java.lang.Object
Constructor and Description |
---|
ConnectionPool(ActiveMQConnection connection) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
javax.jms.Session |
createSession(boolean transacted,
int ackMode) |
void |
decrementReferenceCount() |
boolean |
expiredCheck()
Determines if this Connection has expired.
|
ActiveMQConnection |
getConnection() |
long |
getExpiryTimeout() |
int |
getIdleTimeout() |
int |
getMaximumActiveSessionPerConnection() |
int |
getNumActiveSessions() |
int |
getNumIdleSessions() |
int |
getNumSessions() |
void |
incrementReferenceCount() |
boolean |
isBlockIfSessionPoolIsFull() |
void |
setBlockIfSessionPoolIsFull(boolean block)
Configure whether the createSession method should block when there are no more idle sessions and the
pool already contains the maximum number of active sessions.
|
void |
setExpiryTimeout(long expiryTimeout) |
void |
setIdleTimeout(int idleTimeout) |
void |
setMaximumActiveSessionPerConnection(int maximumActiveSessionPerConnection) |
void |
start() |
java.lang.String |
toString() |
public ConnectionPool(ActiveMQConnection connection)
public void start() throws javax.jms.JMSException
javax.jms.JMSException
public ActiveMQConnection getConnection()
public javax.jms.Session createSession(boolean transacted, int ackMode) throws javax.jms.JMSException
javax.jms.JMSException
public void close()
public void incrementReferenceCount()
public void decrementReferenceCount()
public boolean expiredCheck()
public int getIdleTimeout()
public void setIdleTimeout(int idleTimeout)
public void setExpiryTimeout(long expiryTimeout)
public long getExpiryTimeout()
public int getMaximumActiveSessionPerConnection()
public void setMaximumActiveSessionPerConnection(int maximumActiveSessionPerConnection)
public int getNumSessions()
public int getNumIdleSessions()
public int getNumActiveSessions()
public void setBlockIfSessionPoolIsFull(boolean block)
block
- Indicates whether blocking should be used to wait for more space to create a session.public boolean isBlockIfSessionPoolIsFull()
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2005-2013 Red Hat, Inc.. All Rights Reserved.