class UpgradeTask implements MaintenanceTaskProcess {

    public Supplier<Boolean> condition() {
        final Supplier<Boolean> needUpgradeCondition = () -> upgradeService.needUpgrade();
        final Supplier<Boolean> hasRepositoryConfiguration = forAll.condition().operational(repository);
        return () -> needUpgradeCondition.get() && hasRepositoryConfiguration.get();
    }

}