@Override public void stop( StopContext context ) { ModeShapeEngine engine = getEngine(); if (engine != null) { try { // Undeploy the repository ... engine.undeploy(repositoryName()); } catch (NoSuchRepositoryException e) { // The repository doesn't exist, so no worries ... } } }
final String repoName = repository.getName(); try { final Future<Boolean> futureUndeployRepo = modeShapeEngine.undeploy(repoName); if (futureUndeployRepo.get()) { LOGGER.info("ModeShape repository {} has undeployed.", repoName);
} catch (Exception e) { undeploy(repositoryName); throw e;
} catch (Exception e) { undeploy(repositoryName); throw e;