try {
rem = Naming.lookup(addr);
}
catch (RemoteException e) {
log.severe("Can't access callback address ='" + addr + "', no client rmi registry running");
throw new XmlBlasterException(glob, ErrorCode.RESOURCE_CONFIGURATION_ADDRESS, ME, "Can't access callback address ='" + addr + "', no client rmi registry running", e);
}
catch (NotBoundException e) {
log.severe("The given callback address ='" + addr + "' is not bound to rmi registry: " + e.toString());
throw new XmlBlasterException(glob, ErrorCode.RESOURCE_CONFIGURATION_ADDRESS, ME, "The given callback address '" + addr + "' is not bound to rmi registry", e);
}
catch (MalformedURLException e) {
log.severe("The given callback address ='" + addr + "' is invalid: " + e.toString());
throw new XmlBlasterException(glob, ErrorCode.RESOURCE_CONFIGURATION_ADDRESS, ME, "The given callback address '" + addr + "' is invalid.", e);
}
catch (Throwable e) {
log.severe("The given callback address ='" + addr + "' is invalid : " + e.toString());
throw new XmlBlasterException(glob, ErrorCode.RESOURCE_CONFIGURATION_ADDRESS, ME, "The given callback address '" + addr + "' is invalid.", e);
}
if (rem instanceof org.xmlBlaster.protocol.rmi.I_XmlBlasterCallback) {
cb = (I_XmlBlasterCallback)rem;
log.info("Accessing client callback reference using given '" + addr + "' string");
}
else {
throw new XmlBlasterException(glob, ErrorCode.RESOURCE_CONFIGURATION_ADDRESS, ME, "No callback to '" + addr + "' possible, class needs to implement interface I_XmlBlasterCallback.");
}
}