io.prometheus.metrics.config.PrometheusPropertiesLoader Maven / Gradle / Ivy
package io.prometheus.metrics.config;
import java.io.IOException;
import java.io.InputStream;
import java.nio.file.Files;
import java.nio.file.Paths;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
import java.util.Properties;
import java.util.Set;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
/**
* The Properties Loader is early stages.
*
* It would be great to implement a subset of
* Spring Boot's Externalized Configuration,
* like support for YAML, Properties, and env vars, or support for Spring's naming conventions for properties.
*/
public class PrometheusPropertiesLoader {
/**
* See {@link PrometheusProperties#get()}.
*/
public static PrometheusProperties load() throws PrometheusPropertiesException {
return load(new Properties());
}
public static PrometheusProperties load(Map
© 2015 - 2025 Weber Informatics LLC | Privacy Policy