All Projects → unit-io → unitdb

unit-io / unitdb

Licence: Apache-2.0 license
Fast specialized time-series database for IoT, real-time internet connected devices and AI analytics.

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to unitdb

microprediction
If you can measure it, consider it predicted
Stars: ✭ 158 (+62.89%)
Mutual labels:  timeseries, timeseries-database
Bitcask
🔑A high performance Key/Value store written in Go with a predictable read/write performance and high throughput. Uses a Bitcask on-disk layout (LSM+WAL) similar to Riak.
Stars: ✭ 654 (+574.23%)
Mutual labels:  trie, db
Kairosdb
Fast scalable time series database
Stars: ✭ 1,633 (+1583.51%)
Mutual labels:  timeseries, timeseries-database
InfluxDB.Client.Net
A C# client object model to help integrate with InfluxDB with CLI languages. Supports both .Net traditional and .Net Core.
Stars: ✭ 95 (-2.06%)
Mutual labels:  timeseries, timeseries-database
Arctic
High performance datastore for time series and tick data
Stars: ✭ 2,525 (+2503.09%)
Mutual labels:  timeseries, timeseries-database
metana
Abstract task migration tool written in Go for Golang services. Database and non database migration management brought to the CLI.
Stars: ✭ 61 (-37.11%)
Mutual labels:  db
Deep XF
Package towards building Explainable Forecasting and Nowcasting Models with State-of-the-art Deep Neural Networks and Dynamic Factor Model on Time Series data sets with single line of code. Also, provides utilify facility for time-series signal similarities matching, and removing noise from timeseries signals.
Stars: ✭ 83 (-14.43%)
Mutual labels:  timeseries
rust sequence trie
Ergonomic trie data structure
Stars: ✭ 22 (-77.32%)
Mutual labels:  trie
StockPriceGenerator
Python application to write stock security data to a MongoDB Cluster. Supports a variable amount of stocks, variable amount of time and can write to a MongoDB time-series collection
Stars: ✭ 21 (-78.35%)
Mutual labels:  timeseries
tsam
A python-based time series aggregation module (tsam) which can be used to reduce the number of time steps using typical periods or by decreasing the temporal resolution
Stars: ✭ 112 (+15.46%)
Mutual labels:  timeseries
HydroSight
A flexible statistical toolbox for deriving quantitative insights from groundwater data.
Stars: ✭ 31 (-68.04%)
Mutual labels:  timeseries
cortex-tenant
Prometheus remote write proxy that adds Cortex tenant ID based on metric labels
Stars: ✭ 60 (-38.14%)
Mutual labels:  timeseries
upscheme
Database migrations and schema updates made easy
Stars: ✭ 737 (+659.79%)
Mutual labels:  db
sherlock
Sherlock is an anomaly detection service built on top of Druid
Stars: ✭ 137 (+41.24%)
Mutual labels:  timeseries
lexpy
Python package for lexicon; Trie and DAWG implementation.
Stars: ✭ 47 (-51.55%)
Mutual labels:  trie
ARFIMA.jl
Simulate stochastic timeseries that follow ARFIMA, ARMA, ARIMA, AR, etc. processes
Stars: ✭ 44 (-54.64%)
Mutual labels:  timeseries
fhub
Python client for Finnhub API
Stars: ✭ 31 (-68.04%)
Mutual labels:  timeseries
XLocalizer
Localizer package for Asp.Net Core web applications, powered by online translation and auto resource creating.
Stars: ✭ 103 (+6.19%)
Mutual labels:  db
Algorithms-Java
A collection of common algorithms and data structures implemented in Java.
Stars: ✭ 141 (+45.36%)
Mutual labels:  trie
ngrest-db
Simple ORM to use with ngrest
Stars: ✭ 27 (-72.16%)
Mutual labels:  db

unitdb GoDoc Go Report Card Build Status Coverage Status

Unitdb is blazing fast specialized time-series database for microservices, IoT, and realtime internet connected devices. As Unitdb satisfy the requirements for low latency and binary messaging, it is a perfect time-series database for applications such as internet of things and internet connected devices. The Unitdb Server uses uTP (unit Transport Protocol) for the Client Server messaging. Read uTP Specification.

Don't forget to ⭐ this repo if you like Unitdb!

About unitdb

Key characteristics

  • 100% Go
  • Can store larger-than-memory data sets
  • Optimized for fast lookups and writes
  • Supports writing billions of records per hour
  • Supports opening database with immutable flag
  • Supports database encryption
  • Supports time-to-live on message entries
  • Supports writing to wildcard topics
  • Data is safely written to disk with accuracy and high performant block sync technique

Quick Start

To build Unitdb from source code use go get command.

go get github.com/unit-io/unitdb

Usage

Detailed API documentation is available using the go.dev service.

Make use of the client by importing it in your Go client source code. For example,

import "github.com/unit-io/unitdb"

Unitdb supports Get, Put, Delete operations. It also supports encryption, batch operations, and writing to wildcard topics. See usage guide.

Samples are available in the examples directory for reference.

Clustering

To bring up the Unitdb cluster start 2 or more nodes. For fault tolerance 3 nodes or more are recommended.

> ./bin/unitdb -listen=:6060 -grpc_listen=:6080 -cluster_self=one -db_path=/tmp/unitdb/node1
> ./bin/unitdb -listen=:6061 -grpc_listen=:6081 -cluster_self=two -db_path=/tmp/unitdb/node2

Above example shows each Unitdb node running on the same host, so each node must listen on different ports. This would not be necessary if each node ran on a different host.

Client Libraries

Make use of officially supported client libraries to connect to unitdb server running on single node or running on a cluster.

  • unitdb-go Lightweight and high performance unitdb Go client library.
  • unitdb-dart High performance unitdb Flutter/Dart client library.

Architecture Overview

The unitdb engine handles data from the point put request is received through writing data to the physical disk. Data is compressed and encrypted (if encryption is set) then written to a WAL for immediate durability. Entries are written to memdb and become immediately queryable. The memdb entries are periodically written to log files in the form of blocks.

To efficiently compact and store data, the unitdb engine groups entries sequence by topic key, and then orders those sequences by time and each block keep offset of previous block in reverse time order. Index block offset is calculated from entry sequence in the time-window block. Data is read from data block using index entry information and then it un-compresses the data on read (if encryption flag was set then it un-encrypts the data on read).

Unitdb stores compressed data (live records) in a memdb store. Data records in a memdb are partitioned into (live) time-blocks of configured capacity. New time-blocks are created at ingestion, while old time-blocks are appended to the log files and later sync to the disk store.

When Unitdb receives a put or delete request, it first writes records into tiny-log for recovery. Tiny-logs are added to the log queue to write it to the log file. The tiny-log write is triggered by the time or size of tiny-log incase of backoff due to massive loads.

The tiny-log queue is maintained in memory with a pre-configured size, and during massive loads the memdb backoff process will block the incoming requests from proceeding before the tiny-log queue is cleared by a write operation. After records are appended to the tiny-log, and written to the log files the records are then sync to the disk store using blazing fast block sync technique.

Next steps

In the future, we intend to enhance the Unitdb with the following features:

  • Distributed design: We are working on building out the distributed design of Unitdb, including replication and sharding management to improve its scalability.
  • Developer support and tooling: We are working on building more intuitive tooling, refactoring code structures, and enriching documentation to improve the onboarding experience, enabling developers to quickly integrate Unitdb to their time-series database stack.

Contributing

As Unitdb is under active development and at this time Unitdb is not seeking major changes or new features; however, small bugfixes are encouraged. Unitdb is seeking contibution to improve test coverage and documentation.

Licensing

This project is licensed under Apache-2.0 License.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].