Introduction to InfluxDB: A time-series database

Anurag Nair
5 min readFeb 23, 2021

--

Introduction

This article gives you some good insights & brief overview about InfluxDB: a Time Series database which stores and manages data in time series form.

What is Time Series?

A time series is a collection of observations of well-defined data items resulted through repeated measurements over time. Time series data is indexed in time order which is a sequence of data points.

What is Time Series Database?

Time series database (TSDB) is database system which is optimized for providing time series data and its storage in association with time & value.

Time series database consists of measurements or events that are monitored,tracked, refinement of data i.e down sampling & aggregated over time.They can be application monitoring analysis data,server metrics,data about sensors,market trading data,stock exchange data across markets.

Time series database is capable of ingesting millions of data points per second providing high level performance.

The classic real world example of a time series is stock exchange currency price data.

A time series is set of values with a timestamp for each record where time is a meaningful component of the data.

TSD are a fast growing segment in the database industry. There are several time series database available, but which is the most popular and the best? Below is the list with its ranking-

What is the TICK Stack?

The TICK Stack is an acronym that denotes for a platform of open source tools built to collect, store, graphing, and providing alerts on time series data incredibly easy and efficiently. “I” in TICK is “INFLUXDB”. TICK stack contains various components which are:

TELEGRAF: Telegraf’s provides collection of metrics and metrics collection agent that is used to collect and send metrics to InfluxDB.

InfluxDB:

Influx DB is an open source time series database written in Go language which is developed by InfluxData. It is optimized for high-availability retrieval of data,faster and storage of time series data in fields such as operations monitoring, application metrics, IoT sensor data, and real-time analytics.

InfluxDB is a high performance Time Series Database which can store data ranging from hundreds of thousands of points per second. The InfluxDB is a SQL-kind of query language which was built specifically for time series data.

What is Measurement, Tags, Fields & Points?

Keywords w.r.t to SQL DB

CHRONOGRAF: It’s a whole TICK stack UI used to setup graphs and dashboard of data in InfluxDB and integrate the Kapacitor alerts

KAPACITOR: It is used to break/crunch time series data into action alerts and send these alerts across to several products like Slack and PagerDuty. Kapacitor is a metrics,event processing and alerting system application.The entire TICK Stack is interoperable,with each component providing significant value as a standalone application.

Architecture of TICK stack:-

TICK Stack Architecture

Why use InfluxDB?

  • Faster time
  • Deep insights and analytics
  • Efficient in developer productivity- InfluxDB is — storage,ingest, query, and visualization — which is now accessible via unified API.
  • UI dashboards to view the data like Grafana,Chronograf
  • Easy-to-build, easy-to-share templates- through influxDb templates

Examples where Influxdb can be used

  • System Monitoring like disk ops.
  • Collection of IoT data.
  • Heart rate data
  • Logging
  • Tracing (what took more time among components)

Influx DB Concepts-

Tools for interacting with Influx DB:-

· Influx Command line interface(CLI)

Influxdb shell connected to port 8086

· Graph and Dashboard

— Chronograf

Dashboard View of Chronograf to view the data in time series format

Chronograf Explore View

— Grafana

Dashboard View of Grafana:

Grafana Dashboard

· Influx DB inch tool- for testing Influx Db performance

· Influxd commands — executes all necessary processes for InfluxDB to function

· InfluxDb API client libraries

Eg- influxdb-client-csharp, influxdb-javascript,influxdb-client-java

How to download Influx DB

Influx DB can be downloaded at - influxdata.com

Download version v1.8.3 as the latest version with Docker image.This version does not contain Windows installation url

Unzipping the file gives a folder which contains the following items:

One of which is influx.exe the influxdb client connecting to the localhost:port-no. It is the shell through which developer can interact with the InfluxDB to get the desired results.

Influxd.exe loads the database which contains all the necessary packages and files to run and execute the queries.

Some common influx query examples:

InfluxDB queries

.NET Packages for Influx DB

Here are some of the important nuget packages:

  1. InfluxDB.Client for InfluxDB
  2. Vibrant.InfluxDb.Client(4.0.1)

Reference Links

https://docs.influxdata.com/influxdb/v1.8/

https://www.influxdata.com/time-series-platform/

Conclusion:-

InfluxDB is a time series database built with a purpose to provide data in time series format with high efficiency & availability. Adding up records has time associated with it in built form since the beginning. InfluxDB provides facilitates storage, monitoring, visualization, collecting data & providing alerts in time series data which signifies its importance.

If this article finds you helpful & interesting, then please click on the “clap” button!!!

Happy learning!!

--

--

Anurag Nair

Senior Full Stack Developer having 6+ yrs of experience in Microsoft,Java and Front End based SPA framework,Azure & AWS to build modular and scalable apps.