本文整理汇总了Java中com.codahale.metrics.SharedMetricRegistries.clear方法的典型用法代码示例。如果您正苦于以下问题:Java SharedMetricRegistries.clear方法的具体用法?Java SharedMetricRegistries.clear怎么用?Java SharedMetricRegistries.clear使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.codahale.metrics.SharedMetricRegistries
的用法示例。
在下文中一共展示了SharedMetricRegistries.clear方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onPassivate
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@Override
public void onPassivate( Application application )
{
requestTimers.values().forEach( t -> t.stop() );
requestTimers = null;
reporters.forEach(
r ->
{
if( r instanceof ScheduledReporter )
{
( (ScheduledReporter) r ).stop();
}
else if( r instanceof JmxReporter )
{
( (JmxReporter) r ).stop();
}
}
);
reporters = null;
api = null;
eventRegistration.unregister();
eventRegistration = null;
SharedMetricRegistries.clear();
SharedHealthCheckRegistries.clear();
}
示例2: setUp
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@Before
public void setUp() throws Exception {
Stagemonitor.reset();
SharedMetricRegistries.clear();
this.corePlugin = mock(CorePlugin.class);
when(corePlugin.isStagemonitorActive()).thenReturn(true);
final MockTracer tracer = new MockTracer(new ThreadLocalScopeManager(), new B3Propagator());
TracingPlugin tracingPlugin = mock(TracingPlugin.class);
when(tracingPlugin.getTracer()).thenReturn(tracer);
mdcSpanInterceptor = new MDCSpanEventListener(corePlugin, tracingPlugin);
spanWrapper = new SpanWrapper(tracer.buildSpan("operation name").start(),"operation name",
1, 1, Collections.emptyList(), new ConcurrentHashMap<>());
}
示例3: before
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@Before
public void before() throws Exception {
Stagemonitor.reset();
SharedMetricRegistries.clear();
ConfigurationRegistry configuration = ConfigurationRegistry.builder()
.addOptionProvider(new TracingPlugin())
.build();
config = configuration.getConfig(TracingPlugin.class);
}
示例4: setUp
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@Before
public void setUp() {
SharedMetricRegistries.clear();
}
示例5: setUp
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@Override
public void setUp() throws Exception {
SharedMetricRegistries.clear();
SharedMetricRegistries.getOrCreate("the_name");
super.setUp();
}
示例6: setUp
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@Override
public void setUp() throws Exception {
SharedMetricRegistries.clear();
super.setUp();
}
示例7: clearSharedMetricRegistries
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@After
public void clearSharedMetricRegistries() {
SharedMetricRegistries.clear();
}
示例8: clear
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@AfterClass
public static void clear() {
Stagemonitor.reset();
SharedMetricRegistries.clear();
}
示例9: clearSharedMetricRegistries
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@AfterClass
public static void clearSharedMetricRegistries() {
SharedMetricRegistries.clear();
}
开发者ID:astefanutti,项目名称:metrics-aspectj,代码行数:5,代码来源:TimedStaticMethodWithNameFromElExpressionTest.java
示例10: resetStagemonitor
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@AfterClass
public static void resetStagemonitor() {
Stagemonitor.reset();
SharedMetricRegistries.clear();
}
示例11: reset
import com.codahale.metrics.SharedMetricRegistries; //导入方法依赖的package包/类
@AfterClass
public static void reset() {
Stagemonitor.reset();
SharedMetricRegistries.clear();
}