Nipo is a powerful, fast, multi-thread, clustered and in-memory key-value database, with ability to configure token and acl on commands and key-regexes written by GO

Related tags

Database nipo
Overview

Welcome to NIPO

Nipo is a powerful, fast, multi-thread, clustered and in-memory key-value database, with ability to configure token and acl on commands and key-regexes written by GO. With several mathematical and aggregation functionalities on batch of keys and values.

Fast

Nipo will give you up to 15K OPS in single mode and up to 2.5K OPS in cluster mode with 2 slaves.

Multi-Thread

Nipo's architecture is multi-thread and you can define core and threads in your config file.

Clustered

Nipo supports several slaves and guaranties your slaves synchronization. It will automatically sync slave after comming up. You can ask your cluster status. The healthcheck interval could be configured in millisecond.

In-Memory

Nipo is in-memory database and data will be lost if service stops.

How to Contributing?

For Contributing into nipo project please read contributing rules in CONTRIBUTING.md

Config file

global

Global section defines some global parameters

authorization (string): [true/false]

Defines that the clients must work with token or not. If set "true" you have to define users section

master (string): [true/false]

Defines that this server has some slaves. If set "true" you have to define slaves section

checkinterval (int):

Defines the interval of slaves healthcheck in milliseconds

global:  
  authorization: false
  master: true
  checkinterval: 1000

slaves

Slave section defines parameter about slaves of this server

id (int) : defines the id of slave. Master will sync the slaves by id priority.

ip (string) : is the IP of slave

port (string) : is the listen port of destination IP

authorization (string) : [true/false] defines if the destination slave uses token or not

token (string) : in case of authorization is true, you need to define token

slaves:
  - slave:
    id : 1
    ip : 127.0.0.1
    port : 2324
    authorization: false
    token: 061b30a7-1a12-4280-8e3c-6bc9a19b1683
  - slave:
    id : 2
    ip : 127.0.0.1
    port : 2325
    authorization: false
    token: 061b30a7-1a12-4280-8e3c-6bc9a19b1683

proc

Proc section defines parameters for multi-threading and multi-processing

cores (int) : the count of cores you want to used by nipo

threads (int) : the count of threads you want to created by nipo

NOTE : the best practice is using threads two times of cores

proc:
  cores: 2
  threads: 4

listen

At this section you can configure your server side listen IP and PORT, currently only TCP is allowed.

listen:
  ip: 0.0.0.0
  port: 2323
  protocol: tcp

log

Log section defines parameters for logging

level (int) :
  0 - no log
  1 - info
  2 - debug

path (string) : defines the path of log file

log:
  level: 1
  path: "/tmp/nipo.log"

users

Users section defines parameters for authorization. If authorization in global section is true, this section had to be defined you can define several users

name (string) : just is metadata for name of user

token (string) : used for authorization

keys (string) : the regex of keys which user should have access. if you have several regexes you can separate them with delimiter "||"

cmds (string) : the list of commands that user should have access to execute if you have several commands you can separate them with delimiter "||"

users:
  - user:
    name: admin
    token: 061b30a7-1a12-4280-8e3c-6bc9a19b1683
    keys: .*
    cmds: all
  - user:
    name: readonly
    token: 0517376d-49c1-40eb-a8fc-fd73b70a4ce9
    keys: name.*||.*log.*
    cmds: get||select||avg

CLI

To introduce with CLI nipocli please visit the LINK.

GO library

To introduce how to use nipo with GO please visit the LINK.

You might also like...
Fast and simple key/value store written using Go's standard library
Fast and simple key/value store written using Go's standard library

Table of Contents Description Usage Cookbook Disadvantages Motivation Benchmarks Test 1 Test 4 Description Package pudge is a fast and simple key/valu

Eagle - Eagle is a fast and strongly encrypted key-value store written in pure Golang.

EagleDB EagleDB is a fast and simple key-value store written in Golang. It has been designed for handling an exaggerated read/write workload, which su

Fast thread-safe inmemory cache for big number of entries in Go. Minimizes GC overhead

fastcache - fast thread-safe inmemory cache for big number of entries in Go Features Fast. Performance scales on multi-core CPUs. See benchmark result

Multi producer and multi-reader lockless ring buffer in go using generics from the go 1.18beta release

LocklessGenericRingBuffer This is an implementation of a multi producer, multi r

An embedded key/value database for Go.

bbolt bbolt is a fork of Ben Johnson's Bolt key/value store. The purpose of this fork is to provide the Go community with an active maintenance and de

ACID key-value database.

Coffer Simply ACID* key-value database. At the medium or even low latency it tries to provide greater throughput without losing the ACID properties of

LevelDB key/value database in Go.

This is an implementation of the LevelDB key/value database in the Go programming language. Installation go get github.com/syndtr/goleveldb/leveldb R

Graviton Database: ZFS for key-value stores.
Graviton Database: ZFS for key-value stores.

Graviton Database: ZFS for key-value stores. Graviton Database is simple, fast, versioned, authenticated, embeddable key-value store database in pure

An embedded, hardened key/value database for Go.

Bolt Bolt is a pure Go key/value store inspired by Howard Chu's LMDB project. The goal of the project is to provide a simple, fast, and reliable datab

Comments
  • Improved Code

    Improved Code

    1. Change Name class to CamelCase , Fixed PEP 8: EP711
    2. Handled unhandled error
    3. Fixed some words
    4. Removed repeat datatype input, sorted imports
    5. fixed handels to handles
    opened by Ja7ad 1
  • Can not run nipo/main.go

    Can not run nipo/main.go

    Hi, I had some issue with importing nipo package. I am using this repo out of GOPATH. I tried to fix it using go mod. Now it looks fine. Can I a create a pull request for that? The error was: package nipo is not in GOROOT (/usr/local/go/src/nipo)

    opened by aahemm 1
  • Fix and Improved nipo

    Fix and Improved nipo

    1. sorted imports
    2. removed additional code casting
    3. handled unhandled errors
    4. removed unwrap parentheses
    5. Change name checkinterval to checkInterval for code Effective go
    6. fix some words
    7. removed static value in variable and put in to return
    8. sum variable default type is float64 not need code casting
    9. for improved performance in compiler language change sum += valFloat to sum = sum + valFloat
    10. fixed name to camelCase https://golang.org/doc/effective_go#names
    opened by Ja7ad 0
Owner
Morteza Bashsiz
Linux, DevOps, VoIP, Openstack, Kubernetes, GO
Morteza Bashsiz
Membin is an in-memory database that can be stored on disk. Data model smiliar to key-value but values store as JSON byte array.

Membin Docs | Contributing | License What is Membin? The Membin database system is in-memory database smiliar to key-value databases, target to effici

Membin 3 Jun 3, 2021
BadgerDB is an embeddable, persistent and fast key-value (KV) database written in pure Go

BadgerDB BadgerDB is an embeddable, persistent and fast key-value (KV) database written in pure Go. It is the underlying database for Dgraph, a fast,

Blizard 1 Dec 10, 2021
Simple key value database that use json files to store the database

KValDB Simple key value database that use json files to store the database, the key and the respective value. This simple database have two gRPC metho

Francisco Santos 0 Nov 13, 2021
pure golang key database support key have value. 非常高效实用的键值数据库。

orderfile32 pure golang key database support key have value The orderfile32 is standard alone fast key value database. It have two version. one is thi

null 3 Apr 30, 2022
Distributed cache and in-memory key/value data store.

Distributed cache and in-memory key/value data store. It can be used both as an embedded Go library and as a language-independent service.

Burak Sezer 2.3k Sep 21, 2022
An in-memory key:value store/cache (similar to Memcached) library for Go, suitable for single-machine applications.

go-cache go-cache is an in-memory key:value store/cache similar to memcached that is suitable for applications running on a single machine. Its major

Patrick Mylund Nielsen 6.5k Sep 21, 2022
A minimalistic in-memory key value store.

A minimalistic in-memory key value store. Overview You can think of Kiwi as thread safe global variables. This kind of library comes in helpful when y

SDSLabs 159 Dec 6, 2021
A rest-api that works with golang as an in-memory key value store

Rest API Service in GOLANG A rest-api that works with golang as an in-memory key value store Usage Run command below in terminal in project directory.

sercan aydın 0 Dec 6, 2021
GalaxyDB is a hobbyist key-value database written in Go.

GalaxyDB GalaxyDB is a hobbyist key-value database written in Go Author: Andrew N ([email protected]) Features Data is stored via keys Operations Grafana

nijmeh.xyz 3 Mar 30, 2022
A simple, fast, embeddable, persistent key/value store written in pure Go. It supports fully serializable transactions and many data structures such as list, set, sorted set.

NutsDB English | 简体中文 NutsDB is a simple, fast, embeddable and persistent key/value store written in pure Go. It supports fully serializable transacti

徐佳军 2.5k Sep 21, 2022