@Override
    public Map<String, Object> getMap() {
        if (null == map) {
            synchronized (mutex) {
                // double-guard
                if (null == map) {
                    final Map<String, Object> registryMap = new ConcurrentHashMap<>();
                    if (registryFile.exists()) {
                        try (final InputStream in = FileUtils.openInputStream(registryFile)) {
                            final RegistryWrapper wrapper = mapper.readValue(in, RegistryWrapper.class);

                            registryMap.putAll(wrapper.getApis().stream()
                                    .collect(toMap(this::getApiIndex, identity())));
                            registryMap.putAll(wrapper.getClients().stream()
                                    .collect(toMap(this::getClientIndex, identity())));
                        } catch (IOException ioe) {
                            throw new UncheckedIOException("Error reading registry from file: " + registryFile, ioe);
                        }
                    } else {
                        LOGGER.warn("Local registry file does not exist under path {0}. "
                                + "It will be created when the first save operation occurs",
                            registryFile.getAbsolutePath());
                    }
                    map = registryMap;
                }
            }
        }
        return map;
    }
Read the {@link #map} from the filesystem.

@return the registry map
gateway/engine/filesystem/src/main/java/io/apiman/gateway/engine/filesystem/LocalFileRegistry.java