@@ -10,6 +10,20 @@ application.
1010** Disclaimer** Don't even think about trying to use this in production... just
1111don't.
1212
13+ ## Why Redis
14+
15+ The primary goal of this project is teaching Tokio. Doing this requires a
16+ project with a wide range of features with a focus on implementation simplicity.
17+ Redis, an in-memory database, provides a wide range of features and uses a
18+ simple wire protocol. The wide range of features allows demonstrating many Tokio
19+ patterns in a "real world" context.
20+
21+ The Redis wire protocol documentation can be found [ here] ( https://redis.io/topics/protocol ) .
22+
23+ The set of commands Redis provides can be found
24+ [ here] ( https://redis.io/commands ) .
25+
26+
1327## Running
1428
1529The repository provides a server, client library, and some client executables
@@ -117,6 +131,12 @@ the server to update the active subscriptions.
117131The server uses a ` std::sync::Mutex ` and ** not** a Tokio mutex to synchronize
118132access to shared state. See [ ` db.rs ` ] ( src/db.rs ) for more details.
119133
134+ ### Testing asynchronous code that relies on time
135+
136+ In [ ` tests/server.rs ` ] ( tests/server.rs ) , there are tests for key expiration.
137+ These tests depend on time passing. In order to make the tests deterministic,
138+ time is mocked out using Tokio's testing utilities.
139+
120140## Contributing
121141
122142Contributions to ` mini-redis ` are welcome. Keep in mind, the goal of the project
@@ -128,6 +148,9 @@ demonstrate a new pattern.
128148
129149Contributions should come with extensive comments targetted to new Tokio users.
130150
151+ Contributions that only focus on clarifying and improving comments are very
152+ welcome.
153+
131154## FAQ
132155
133156#### Should I use this in production?
0 commit comments