{"id":16369730,"url":"https://github.com/dcsunset/distributed-serverless-kv","last_synced_at":"2026-03-03T17:30:16.658Z","repository":{"id":91210711,"uuid":"276816650","full_name":"DCsunset/distributed-serverless-kv","owner":"DCsunset","description":"A distributed key-value store with sharding for serverless applications","archived":false,"fork":false,"pushed_at":"2023-09-13T18:24:40.000Z","size":142,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-12-31T09:44:48.563Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DCsunset.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2020-07-03T05:37:58.000Z","updated_at":"2023-07-10T01:52:17.000Z","dependencies_parsed_at":"2023-09-14T09:28:41.178Z","dependency_job_id":null,"html_url":"https://github.com/DCsunset/distributed-serverless-kv","commit_stats":null,"previous_names":["dcsunset/distributed-serverless-kv"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DCsunset%2Fdistributed-serverless-kv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DCsunset%2Fdistributed-serverless-kv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DCsunset%2Fdistributed-serverless-kv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DCsunset%2Fdistributed-serverless-kv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DCsunset","download_url":"https://codeload.github.com/DCsunset/distributed-serverless-kv/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239885458,"owners_count":19713311,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-11T02:56:09.365Z","updated_at":"2025-02-20T17:40:59.646Z","avatar_url":"https://github.com/DCsunset.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# distributed-serverless-kv\n\n## Introduction\n\nThis demo is a simple in-memory distributed key-value database.\n\n**Note**:\nThe number of action invocations in OpenWhisk are limited to 60 per minute by default.\nThe default limitations can be changed in helm configuration file when deploying it.\n\n\n## Run this project\n\n(The following steps are tested on Linux.\nSome steps might differ on other platforms.)\n\nFirst, clone this repository directly to `$GOPATH/src/github.com/DCsunset/openwhisk-grpc`\nor clone it elsewhere and create a symlink in it.\n\nNext, modify the `server.json` in the `server` directory.\nSince this prototype is elastic,\nthe `initial` field means the first server to store the data.\nThe `availableServers` field means the servers available to be used later.\nThe `self` field is the address of the current machine.\nThe `servers` field shows all the servers used for the db.\nThe `threshold` field means when the key-value pairs reach the threshold,\ndata should be split and sent to other available servers.\n\nThen, start the db server in directory `server` on every machine:\n\n```\ngo run *.go\n```\n\nNext, deploy OpenWhisk (for example, k8s in docker).\n\nFinally, run `createAction.sh` in the `demo` directory to create some demo actions.\n\nTo invoke the action, change the parameters in `invokeAction.sh` and execute it.\n\n## Generate grpc code from proto\n\n```\nprotoc -I db --go_out=plugins=grpc:db db/db.proto\n```\n\n## Benchmarks\n\n### Steps\n\nTo run the benchmarking, first deploy the simple db and the distributed db.\n\nThen modify the `createAction.sh` script and run it to create the benchmark action.\n\nFinally, run the `invokeAction.sh` script to start the benchmarking.\n\n### Results\n\n(10ms delay has been added intentionally to read and write operations)\n\n| Operations       | Simple Database | Distributed Database |\n| ---------------- | --------------- | -------------------- |\n| Read Latency     | 25 ms           | 20 ms                |\n| Write Latency    | 50 ms           | 35 ms                |\n| Read Throughput  | 24 GB/s         | 16 GB/s              |\n| Write Throughput | 7 GB/s          | 11 GB/s              |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdcsunset%2Fdistributed-serverless-kv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdcsunset%2Fdistributed-serverless-kv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdcsunset%2Fdistributed-serverless-kv/lists"}