当前位置: 首页>>代码示例>>Java>>正文


Java MetricRegistry.counter方法代码示例

本文整理汇总了Java中com.codahale.metrics.MetricRegistry.counter方法的典型用法代码示例。如果您正苦于以下问题:Java MetricRegistry.counter方法的具体用法?Java MetricRegistry.counter怎么用?Java MetricRegistry.counter使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.codahale.metrics.MetricRegistry的用法示例。


在下文中一共展示了MetricRegistry.counter方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: PGFactStore

import com.codahale.metrics.MetricRegistry; //导入方法依赖的package包/类
@Autowired
public PGFactStore(JdbcTemplate jdbcTemplate, PGSubscriptionFactory subscriptionFactory,
        MetricRegistry registry) {
    this.jdbcTemplate = jdbcTemplate;
    this.subscriptionFactory = subscriptionFactory;
    this.registry = registry;

    publishFailedCounter = registry.counter(names.factPublishingFailed());
    publishLatency = registry.timer(names.factPublishingLatency());
    publishMeter = registry.meter(names.factPublishingMeter());

    fetchLatency = registry.timer(names.fetchLatency());
    seqLookupLatency = registry.timer(names.seqLookupLatency());

    subscriptionCatchupMeter = registry.meter(names.subscribeCatchup());
    subscriptionFollowMeter = registry.meter(names.subscribeFollow());
}
 
开发者ID:uweschaefer,项目名称:factcast,代码行数:18,代码来源:PGFactStore.java

示例2: MonitoredExecutorService

import com.codahale.metrics.MetricRegistry; //导入方法依赖的package包/类
public MonitoredExecutorService(ExecutorService delegate, MetricRegistry registry, String
        name) {
    this.delegate = delegate;

    this.submitted = registry.meter(MetricRegistry.name(name, "submitted"));
    this.rejected = registry.meter(MetricRegistry.name(name, "rejected"));
    this.running = registry.counter(MetricRegistry.name(name, "running"));
    this.completed = registry.meter(MetricRegistry.name(name, "completed"));

    this.dispatchDurationTimer = registry.timer(MetricRegistry.name(name, "dispatchDuration"));
    this.durationTimer = registry.timer(MetricRegistry.name(name, "duration"));
}
 
开发者ID:fchenxi,项目名称:easyhbase,代码行数:13,代码来源:MonitoredExecutorService.java

示例3: ConnectionLimiter

import com.codahale.metrics.MetricRegistry; //导入方法依赖的package包/类
public ConnectionLimiter(MetricRegistry metrics, int maxConnections) {
  this.maxConnections = maxConnections;
  this.numConnections = new AtomicInteger(0);
  this.connections = metrics.counter(name(Router.class, "Active Connections"));
}
 
开发者ID:Nordstrom,项目名称:xrpc,代码行数:6,代码来源:ConnectionLimiter.java

示例4: SingleThreadNestedCounter

import com.codahale.metrics.MetricRegistry; //导入方法依赖的package包/类
public SingleThreadNestedCounter(MetricRegistry registry, String name) {
  super();
  this.counter = registry.counter(name);
}
 
开发者ID:skhalifa,项目名称:QDrill,代码行数:5,代码来源:SingleThreadNestedCounter.java

示例5: PGConnectionTester

import com.codahale.metrics.MetricRegistry; //导入方法依赖的package包/类
PGConnectionTester(@NonNull MetricRegistry registry) {
    connectionFailureMetric = registry.counter(new PGMetricNames().connectionFailure());
}
 
开发者ID:uweschaefer,项目名称:factcast,代码行数:4,代码来源:PGConnectionTester.java


注:本文中的com.codahale.metrics.MetricRegistry.counter方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。