diff --git a/README.md b/README.md index e4ac4b14..14603d02 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,11 @@ Use Elasticell as Redis. You can replace Redis with Elasticell to power your app Grow Elasticell as your business grows. You can increase the capacity simply by adding more machines. - __Strong consistent persistence storage__ -You can think of Elasticell as a single-machine NoSQL which provide 7*24 service and has zero downtime. Elasticell put your data on multiple machines as replication without worrying about consistency. Elasticell makes your application use redis as a database and not just only the cache. +Elasticell put your data on multiple machines as replication without worrying about consistency. Elasticell makes your application use redis as a database and not just only the cache. + +- __High availability__ +All of the three components, PD, Cell and Proxy, can tolerate the failure of some instances without impacting the availability of the entire cluster. + ## Roadmap diff --git a/docs/ROADMAP.md b/docs/ROADMAP.md index 10ffade5..15af1e5e 100644 --- a/docs/ROADMAP.md +++ b/docs/ROADMAP.md @@ -6,6 +6,7 @@ This document defines the roadmap for Elasticell development. - [x] Multi-Raft - [x] Redis protocol - [x] RocksDB +- [ ] Go,Java,Python redis lib - [ ] Prometheus - [ ] PD admin UI - [ ] Index \ No newline at end of file diff --git a/docs/architecture/concept.md b/docs/architecture/concept.md index e69de29b..297d0ca7 100644 --- a/docs/architecture/concept.md +++ b/docs/architecture/concept.md @@ -0,0 +1,40 @@ +## Concept +To better understand Elasticell’s architecture, you need to understand the Elasticell concept. + +### Store +Store is a service that runs on a single disk. A store manage many cells, and provide data storage for cells, and dispatch messages to cells. + +### Cell +A cell manage some data in range of [start, end), every cell has some replication on different stores, we called these replications Peer. All cell replications with has same id makes up a raft group. Cell's peer maybe scheduled by PD move to another store, or removed from the store. + +A cell has three meta data: + +1. ID, The uniquely identifies of a cell + +2. Data range, Decide which data is managed by the cell + +3. Peers, Cell replications + +4. Epoch, The version of the cell, it will increase every time the peers changes or cell split + +In the raft group, number of cell replications needs to be set an odd number. Usually it is recommended to set to 3 at least. + +### PD (Placement Driver) +PD is the managing component of the entire cluster and is in charge of the following two operations: + +1. Storing the metadata of the cluster such as the cell location of a specific key. + +2. Scheduling and load balancing cells in the store cluster, including but not limited to data migration and Raft group leader transfer. + +As a cluster, PD needs to be deployed to an odd number of nodes. Usually it is recommended to deploy to 3 online nodes at least. + +### Proxy (optional component) +The Proxy server is used for proxy the read and write operation for external application. The proxy is in charge of the following three operations: + +1. Sync cells metadata to local from PD + +2. Receive read and write operation from external application, and forward these operations to the correct store according to metadata and the key. + +3. Receive the response from the store, and forwarding it to the external application. Resynchronize the metadata from PD when an raft error occurs, and retry forward the operation. + +The proxy is stateless and can be scaled. \ No newline at end of file diff --git a/docs/architecture/index.md b/docs/architecture/index.md new file mode 100644 index 00000000..1661306d --- /dev/null +++ b/docs/architecture/index.md @@ -0,0 +1,18 @@ +## Architecture +To better understand Elasticell’s features, you need to understand the Elasticell architecture. + +![architecture](../imgs/architecture.png) + +The Elasticell has threee components: PD server, cell server, and proxy server. + +### __Compatible with Redis protocol__ +Use Elasticell as Redis. You can replace Redis with Elasticell to power your application without changing a single line of code in most cases([unsupport-redis-commands](./unsupport-command.md)). + +### __Horizontal scalability__ +Grow Elasticell as your business grows. You can increase the capacity simply by adding more machines. + +### __Strong consistent persistence storage__ +Elasticell put your data on multiple machines as replication without worrying about consistency. Elasticell makes your application use redis as a database and not just only the cache. + +### __High availability__ +All of the three components, PD, Cell and Proxy, can tolerate the failure of some instances without impacting the availability of the entire cluster. \ No newline at end of file diff --git a/docs/imgs/architecture.png b/docs/imgs/architecture.png index 7333acc1..8d54d5d2 100644 Binary files a/docs/imgs/architecture.png and b/docs/imgs/architecture.png differ diff --git a/docs/index.md b/docs/index.md index 837b3fec..06dd697d 100644 --- a/docs/index.md +++ b/docs/index.md @@ -2,11 +2,14 @@ Elasticell is a distributed NoSQL database with strong consistency and reliability. -- __Compatible with Redis protocol__ +### __Compatible with Redis protocol__ Use Elasticell as Redis. You can replace Redis with Elasticell to power your application without changing a single line of code in most cases([unsupport-redis-commands](./unsupport-command.md)). -- __Horizontal scalability__ +### __Horizontal scalability__ Grow Elasticell as your business grows. You can increase the capacity simply by adding more machines. -- __Strong consistent persistence storage__ -You can think of Elasticell as a single-machine NoSQL which provide 7*24 service and has zero downtime. Elasticell put your data on multiple machines as replication without worrying about consistency. Elasticell makes your application use redis as a database and not just only the cache. \ No newline at end of file +### __Strong consistent persistence storage__ +Elasticell put your data on multiple machines as replication without worrying about consistency. Elasticell makes your application use redis as a database and not just only the cache. + +### __High availability__ +All of the three components, PD, Cell and Proxy, can tolerate the failure of some instances without impacting the availability of the entire cluster. \ No newline at end of file diff --git a/mkdocs.yml b/mkdocs.yml index dc885ac8..4ab1c6f2 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -7,7 +7,7 @@ pages: - Quick Start: user-guide/quick-start.md - Installation: user-guide/installation.md - Configuation: user-guide/configuration.md -- Architecture: +- Architecture: architecture/index.md - Concept: architecture/concept.md - PD: architecture/pd.md - Cell: architecture/cell.md