use of com.palantir.tritium.metrics.registry.DefaultTaggedMetricRegistry in project atlasdb by palantir.
the class TimeLockServerLauncher method initialize.
@Override
public void initialize(Bootstrap<TimeLockServerConfiguration> bootstrap) {
MetricRegistry metricRegistry = SharedMetricRegistries.getOrCreate("AtlasDbTest" + UUID.randomUUID().toString());
TaggedMetricRegistry taggedMetricRegistry = new DefaultTaggedMetricRegistry();
AtlasDbMetrics.setMetricRegistries(metricRegistry, taggedMetricRegistry);
bootstrap.setMetricRegistry(metricRegistry);
bootstrap.getObjectMapper().registerSubtypes(NonBlockingFileAppenderFactory.class);
bootstrap.getObjectMapper().registerModule(new Jdk8Module());
super.initialize(bootstrap);
}
use of com.palantir.tritium.metrics.registry.DefaultTaggedMetricRegistry in project atlasdb by palantir.
the class CassandraClientPoolTest method setup.
@Before
public void setup() {
AtlasDbMetrics.setMetricRegistries(new MetricRegistry(), new DefaultTaggedMetricRegistry());
this.metricRegistry = AtlasDbMetrics.getMetricRegistry();
config = mock(CassandraKeyValueServiceConfig.class);
when(config.poolRefreshIntervalSeconds()).thenReturn(POOL_REFRESH_INTERVAL_SECONDS);
when(config.timeBetweenConnectionEvictionRunsSeconds()).thenReturn(TIME_BETWEEN_EVICTION_RUNS_SECONDS);
when(config.unresponsiveHostBackoffTimeSeconds()).thenReturn(UNRESPONSIVE_HOST_BACKOFF_SECONDS);
blacklist = new Blacklist(config);
}
use of com.palantir.tritium.metrics.registry.DefaultTaggedMetricRegistry in project atlasdb by palantir.
the class MetricsRule method before.
@Override
protected void before() throws Throwable {
super.before();
AtlasDbMetrics.setMetricRegistries(SharedMetricRegistries.getOrCreate("AtlasDbTest"), new DefaultTaggedMetricRegistry());
}
Aggregations