Skip to content

Kjoedicker/rusty-key

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation


Rusty-Key

A simple key/value store


· Report Issue · Request Feature

About The Project

rusty-key leverages actix_web for communicating requests to the native underlying HashMap that hosts everything. Data is persisted by default with a AOF system that helps keep and rebuild an event log of the data as it populates.

Like a key, this Rust based Key/Value store that aims to be simple and efficient, even if its a little rough around the edges.

API

  • GET /key
    • 200 = the associated value
    • 404 = Key not found
  • PUT /key
    • 201 = creation
  • DELETE /key
    • 200 = deletion
    • 404 = Key not found

Usage

#  Returns `201` indicating the provided key was assigned the provided value
curl --location --request PUT 'http://localhost:8080/someKey' \
--header 'Content-Type: application/json' \
--data-raw '{
    "value": "someValue"
}'

# Returns `200` and the associated value or `404` if the key does not exist.
curl --location --request GET 'http://localhost:8080/1'

# Return `200` indicating the key was deleted or `404` if the key does not exist
curl --location --request DELETE 'http://localhost:8080/someKey'

forthebadge

About

Rust based Key Value Store

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages