返回排行榜

skytable/skytable

Rustskytable.io

Skytable is a modern scalable NoSQL database with BlueQL, designed for performance, scalability and flexibility. Skytable gives you spaces, models, data types, complex collections and more to build powerful experiences

nosqldatabaserustsqlkey-value-storedocument-databasedatabase-enginecolumn-storedistributed-databasemulti-modelbeginner-friendlydbms
Star 增长趋势
Star
2.7k
Forks
92
周增长
Issues
24
1k2k
2020年8月2022年7月2024年7月2026年7月
制品库crates.iocargo add skytable
README

Skytable Skytable Logo

A modern NoSQL database, powered by BlueQL.

GitHub release (with filter) GitHub Workflow Status (with event) Discord Docs Static Badge

NEW RELEASE UPDATES

A new version of Skytable (Skytable 0.9.0) has been in development for a while and is nearing completion. Skytable 0.9 adds clustering, new data types, and advanced querying features. The code is currently on a private repository but will be available on the crv1 branch. If you want to share any ideas or concerns before the release ships, please open an issue here.

This branch currently contains the source code for Skytable 0.8.

What is Skytable?

Skytable is a NoSQL database implemented using modern design paradigms, that focuses on performance, flexibility, and scalability.

Skytable is primarily in-memory, uses multithreaded asynchronous I/O and a custom AOF-based storage engine with advanced delayed durability transactions for efficient disk I/O. Skytable's data model is based on a column-oriented structure with support for additional data models(WIP). Querying is done using BlueQL, a SQL-based query language hardened against injection attacks, written specifically for Skytable.

Skytable is best-suited for applications that need to store large-scale data, need high-performance and low latencies.

You can read more about Skytable's architecture, including information on the clustering and HA implementation that we're currently working on, and limitations on this page.

Features

  • Spaces, models and more: For flexible data definition
  • Powerful querying with BlueQL: A modern query language based on SQL
  • Rich data modeling: Use models to define data with complex types, collections and more
  • Performant: Optimized multithreaded network I/O, write batching and several other optimizations
  • Secure: Injection deterrence using BlueQL and other memory safety measures
  • Enforces best practices: If you're building with Skytable today, the practices you'll get used to here will let you easily take on the job of building performant systems, even outside Skytable

Learn more about Skytable's features here.

Getting started

  1. Set up Skytable on your machine: You'll need to download a bundled release file from the releases page. Unzip the files and you're ready to go.
  2. Start the database server: ./skyd --auth-root-password <password> with your choice of a password for the root account. The root account is just like a root account on Unix based systems that has control over everything.
  3. Start the interactive client REPL: ./skysh and then enter your password.
  4. Your setup is now complete.

For a more detailed guide on installation and deployment, follow the guide here.

Using Skytable

Skytable has SPACEs instead of DATABASEs due to signficant operational differences (and because SPACEs store a lot more than tabular data).

With the REPL started, follow this guide:

  1. Create a space and switch to it:

    CREATE SPACE myspace
    USE myspace
    
  2. Create a model:

    CREATE MODEL myspace.mymodel(username: string, password: string, notes: list { type: string })
    

    The rough representation for this in Rust would be:

    pub struct MyModel {
     username: String,
     password: String,
     notes: Vec<String>,
    }
    
  3. INSERT some data:

    INSERT INTO mymodel('sayan', 'pass123', [])
    
  4. UPDATE some data:

    UPDATE mymodel SET notes += "my first note" WHERE username = 'sayan'
    
  5. SELECT some data

    SELECT * FROM mymodel WHERE username = 'sayan'
    
  6. Modify and run your own queries to understand how things work. And then make sure you read the documentation learn BlueQL.

For a complete guide on Skytable, it's architecture, BlueQL, queries and more we strongly recommend you to read the documentation here.

While you're seeing strings and other values being used here, this is so because the REPL client smartly parameterizes queries behind the scenes. BlueQL has mandatory parameterization. (See below to see how the Rust client handles this)

Find a client driver

You need a client driver to use Skytable in your programs. Officially, we maintain a regularly updated Rust client driver which is liberally license under the Apache-2.0 license so that you can use it anywhere.

Using the Rust client driver, it's very straightforward to run queries thanks to Rust's powerful type system and macros:

use skytable::{Config, query};

fn main() {
    let mut db = Config::new_default("username", "password").connect().unwrap();
    let query = query!("select username, password from myspace.mymodel where username = ?", "sayan");
    let (username, password): (String, Vec<u8>) = db.query_parse(&query).unwrap();
    // do something with it
}

You can find more information on client drivers on this page. If you want to help write a client driver for your language of choice, we're here to support your work. Please reach out to: hey@skytable.io or leave a message on our Discord server.

Getting help

We exclusively use Discord for most real-time communications — you can chat with developers, maintainers, and our amazing users. Outside that, we recommend that you use our GitHub Discussions page for any questions or open a new issue if you think you've found a bug.

Contributing

Please read the contributing guide here.

Acknowledgements

Please read the acknowledgements document.

License

Skytable is distributed under the AGPL-3.0 License. You may not use Skytable's logo for other projects.

相关仓库
redis/redis

For developers, who are building real-time data-driven applications, Redis is the preferred, fastest, and most feature-rich cache, data structure server, and document and vector query engine.

COtherdatabasekey-value
redis.io
75.6k24.7k
dbeaver/dbeaver

Free universal database tool and SQL client

JavaMavenApache License 2.0sqldatabase
dbeaver.io
51.1k4.3k
surrealdb/surrealdb

A scalable, distributed, collaborative, document-graph database, for the realtime web

Rustcrates.ioOtherdatabasedistributed
surrealdb.com
32.7k1.3k
dragonflydb/dragonfly

A modern replacement for Redis and Memcached

C++Othermemcachedmulti-threading
dragonflydb.io
30.9k1.2k
mongodb/mongo

The MongoDB Database

C++Otherc-plus-plusdatabase
mongodb.com
28.5k5.8k
valkey-io/valkey

A flexible distributed key-value database that is optimized for caching and other realtime workloads.

CBSD 3-Clause "New" or "Revised" Licensecachedatabase
valkey.io
26.6k1.2k
pubkey/rxdb

The local-first database that runs on every JS runtime and replicates with your existing backend - no vendor, no lock-in - https://rxdb.info/

TypeScriptnpmApache License 2.0databasenosql
rxdb.info
23.3k1.2k
neo4j/neo4j

Graphs for Everyone

JavaMavenGNU General Public License v3.0cyphergraphdb
neo4j.com
16.9k2.7k
scylladb/scylladb

NoSQL data store using the Seastar framework, compatible with Apache Cassandra and Amazon DynamoDB

C++Othernosqlc-plus-plus
scylladb.com
15.7k1.5k
arangodb/arangodb

🥑 ArangoDB is a native multi-model database with flexible data models for documents, graphs, and key-values. Build high performance applications using a convenient SQL-like query language or JavaScript extensions.

C++Othermulti-modelgraph-database
arangodb.com
14.2k884
CodisLabs/codis

Proxy based Redis cluster solution supporting pipeline and scaling dynamically

GoGo ModulesMIT Licensegoredis
13.2k2.7k
madd86/awesome-system-design

A curated list of awesome System Design (A.K.A. Distributed Systems) resources.

Creative Commons Zero v1.0 Universalrelational-databasemessage-broker
12.3k1.3k