in archaius2-core/src/main/java/com/netflix/archaius/config/PollingDynamicConfig.java [98:126]
private void update() throws Exception {
// OK to ignore calls to update() if already busy updating
if (busy.compareAndSet(false, true)) {
updateCounter.incrementAndGet();
try {
PollingResponse response = reader.call();
if (response.hasData()) {
current = Collections.unmodifiableMap(response.getToAdd());
currentIds = Collections.unmodifiableMap(response.getNameToIdsMap());
notifyConfigUpdated(this);
}
}
catch (Exception e) {
LOG.trace("Error reading data from remote server ", e);
errorCounter.incrementAndGet();
try {
notifyError(e, this);
}
catch (Exception e2) {
LOG.warn("Failed to notify error observer", e2);
}
throw e;
}
finally {
busy.set(false);
}
}
}