if (dest instanceof Queue) {
Queue queue = (Queue) dest;
QueueConnectionFactory qConFactory = null;
QueueConnection qConnection = null;
QueueSession qSession = null;
QueueBrowser qBrowser = null;
try {
qConFactory = (QueueConnectionFactory) kernel.invoke(
JCA_MANAGED_CONNECTION_FACTORY_NAME,
"$getResource");
qConnection = qConFactory.createQueueConnection();
qSession = qConnection.createQueueSession(false,
QueueSession.AUTO_ACKNOWLEDGE);
qBrowser = qSession.createBrowser(queue);
qConnection.start();
for (Enumeration e = qBrowser.getEnumeration(); e
.hasMoreElements();) {
Object o = e.nextElement();
ret.add(o);
}
qConnection.stop();
} catch (Exception e) {
log.error(e.getMessage(), e);
} finally {
try {
if (qBrowser != null) {
qBrowser.close();
}
} catch (JMSException ignore) {
}
try {
if (qSession != null) {