|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.messenger.DefaultServerSessionPool
public class DefaultServerSessionPool
DefaultServerSessionPool
is a default implementation of
the JMS ServerSessionPool interface.
Field Summary | |
---|---|
private java.util.LinkedList |
list
the list of ServerSession objects |
private javax.jms.MessageListener |
listener
The MessageListener which are fired by new JMS Sessions |
private SessionFactory |
sessionFactory
the factory used to create new Sessions |
private long |
timeout
maximum blocking time, just in case a notify goes walkies |
Constructor Summary | |
---|---|
DefaultServerSessionPool()
|
|
DefaultServerSessionPool(SessionFactory sessionFactory,
javax.jms.MessageListener listener,
int numberOfServerSessions)
|
Method Summary | |
---|---|
protected javax.jms.ServerSession |
createServerSession()
|
javax.jms.ServerSession |
getServerSession()
Return a server session from the pool. |
void |
putServerSession(javax.jms.ServerSession serverSession)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.util.LinkedList list
private SessionFactory sessionFactory
private javax.jms.MessageListener listener
private long timeout
Constructor Detail |
---|
public DefaultServerSessionPool()
public DefaultServerSessionPool(SessionFactory sessionFactory, javax.jms.MessageListener listener, int numberOfServerSessions) throws javax.jms.JMSException
javax.jms.JMSException
Method Detail |
---|
public javax.jms.ServerSession getServerSession() throws javax.jms.JMSException
getServerSession
in interface javax.jms.ServerSessionPool
javax.jms.JMSException
- if a JMS error occurs.public void putServerSession(javax.jms.ServerSession serverSession)
protected javax.jms.ServerSession createServerSession() throws javax.jms.JMSException
javax.jms.JMSException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |