WeSee
WeSee

Reputation: 3770

Metrics in time series database

We want to use a timeseries database as InfluxDB for raw sensor data storage.

How to handle key metrics as

Is the star schema known from data warehousing a valid approach with time series db's?

Or is it better to generate such metrics on demand?

Upvotes: 0

Views: 102

Answers (1)

Yuri Lachin
Yuri Lachin

Reputation: 1500

If you don't mind using disk space usage and longer response time from queries it is enough to store metrics for raw sensor data. InfluxQL provides aggregation functions for avg,max,min of time series. Just don't forget to tag input data with some kind of sensors' ID.

In more a advance setup you can define retention policy to keep raw data times series only for some finite time period (for example 1 week) and configure continuous queries in influxdb to automatically create aggregated series with average, max, min values (for example per 5-min or per day) from raw series. Queries from such pre-aggregated derived time series will run faster.

Upvotes: 2

Related Questions