Giter Club home page Giter Club logo

flydb's Introduction

FlyDB-logo

GitHub top language Go Reference LICENSE GitHub stars GitHub forks Go Report Card

The project is under iterative development, please do not use it in production environment!

English | ไธญๆ–‡

FlyDB aims to serve as an alternative to in-memory key-value storage (such as Redis) in some cases, aiming to strike a balance between performance and storage cost. It does this by optimizing resource allocation and using cost-effective storage media. By intelligently managing data, FlyDB ensures efficient operations while minimizing storage costs. It provides a reliable solution for scenarios that require a balance between performance and storage costs.

๐Ÿ“š What is FlyDB ?

FlyDB is a high-performance key-value (KV) storage engine based on the efficient bitcask model. It offers fast and reliable data retrieval and storage capabilities. By leveraging the simplicity and effectiveness of the bitcask model, FlyDB ensures efficient read and write operations, resulting in improved overall performance. It provides a streamlined approach to storing and accessing key-value pairs, making it an excellent choice for scenarios that require fast and responsive data access. FlyDB's focus on speed and simplicity makes it a valuable alternative for applications that prioritize performance while balancing storage costs.ย 

๐Ÿ Fast Start: FlyDB

You can install FlyDB using the Go command line tool:

go get github.com/ByteStorage/FlyDB@v1.0.3

Or clone this project from github:

git clone https://github.com/ByteStorage/FlyDB.git

๐Ÿ–ฅ How to use FlyDB ?

Here is a simple example of how to use the Linux version:

See flydb/examples for details.

package main

import (
	"fmt"
	"github.com/ByteStorage/FlyDB/flydb"
	"github.com/ByteStorage/FlyDB/config"
)

func main() {
    	options := config.DefaultOptions
	options.DirPath = "/tmp/flydb"
	db, _ := flydb.NewFlyDB(options)

    	err := db.Put([]byte("name"), []byte("flydb-example"))
    	if err != nil {
        	fmt.Println("Put Error => ", err)
    	}


	val, err := db.Get([]byte("name"))
	if err != nil {
		fmt.Println("Get Error => ", err)
	}
    	fmt.Println("name value => ", string(val))
    
    
    	err := db.Delete([]byte("name"))
    	if err != nil {
        	fmt.Println("Delete Error => ", err)
    	}
}

๐Ÿš€ Performance test

We did a simple performance test of the V1.0.3 version of FlyDB. This test mainly focused on reading and writing large-scale data, and we selected 500,000 random data for testing.

Through testing, we found that in V1.0.3, with 500,000 data:

PUT performance: 1.354297175s

GET performance: 1.068179401s

vx

If you have a better way to optimize read and write performance, please submit your 'pr'.

๐Ÿ”ฎ How to contact us ?

If you have any questions and want to contact us, you can contact our developer team, we will reply to your email:

Team Email: [email protected]

Or add my wechat, invite you to enter the project community, and code masters together to exchange learning.

Add wechat please comment GIthub

vx

๐Ÿ“œ TODO List

  • Extended data structure support: including but not limited to string, list, hash, set, etc.
  • Compatible with Redis protocols and commands.
  • Support http services.
  • Support tcp services.
  • Log aggregation
  • Data backup
  • Distributed cluster model.

How to contribute ?

If you have any ideas or suggestions for FlyDB, please feel free to submit 'issues' or' pr 'on GitHub. We welcome your contributions!

Please refer to the complete specification procedure๏ผšCONTRIBUTEING

Licence

FlyDB is released under the Apache license. For details, see LICENSE file.

flydb's People

Contributors

bigboss2063 avatar chdlvy avatar crazyjius avatar lovevivi121 avatar qishenonly avatar sjcsjc123 avatar uncle-justice avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.