Utilities for transforming InfluxDB time series data
The basics are:
- Install Rust (to build the project): https://rustup.rs/
- git clone [email protected]:michaelr524/downsampler.git
- cd downsampler
- cargo build --release
- Edit config.toml to your needs
- Run like this: target/release/downsampler downsample -s ‘2018-08-13 15:22:06’ -e ‘2018-08-17 19:03:17’
The following operations are currently supported:
Create downsampled series from other series.
Creates many measurement with a single serie from measurements with multiple series.
Continuously downsampling the configured series as new data arrives. You need to have Redis running. Redis is used for notifying downsampler about new data. Additionally, Redis is used to store a checkpoint so that downsampler knows how to restart from the point where it stopped last time it ran. The way to send updates to Redis is:
HSET downsampler_updates "binance_BTCUSDT" "1537710900000000000"
The key will be used in the downsampled series name (check listen
> measurement_template
in config.toml
) and the value is the timestamp in nanoseconds format.
Downsampler will downsample all the data from the previous checkpoint up to the given timestamp.