class ServiceProvision {

    public static <T> Map<String, T> loadServices(Configuration configuration, Environment environment, String key, Class<? extends T> serviceClass) {
        return configuration.get(key, JsonNode.class)
                .<Map<String, T>>map(node -> servicesMap(node, environment, serviceClass))
                .orElse(emptyMap());
    }

    private  ServiceProvision();

}