Skip to content

Commit

Permalink
Publish beta version of EDMA
Browse files Browse the repository at this point in the history
  • Loading branch information
chungquantin committed Dec 10, 2022
1 parent 8a0b5d1 commit 93c6525
Show file tree
Hide file tree
Showing 8 changed files with 403 additions and 37 deletions.
38 changes: 19 additions & 19 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

111 changes: 98 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,23 +14,22 @@ Embedded Database Management for All

<p>
<a href="https://github.com/nomadiz/edma"><img src="https://img.shields.io/badge/built_with-Rust-dca282.svg?style=flat-square"></a>
&nbsp;
<a href="https://crates.io/crates/edma"><img src="https://img.shields.io/crates/v/edma.svg?logo=rust"/></a>
<a href="https://github.com/nomadiz/edma"><img src="https://img.shields.io/github/v/release/nomadiz/edma?color=%23ff00a0&include_prereleases&label=version&sort=semver&style=flat-square"></a>
&nbsp;
<a href="https://github.com/nomadiz/edma/blob/master/LICENSE">
<img src="https://img.shields.io/badge/license-MIT License-00bfff.svg?style=flat-square"></a>
&nbsp;
<a href="https://github.com/nomadiz/edma/graphs/contributors" alt="Contributors">
<img src="https://img.shields.io/github/contributors/nomadiz/edma" /></a>
<a href="https://github.com/nomadiz/edma/pulse" alt="Activity">
&nbsp;
<img src="https://img.shields.io/github/commit-activity/m/nomadiz/edma" />
<a href="https://github.com/nomadiz/edma/graphs/contributors" alt="Contributors">
<img src="https://img.shields.io/github/contributors/nomadiz/edma?color=green" /></a>
<a href="https://github.com/nomadiz/edma/pulse" alt="Activity">
</a>
</p>

## What is EDMA?

<p align="center">
<img width="80%" src="https://user-images.githubusercontent.com/56880684/206833658-97091acd-11c7-4b78-b08b-9ce2aeb365a8.gif"/>
<img width="80%" style="
box-shadow: 0px 4px 59px 22px rgba(0, 0, 0, 0.56);
border-radius: 10px;" src="https://user-images.githubusercontent.com/56880684/206833658-97091acd-11c7-4b78-b08b-9ce2aeb365a8.gif"/>
</p>

**EDMA: Embedded Database Management for All** is an open source project made to manage embedded key-value storages. EDMA is a TUI (Terminal User Interface) that is easy to install and configure. It allows engineer to traverse the embedded database and deserialize byte data with provided byte layout. This enhances the experience of working with low level database system like RocksDB or Redb.
Expand All @@ -42,9 +41,44 @@ Embedded Database Management for All
- Custom byte layout deserialization
- Execute database command directly in terminal
- Interactive terminal interface with keyboard only control
- Iterate key-value pairs from column family and table
- Iterate key-value pairs from column family and table

## Getting Started

### Installation

#### With Homebrew (Linux, macOS)

If you’re using Homebrew or Linuxbrew, install the edma formula:

```
brew install nomadiz/tap/edma
```

#### With Cargo (Linux, macOS, Windows)

If you already have a Rust environment set up, you can use the `cargo install` command:

```
cargo install --version 0.1.0-beta.3 edma
```

## Usage
#### From binaries (Linux, macOS, Windows)

- Download the [latest release binary](https://github.com/nomadiz/edma/releases) for your system
- Set the `PATH` environment variable

### Set a config path

Configuration file is where you identify path to databases and EDMA byte templates. To set a config path, using a CLI command

```
$ edma --config-path [PATH_TO_FILE]
```

Please view [EDMA Configuration file](https://github.com/nomadiz/edma#configuration) to learn more how configuration file works.

### Usage

Run EDMA terminal application

Expand All @@ -55,7 +89,7 @@ $ edma
Set a config file path

```shell
$ edma --config-file [PATH]
$ edma --config-path [PATH]
```

Using `help` command
Expand All @@ -77,6 +111,52 @@ OPTIONS:
-c, --config-path <config-path> Set the config file
```

## Why use EDMA?

### Compatible with multiple databases

<p align="center">
<img width="80%" style="
box-shadow: 0px 4px 59px 22px rgba(0, 0, 0, 0.56);
border-radius: 10px;" src="https://user-images.githubusercontent.com/56880684/206836453-3834a473-363b-4b7e-af27-fbbc6115a3bc.png"/>
</p>

**EDMA** is a very first database management tool designed for embedded databases. Applying adapter design pattern into database storage implementation, it makes integration with databases become easier. EDMA supports two databases by default: `RocksDB` and `ReDB`. To integrate with other embedded databases, you can add the implementation in [EDMA storage layer](https://github.com/nomadiz/edma/tree/master/db/src/storage/kvs)

### Interactive terminal UI

<p align="center">
<img width="80%" style="
box-shadow: 0px 4px 59px 22px rgba(0, 0, 0, 0.56);
border-radius: 10px;" src="https://user-images.githubusercontent.com/56880684/206836166-0699e5cd-e954-4499-9a7e-7a4aeb43eabc.png"/>
</p>

EDMA is built using Rust library `tui-rs` which makes it to be an app that can be run directly on your terminal. No startup time needed and it's extremely light weight. Run every where, every time, all at once

### Template management for byte deserializer

<p align="center">
<img width="80%" style="
box-shadow: 0px 4px 59px 22px rgba(0, 0, 0, 0.56);
border-radius: 10px;" src="https://user-images.githubusercontent.com/56880684/206836189-9de85d33-9a07-4e27-a182-d6cd0db83569.png"/>
</p>

Data in embedded database is different from data presented in relational databases. While relational databases label data with specific type and attributes when it is created, embedded database can't do that. The only data type that embedded database displays is byte array. For example, `[0 0 0 1 50 32 20]`. It is not human readable.

Using EDMA, byte data can be converted into human readable data using EDMA byte template system.

Instruction on how EDMA byte deserializer works: [What is EDMA templates?](https://github.com/nomadiz/edma#templates)

### Command editor

Command editor is one core feature of EDMA, it allows you to manage byte data using advanced commands. The image below shows how a database column family can iterated using command editor

<p align="center">
<img width="80%" style="
box-shadow: 0px 4px 59px 22px rgba(0, 0, 0, 0.56);
border-radius: 10px;" src="https://user-images.githubusercontent.com/56880684/206836218-8f115413-4b8d-4c88-a192-06e4eca3a697.png"/>
</p>

## Keymap

| Key | Description |
Expand All @@ -91,10 +171,15 @@ OPTIONS:
| <kbd>q</kbd> | Quit |

## EDMA Command

EDMA supports inline command to interact with embedded databases. The list of supported commands are

### `COLUMN` or `TABLE`: Iterate with defined column famility or table

#### Arguments
- `String`: Column family name

- `String`: Column family name

## Configuration

### Databases
Expand Down
Loading

0 comments on commit 93c6525

Please sign in to comment.