Source:
<code>private boolean fetchRegistry(boolean forceFullRegistryFetch) { ClientResponse response = null; Stopwatch tracer = FETCH_REGISTRY_TIMER.start(); try { Applications applications = getApplications(); if (clientConfig.shouldDisableDelta() || forceFullRegistryFetch || (applications == null) || (applications.getRegisteredApplications().size() == 0) || (applications.getVersion() == -1)) { logger.info("Disable delta property : {}", clientConfig.shouldDisableDelta()); logger.info("Force full registry fetch : {}", forceFullRegistryFetch); logger.info("Application is null : {}", (applications == null)); logger.info("Registered Applications size is zero : {}", (applications.getRegisteredApplications().size() == 0)); logger.info("Application version is -1: {}", (applications.getVersion() == -1)); response = getAndStoreFullRegistry(); } else { Applications delta = null; response = makeRemoteCall(Action.Refresh_Delta); if (response.getStatus() == Status.OK.getStatusCode()) { delta = response.getEntity(Applications.class); } if (delta == null) { logger.warn("The server does not allow the delta revision to be applied because it is not safe. Hence got the full registry."); this.closeResponse(response); response = getAndStoreFullRegistry(); } else { updateDelta(delta); String reconcileHashCode = getReconcileHashCode(applications); if ((!reconcileHashCode.equals(delta.getAppsHashCode())) || clientConfig.shouldLogDeltaDiff()) { response = reconcileAndLogDifference(response, delta, reconcileHashCode); } } logTotalInstances(); } logger.debug(PREFIX + appPathIdentifier + " - refresh status: " + response.getStatus()); } catch (Throwable e) { logger.error( PREFIX + appPathIdentifier + " - was unable to refresh it's cache! status = " + e.getMessage(), e); return false; } finally { if (tracer != null) { tracer.stop(); } closeResponse(response); <START> notifyRefreshCallbacks(); <END> } return true; }</code><technical_language>this success</technical_language>

Target:
private boolean fetchRegistry(boolean forceFullRegistryFetch) { ClientResponse response = null; Stopwatch tracer = FETCH_REGISTRY_TIMER.start(); try { Applications applications = getApplications(); if (clientConfig.shouldDisableDelta() || forceFullRegistryFetch || (applications == null) || (applications.getRegisteredApplications().size() == 0) || (applications.getVersion() == -1)) { logger.info("Disable delta property : {}", clientConfig.shouldDisableDelta()); logger.info("Force full registry fetch : {}", forceFullRegistryFetch); logger.info("Application is null : {}", (applications == null)); logger.info("Registered Applications size is zero : {}", (applications.getRegisteredApplications().size() == 0)); logger.info("Application version is -1: {}", (applications.getVersion() == -1)); response = getAndStoreFullRegistry(); } else { Applications delta = null; response = makeRemoteCall(Action.Refresh_Delta); if (response.getStatus() == Status.OK.getStatusCode()) { delta = response.getEntity(Applications.class); } if (delta == null) { logger.warn("The server does not allow the delta revision to be applied because it is not safe. Hence got the full registry."); this.closeResponse(response); response = getAndStoreFullRegistry(); } else { updateDelta(delta); String reconcileHashCode = getReconcileHashCode(applications); if ((!reconcileHashCode.equals(delta.getAppsHashCode())) || clientConfig.shouldLogDeltaDiff()) { response = reconcileAndLogDifference(response, delta, reconcileHashCode); } } logTotalInstances(); } logger.debug(PREFIX + appPathIdentifier + " - refresh status: " + response.getStatus()); updateInstanceRemoteStatus(); } catch (Throwable e) { logger.error( PREFIX + appPathIdentifier + " - was unable to refresh its cache! status = " + e.getMessage(), e); return false; } finally { if (tracer != null) { tracer.stop(); } closeResponse(response); } return true; }