@Override public boolean repositoryActive(String repositoryName) throws RepositoryNotFoundException { RepositoryDefinition repoDef = repos.get(repositoryName); if (repoDef == null) { throw new RepositoryNotFoundException("No repository named " + repositoryName); } return repoDef.getLifecycleState() == RepositoryLifecycleState.ACTIVE; }
@Override public boolean repositoryExistsAndActive(String repositoryName) { RepositoryDefinition repoDef = repos.get(repositoryName); return repoDef != null && repoDef.getLifecycleState() == RepositoryLifecycleState.ACTIVE; }