htcache -a 0.0.0.0 -p 9000
PUT /<cache-key>
Content-Type: <content-type>
X-TTL: <ttl>
curl -XPUT http://localhost:3030/test --header "Content-Type: text/plain" --header "X-TTL: 120" --data-binary="hello world"
GET /<cache-key>
curl -XGET http://localhost:3030/test
This demo application uses the following techniques and libraries:
- "Warp" for creating an lightweight HTTP server with REST interface
- "Clap" for creating a nice command line interface
- "Tokio" to run the garbage collector asynchronous
- "Serde" and "Serde JSON" to serialize and deserialize the cache