
io.pcp.parfait.dropwizard.DefaultMetricDescriptorLookup Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of parfait-dropwizard Show documentation
Show all versions of parfait-dropwizard Show documentation
Reporter for Dropwizard (ex Codahale) metrics that publishes to Parfait
package io.pcp.parfait.dropwizard;
import static tec.uom.se.AbstractUnit.ONE;
import io.pcp.parfait.ValueSemantics;
import javax.measure.quantity.Dimensionless;
import javax.measure.Unit;
public class DefaultMetricDescriptorLookup implements MetricDescriptorLookup {
@Override
public MetricDescriptor getDescriptorFor(final String metricName) {
return new MetricDescriptor() {
@Override
public Unit getUnit() {
return ONE;
}
@Override
public String getDescription() {
return metricName;
}
@Override
public ValueSemantics getSemantics() {
return ValueSemantics.FREE_RUNNING;
}
};
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy