public class MetricsSystemLoader extends Object
ServiceLoader to instantiate a MetricsSystem.| Modifier and Type | Field and Description |
|---|---|
private static MetricsSystemLoader |
INSTANCE |
private static org.slf4j.Logger |
LOG |
| Modifier | Constructor and Description |
|---|---|
private |
MetricsSystemLoader() |
| Modifier and Type | Method and Description |
|---|---|
(package private) MetricsSystem |
_load(MetricsSystemConfiguration<?> config) |
(package private) List<MetricsSystemFactory> |
getFactories() |
static MetricsSystem |
load(MetricsSystemConfiguration<?> config)
Creates a
MetricsSystem instance using the corresponding MetricsSystemFactory
available to ServiceLoader on the classpath. |
private static final org.slf4j.Logger LOG
private static final MetricsSystemLoader INSTANCE
public static MetricsSystem load(MetricsSystemConfiguration<?> config)
MetricsSystem instance using the corresponding MetricsSystemFactory
available to ServiceLoader on the classpath. If there is not exactly one instance of
a MetricsSystemFactory, an instance of NoopMetricsSystem will be returned.config - State to pass to the MetricsSystemFactory.MetricsSystem implementation.MetricsSystem _load(MetricsSystemConfiguration<?> config)
List<MetricsSystemFactory> getFactories()
Copyright © 2012–2016 The Apache Software Foundation. All rights reserved.