-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
1 parent
a97ca89
commit 2702ab5
Showing
7 changed files
with
109 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
61 changes: 61 additions & 0 deletions
61
...docs/src/mdbook/src/dataplane/tasks2/configuration-persistence-investigation.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# Configuration persistence | ||
|
||
We need to officially pick a data store for configuration information. | ||
|
||
This data store _is not_ intended for storing "fast" state. | ||
Rather, this store needs to hold configuration data which is | ||
|
||
1. durable | ||
2. atomic | ||
3. strongly typed | ||
4. immediately consistent | ||
|
||
## etcd | ||
|
||
[`etcd`] is a reasonable choice because | ||
|
||
1. It is already in use in kubernetes and is therefore likely to be well-maintained and tested. | ||
2. we are already using / integrating with kubernetes so any flaws in `etcd` are likely to impact us anyway. | ||
|
||
I have used [`zookeeper`](https://zookeeper.apache.org/) in the past and *strongly recommend against it*. | ||
|
||
I would also consider [`consul`](https://github.com/hashicorp/consul) but [the license](https://github.com/hashicorp/consul/blob/main/LICENSE) is *_not_* acceptable. | ||
|
||
A newer entry in the space is [`nacos`](https://github.com/alibaba/nacos) but I think it is less well suited since it only seems to support eventual consistency. | ||
|
||
## rqlite | ||
|
||
_I have not used [`rqlite`],_ but it seems to be a reasonable (if young) option. | ||
My biggest concern is that [transactions](https://rqlite.io/docs/api/api/#transactions) support seems _very_ weak. | ||
|
||
- has a supported [rust client](https://github.com/tomvoet/rqlite-rs) (and even a [sqlx](https://github.com/launchbadge/sqlx) client in the form of [sqlx-rqlite](https://crates.io/crates/sqlx-rqlite)) | ||
- [weak](https://rqlite.io/docs/api/read-consistency/#weak), [linearizable](https://rqlite.io/docs/api/read-consistency/#linearizable), and [strong](https://rqlite.io/docs/api/read-consistency/#strong) consistency models supported | ||
- [transactions](https://rqlite.io/docs/api/api/#transactions) (this seems less than ideal tho) | ||
|
||
## TiKV | ||
|
||
[TiKV] seems like the **strongest near-term option** on the list. | ||
|
||
I think that the biggest advantage is in the case that we want to _eventually_ switch to [TiDB]. | ||
That strategy allows us the most flexibility to use a "real" database in the future while using a "simple" KV database in the near term. | ||
|
||
## TiDB | ||
|
||
[TiDB] is a [MySQL] compatible [distributed SQL] database built on top of [TiKV]. | ||
|
||
The thing which I find most striking about this database is the excellent documentation and robust feature set (robust all things considered). | ||
|
||
- [Generated columns](https://docs.pingcap.com/tidb/dev/generated-columns) | ||
- [JSON](https://docs.pingcap.com/tidb/dev/data-type-json) | ||
- [Referential integrity](https://docs.pingcap.com/tidb/dev/foreign-key) | ||
- [Transactions](https://docs.pingcap.com/tidb/dev/transaction-overview) | ||
- [Views](https://docs.pingcap.com/tidb/dev/views) | ||
- [Change data capture](https://docs.pingcap.com/tidb/stable/ticdc-overview) | ||
|
||
## Summary | ||
|
||
Thus, I think the real choice is between [`etcd`], [TiDB], and [TiKV]. | ||
|
||
That choice comes down to how much we value the functionality of sql (multiple indexes, referential integrity, strong schema) vs. the upsides of kv databases (watches, more easily evolved schema). | ||
|
||
{{#include ../../links.md}} |
25 changes: 25 additions & 0 deletions
25
design-docs/src/mdbook/src/dataplane/tasks2/dataplane-worker-lifecycle.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Dataplane worker lifecycle | ||
|
||
This is mostly a design task at this point. | ||
|
||
Things which need to be worked out and documented: | ||
|
||
1. communication pattern between workers | ||
2. communication pattern between workers and the control plane | ||
3. communication pattern between workers and the management plane | ||
4. communication pattern between workers and the telemetry / monitoring subsystems | ||
|
||
In each case, we need to consider | ||
|
||
1. performance impact, | ||
2. thread safety, | ||
3. design simplicity, | ||
4. transactionality, | ||
5. extensibility. | ||
|
||
## Likely dispatch | ||
|
||
- primary: [@daniel-noland] | ||
- sync with: [@sergeymatov] | ||
|
||
{{#include ../../links.md}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Route manager | ||
|
||
This is basically a big TODO. | ||
|
||
For the moment, I would like to get some more precise feature definition from [@sergeymatov]. | ||
|
||
It is also important to align this task with the [dataplane worker lifecycle]. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# Telemetry (basic) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters