public void update(RawConfig config) {
        // Do not cache errors
        if (config.isError()) return;

        // Do not cache empty configs (which have generation 0), remove everything in cache
        if (config.getGeneration() == 0) {
            cache.clear();
            return;
        }

        log.log(Level.FINE, () -> "Putting '" + config + "' into memory cache");
        cache.put(new ConfigCacheKey(config.getKey(), config.getDefMd5()), config);
    }
Put in cache, except when config has an error

@param config config to update in cache
config-proxy/src/main/java/com/yahoo/vespa/config/proxy/MemoryCache.java