@Override @Transactional public void removeAlias(Application application, String alias) throws ServiceException, CheckException { try { hipacheRedisUtils.removeAlias(alias); boolean removed = application.getAliases().remove(alias); if (!removed) { throw new CheckException("Alias [" + alias + "] doesn't exist"); } application = applicationDAO.save(application); } catch (DataAccessException e) { throw new ServiceException(e.getLocalizedMessage(), e); } }