org.arch4j.messaging.websphere
Class J2EEContainerMessageQueueFacade
java.lang.Object
|
+--org.arch4j.messaging.MessageFacade
|
+--org.arch4j.messaging.MessageQueueFacade
|
+--org.arch4j.messaging.websphere.WebsphereMessageQueueFacade
|
+--org.arch4j.messaging.websphere.WebsphereMessageQueueFacadeWithCaching
|
+--org.arch4j.messaging.websphere.J2EEContainerMessageQueueFacade
- public class J2EEContainerMessageQueueFacade
- extends WebsphereMessageQueueFacadeWithCaching
- Author:
- roomej
Currently Websphere specific since we have not abstracted out how to get
the QCF.
A Message Queue Facade running in a J2EE container.
Is this case the container is going to pool connections and sessions,
so we will agressivly close them, so they can be resused in the pool.
Method Summary |
void |
close()
Since a provider typically allocates resources outside the JVM
on behalf of a Session , clients
should close them when they are not needed. |
javax.jms.QueueConnection |
getQueueConnection()
Returns a reference to the QueueConnection instance. |
javax.jms.QueueSession |
getQueueSession()
Returns a reference to the QueueSession instance associated
with this object. |
protected void |
initialize(boolean isTransactional)
Initialize the new instance. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
J2EEContainerMessageQueueFacade
public J2EEContainerMessageQueueFacade()
initialize
protected void initialize(boolean isTransactional)
- Description copied from class:
MessageQueueFacade
- Initialize the new instance. This method must be called by the
MessagingProvider
.
- Overrides:
initialize
in class MessageQueueFacade
getQueueConnection
public javax.jms.QueueConnection getQueueConnection()
- Description copied from class:
MessageQueueFacade
- Returns a reference to the
QueueConnection
instance.
- Overrides:
getQueueConnection
in class MessageQueueFacade
getQueueSession
public javax.jms.QueueSession getQueueSession()
- Description copied from class:
MessageQueueFacade
- Returns a reference to the
QueueSession
instance associated
with this object.
- Overrides:
getQueueSession
in class MessageQueueFacade
close
public void close()
- Description copied from class:
MessageQueueFacade
- Since a provider typically allocates resources outside the JVM
on behalf of a
Session
, clients
should close them when they are not needed. Relying on garbage collection
to eventually reclaim these resources may not be timely enough.
Note: Do not close the static queueConnection
here as
other Session
s may be relying on it.
- Overrides:
close
in class MessageQueueFacade
Copyright © 2000-2004 SpiderLogic, a service of Wipfli Ullrich Bertelson LLP.