public synchronized void undeployResource(Object resource)
throws Exception {
NamingManager namingMgr = Switch.getSwitch().getNamingManager();
PersistenceManagerFactoryResource configPMFRes =
(PersistenceManagerFactoryResource)resource;
namingMgr.unpublishObject(configPMFRes.getJndiName());
ResourceInstaller installer = Switch.getSwitch().getResourceInstaller();
installer.removeResource(
IASJ2EEResourceFactoryImpl.toPMFJ2EEResource(configPMFRes));
}