ResourceHandle resourceHandle = null;
ResourceSpec spec =
new ResourceSpec(JMS_RESOURCE_FACTORY,
ResourceSpec.JMS);
if (xaResource != null) {
logger.logp(Level.FINEST,
"BasicResourceAllocator", "createResource",
"NOT NULL", xaResource);
try {
resourceHandle = new ResourceHandle(
null, //no object present
spec,
this, null);
if (logger.isLoggable(Level.FINEST)) {
xaResource = new XAResourceWrapper(xaResource);
}
resourceHandle.fillInResourceObjects(null, xaResource);
} catch (Exception e) {
throw (PoolingException) (new PoolingException()).initCause(e);
}
} else {
logger.logp(Level.FINEST,
"BasicResourceAllocator", "createResource",
"NULL", xaResource);
}
return resourceHandle;