Crate tic [] [src]

tic - time interval counter a high-performance stats library for Rust projects

About

tic is using Histograms and Heatmaps for storing all Samples. Simply timestamp your start and start events, and pass those along with a metric label to Sample::new(); Your metric label could be an Enum, or a String, or Integer, or ...). Sender is clonable and can be shared across many threads. A single Receiver is capable of processing millions of samples per second. Performance is a top priority

Goals

  • high-performance stats library for use in Rust projects
  • export derived metrics as well as histograms

Future work

  • tests, tests, tests
  • improve the documentation
  • make it suitable for long-running applications
  • stats aggregator
  • extensive benchmarking
  • optimization efforts, memory footprint and speed

Usage

The pattern is to create a Receiver, acquire a Sender from the Receiver, and send Samples to the Sender

Example

Checkout benches/src/main.rs

Structs

Clocksource
Config

a configuration struct for customizing Receiver

Meters
Percentile

a Percentile is the label plus floating point percentile representation

Receiver

a Receiver processes incoming Samples and generates stats

Sample

a start and stop time for an event

Sender

a Sender is used to push Samples to the Receiver it is clonable for sharing between threads

Enums

Interest

an Interest registers a metric for reporting