thanos_downloader

command module
v0.0.0-...-f8418de Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 14, 2020 License: Apache-2.0 Imports: 14 Imported by: 0

README

Release Build Status Go Report Card

Thanos Downloader

A helper application to use Prometheus TSDB data blocks uploaded by Thanos Sidecar component with a vanilla Prometheus setup.

The goal of this project is to allow for a simple use of Thanos Sidecar as a backup service for Prometheus data, and be able to use that data with a vanilla Prometheus setup without the need for the remaining Thanos components.

Configuration

Thanos Downloader uses the same configuration format used by Thanos Sidecar (e.g https://thanos.io/storage.md/#gcs). The available configuration flags can be found as below :

$ thanos_downloader --help
usage: thanos_downloader --interval.start=INTERVAL.START --interval.end=INTERVAL.END [<flags>]

Flags:
  --help                            Show context-sensitive help (also try --help-long and --help-man).
  --data.path="prom_data"           target data directory path.
  --interval.start=INTERVAL.START   start time of the requested interval in Unix time format (seconds).
  --interval.end=INTERVAL.END       end time of the requested interval in Unix time format (seconds).
  --config.path="config.yaml"       path to the Thanos format config file.
  --version                         Show application version.
How does it work
  1. get list of blocks in the provided bucket
  2. filter all blocks that satisfies the requested time range
  3. get the block with the highest resolution and most samples count for each time interval. This is needed since the uploaded blocks might be overlapping due to Prometheus HA setups and/or Thanos downsampling.
Docker

The application is available as a docker image :

docker run --rm -it anasaso/thanos_downloader:latest --help
Examples

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
pkg

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL