Package com.twitter.common.stats

Examples of com.twitter.common.stats.SlidingStats


      private final AtomicLong timeouts;
      private final AtomicLong failures;

      OpStats(String opName) {
        this.opName = MorePreconditions.checkNotBlank(opName);
        timing = new SlidingStats("scheduler_log_native_" + opName, "nanos");
        timeouts = exportLongStat("scheduler_log_native_%s_timeouts", opName);
        failures = exportLongStat("scheduler_log_native_%s_failures", opName);
      }
View Full Code Here


        }
      });

  @Override
  public Object invoke(MethodInvocation invocation) throws Throwable {
    SlidingStats stat = stats.get(invocation.getMethod());
    long start = System.nanoTime();
    try {
      return invocation.proceed();
    } finally {
      stat.accumulate(System.nanoTime() - start);
    }
  }
View Full Code Here

      private final AtomicLong timeouts;
      private final AtomicLong failures;

      OpStats(String opName) {
        this.opName = MorePreconditions.checkNotBlank(opName);
        timing = new SlidingStats("scheduler_log_native_" + opName, "nanos");
        timeouts = exportLongStat("scheduler_log_native_%s_timeouts", opName);
        failures = exportLongStat("scheduler_log_native_%s_failures", opName);
      }
View Full Code Here

TOP

Related Classes of com.twitter.common.stats.SlidingStats

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.