BerylDB is a data structure data manager that can be used to store data as key-value entries.

Overview

BerylDB

License

This README is a brief introduction to Beryl. For extended information, you can visit our documentation site at docs.beryl.dev.

If you enjoyed learning about project and support its development, give it a star. It is appreciated

Get involved

Join our community 👋 We invite people from different backgrounds 🌈 👨 ❤️ 🙋 👴

If you are just getting started as programmer, there are several ways that you can collaborate. There is no need to be a senior programmer. At BerylDB, we are problem solvers and welcome people having this vision 👍

Some ways to get involved include

  • 🎓 Check our pending issues, or create your own.
  • 🌵 Contribute to our APIs (JS, PHP, Python).
  • 🙋 Become a QA: Test our software and report back (Check our Google group).
  • 💬 Get Involved and join our Discord server.

Logo

What is Beryl?

Beryl is a data structure server. Our database provides access to structures via a wide range of commands, which are later queued, processed, and dispatched. The server is written in C++ and is powered by RocksDB.

With Beryl, users have access to lists, maps, keys, and channel subscriptions for their clients. Currently, the server is available for GNU/Linux, FreeBSD and macOS.

A robust attention to performance and code cleanliness is an ongoing priority when developing BerylDB. Our server aims at being crash-free while utilizing minimum resources.

Why use it?

Beryl simplifies your system by allowing you to write fewer lines of code to store, retrieve, and manage data in your apps. For instance, if your app relies on sessions to keep users connected, you may use Beryl's key-value data storage. Then remove expiring keys with Beryl's automatic expire managing system.

Installation

We recommend building Beryl from the source. A guide on how to do this is available on the Beryl docs site. Beryl's development branches are available in our GitHub repository.

NOTE: When running 'make', you should use the '-j4' argument, which allows you to compile using 4 cores. Feel free to change this number according to your CPU.

  • Installing dependencies in Debian based systems:
sudo apt-get install librocksdb-dev build-essential
  • Installing dependencies in Redhat based systems:
dnf install @development-tools
yum install git rocksdb-devel.x86_64
  • Installing dependencies in macOS:
brew install rocksdb 

Clone Beryl's latest stable version:

git clone --branch 1.0 https://github.com/beryldb/beryldb.git --depth=5
cd beryldb/

You may now configure BerylDB following these quick steps:

./configure
make -j4 install

Beryl is compiled in verbose level by default. If you prefer to build with minimal information, you can use:

make -j4 install VERBOSE=0

Running Beryl

To run Beryl using the default configuration, type:

./run/beryldb start

NOTE: Beryl runs in the background by default. If you wish to avoid forking, you can run the server using nofork:

./run/beryldb start --nofork

Great! You may now run your very first BerylDB command using Beryl-cli.

Keep in mind that BerylDB uses port 6378 by default, so be sure to maintain that port unused before running the server.

APIs

APIs are used to interact with a BerylDB data-structure server. You can typically execute the same exact command as if you were connecting from the CLI.

First queries

You may want to learn more about Beryl and run your first queries using Beryl-cli:

  • set is used to define a key.
  • get is used to retrieve a key.
  • use del to remove a key.
  • use exists to verify whether a given key exists.
  • strlen is used to obtain a key's length.
get hello "world" beryl> strlen hello 5 beryl> ismatch hello "worl?" 1 beryl> del hello OK beryl> exists hello 0 ">
beryl> set hello "world"
OK
beryl> get hello
"world"
beryl> strlen hello
5
beryl> ismatch hello "worl?"
1
beryl> del hello
OK
beryl> exists hello
0

You can also run the ls command to obtain a counter in all structures:

beryl> ls
KEY       |  1 
MAP       |  0 
LIST      |  5 
GEO       |  2 
MULTIMAP  |  0 
VECTOR    |  6 
EXPIRES   |  1 
FUTURES   |  0 

To search all keys:

beryl> search *
Key                | Value     
―――――――――――――――――― | ―――――――
hello              | "world"  
test		   | "value"

Take a look at all Beryl's commands here.

Coremodules and Modules

Beryl is mainly divided into two components: core modules and modules. These can be found in these directories:

  • src/coremodules: Contains Beryl's core modules. These are required to run the server properly.

  • src/modules: Contains optional modules. Beryl can funcion without these.

Core modules include those components that are required in order to run basic functionalities. For instance, core_keys handles the SET and GET commands.

In the other hand, modules are optional components developed either by the Beryl team or by third party developers. A good example of this can be Hop. Hop allows users to unsubscribe and subscribe to a channel in just one command.

Feel free to code and submit your own modules.

Discussions

In order to maintain a documentation that is easy to follow. We try to maintain documentation that is easy to follow and try to make discussions understandable for everyone. Our code is actively changing and thus having a brief discussion board is preferred. Join our Google group If you would like to learn more about Beryl's development process.

Source code organization

Beryl's source code is in the src/ directory. The Makefile, which is created after configuring Beryl, is located in the root directory.

Inside the root directory, you will find:

  • src: Contains Beryl's implementation, written in C++.
  • include: Contains Beryl's headers.
  • etc: Libraries developed by 3rd party organizations.
  • make: Contains several Perl-based functions to compile BerylDB.

NOTE: Beryl has changed a bit. Some functions and file names may have changed. Hence, Beryl's documentation may be closer to the stable branch. Nonetheless, the core structure is the same, tested extensively.

Contributing

We are always welcoming new members. If you wish to start contributing code to the Beryl project in any form, such as in the form of pull requests via Github, a code snippet, or a patch, you will need to agree to release your work under the terms of the BSD license.

External Links

Comments
  • Best way to find keys in lists?

    Best way to find keys in lists?

    Hello,

    Hope this issue finds you all well. I'm trying to find a good way to find elements in a given list. Is there any predefined command for this?

    Great work, look forward to see newer releases! 👍

    enhancement 
    opened by benjasohns 2
  • What’s your level of compatibility with Redis?

    What’s your level of compatibility with Redis?

    Some commands of BerylDB seems to be close to Redis but some Redis commands are missing such as ‘hgetall’. Do you plan to be fully compatible or just having a subset ? Thank you

    question 
    opened by adulau 1
  • Command to get core modules

    Command to get core modules

    Hello team:

    Wouldn't it be great to have a command to list core modules? I understand that $MODULES will list all available modules, however, a better approach may be to have two commands for this, or having one command that takes arguments.

    I suggest having one MODULES command capable of handling arguments:

    $MODULES core

    and:

    $MODULES opt

    Would this be a good thing to have?

    Thanks, and keep the work!

    opened by benjasohns 1
  • epoll_wait

    epoll_wait

    Dear community,

    I am in need of support with epoll. I would like to know if anyone has experience implementing epoll-based systems. I am interested in reducing awaiting time in timeouts while using less resources.

    I would appreciate your help.

    Thanks

    enhancement help wanted 
    opened by cfferry 0
  • Sets implementation

    Sets implementation

    A suggestion:

    It would be great to have sets implemented before our 1.0 release. We already have lists and vectors. These two containers allow duplicates. It would be useful to have a container that only inserts unique elements.

    If you are interested in implementing this, feel free to do so.

    I may be reached on Discord and/or via [email protected]

    enhancement 
    opened by cfferry 0
  • Iterator class

    Iterator class

    Dear BerylDB staff:

    I believe that the server is requiring a rather different approach when dealing with functions that return more than one item (for instance, HKEYS or HLIST).

    I recommend creating a class Iterator and use it as an internal search engine.

    I am open to suggestions.

    enhancement 
    opened by eclipsedcpp 0
  • Sort function

    Sort function

    Dear BerylDB staff:

    I believe a sort function is somewhat becoming a must at this point. This function would basically return a sorted list of items in a given vector, map, list or multimap.

    The idea is to add as many functionalities as possible to the daemon, and sort is a well-needed one.

    Looking forward for ideas.

    enhancement 
    opened by eclipsedcpp 1
Releases(0.8.3)
Owner
BerylDB
Official repository for BerylDB.
BerylDB
FoundationDB - the open source, distributed, transactional key-value store

FoundationDB is a distributed database designed to handle large volumes of structured data across clusters of commodity servers. It organizes data as

Apple 12k Dec 31, 2022
Beryl-cli is a client for the BerylDB database server

Beryl-cli is a client for the BerylDB database server. It offers multiple commands and is designed to be fast and user-friendly.

BerylDB 11 Oct 9, 2022
Simple constant key/value storage library, for read-heavy systems with infrequent large bulk inserts.

Sparkey is a simple constant key/value storage library. It is mostly suited for read heavy systems with infrequent large bulk inserts. It includes bot

Spotify 989 Dec 14, 2022
LevelDB is a fast key-value storage library written at Google that provides an ordered mapping from string keys to string values.

LevelDB is a fast key-value storage library written at Google that provides an ordered mapping from string keys to string values. Authors: Sanjay Ghem

Google 31.6k Jan 7, 2023
libmdbx is an extremely fast, compact, powerful, embedded, transactional key-value database, with permissive license

One of the fastest embeddable key-value ACID database without WAL. libmdbx surpasses the legendary LMDB in terms of reliability, features and performance.

Леонид Юрьев (Leonid Yuriev) 1.1k Dec 19, 2022
Money Manager Ex is an easy to use, money management application built with wxWidgets

Money Manager Ex Money Manager Ex is a free, open-source, cross-platform, easy-to-use personal finance software. It primarily helps organize one's fin

Money Manager EX 1.2k Dec 31, 2022
Atsugami - A taggable GTK+ image manager written in C

Atsugami [] Notes Limit of 999,999x999,999px Dependencies PostgreSQL (Tested on 14 and 14.1) GTK3 Clang BSD make (bmake) Building and installation # F

Nate Morrison 4 Feb 3, 2022
A redis module, similar to redis zset, but you can set multiple scores for each member to support multi-dimensional sorting

TairZset: Support multi-score sorting zset Introduction Chinese TairZset is a data structure developed based on the redis module. Compared with the na

Alibaba 60 Dec 1, 2022
SpDB is a data integration tool designed to organize scientific data from different sources under the same namespace according to a global schema and to provide access to them in a unified form (views)

SpDB is a data integration tool designed to organize scientific data from different sources under the same namespace according to a global schema and to provide access to them in a unified form (views). Its main purpose is to provide a unified data access interface for complex scientific computations in order to enable the interaction and integration between different programs and databases.

YU Zhi 0 Jun 22, 2022
TimescaleDB is an open-source database designed to make SQL scalable for time-series data.

An open-source time-series SQL database optimized for fast ingest and complex queries. Packaged as a PostgreSQL extension.

Timescale 14.3k Jan 2, 2023
Velox is a new C++ vectorized database acceleration library aimed to optimizing query engines and data processing systems.

Velox is a C++ database acceleration library which provides reusable, extensible, and high-performance data processing components

Facebook Incubator 2k Jan 8, 2023
LogMessage is one of the output format of database incremental data

LogMessage LogMessage是一种数据库增量数据的输出格式,oceanbase的增量采集模块liboblog正是使用的这种消息格式来输出增量数据,LogMessage支持oceanbase中不同数据类型的增量数据的写入,具有序列化和反序列化的能力。 如何编译 LogMessage的编译

OceanBase 7 Dec 14, 2022
Incremental backup with strong cryptographic confidentiality baked into the data model.

Incremental backup with strong cryptographic confidentiality baked into the data model.

Rich Felker 117 Dec 29, 2022
recovery postgresql table data by update/delete/rollback/dropcolumn command

recovery postgresql table data by update/delete/rollback/dropcolumn command

RadonDB 6 Aug 4, 2022
The database built for IoT streaming data storage and real-time stream processing.

The database built for IoT streaming data storage and real-time stream processing.

HStreamDB 575 Dec 26, 2022
Flashback mysql data to any point

一、简介 MyFlash是由美团点评公司技术工程部开发维护的一个回滚DML操作的工具。该工具通过解析v4版本的binlog,完成回滚操作。相对已有的回滚工具,其增加了更多的过滤选项,让回滚更加容易。 该工具已经在美团点评内部使用 二、详细说明 安装 使用 测试用例 三、限制 binlog格式必须为r

美团 1.1k Dec 30, 2022
PGSpider: High-Performance SQL Cluster Engine for distributed big data.

PGSpider: High-Performance SQL Cluster Engine for distributed big data.

PGSpider 132 Sep 8, 2022
GridDB is a next-generation open source database that makes time series IoT and big data fast,and easy.

Overview GridDB is Database for IoT with both NoSQL interface and SQL Interface. Please refer to GridDB Features Reference for functionality. This rep

GridDB 2k Jan 8, 2023
An open-source big data platform designed and optimized for the Internet of Things (IoT).

An open-source big data platform designed and optimized for the Internet of Things (IoT).

null 20.3k Dec 29, 2022