https://github.com/casey/worm
Write once read many key value storage service
https://github.com/casey/worm
Last synced: 11 months ago
JSON representation
Write once read many key value storage service
- Host: GitHub
- URL: https://github.com/casey/worm
- Owner: casey
- License: other
- Created: 2014-09-09T21:46:28.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2014-10-04T11:43:12.000Z (over 11 years ago)
- Last Synced: 2025-02-14T01:18:27.049Z (over 1 year ago)
- Language: Go
- Homepage:
- Size: 211 KB
- Stars: 1
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
WORM
====
Write once read many key value storage service
[Test instance here.](http://rodarmor-worm.appspot.com)
API
---
KEYs match `/[a-zA-Z0-9.-_]+/`.
* `PUT /KEY` -> Associates KEY with data in request. Puts after the first will be ignored.
* `GET /KEY` -> Returns the data associated with KEY.
```
> curl -X PUT http://rodarmor-worm.appspot.com/hello --data 'bob'
bob
> curl -X PUT http://rodarmor-worm.appspot.com/hello --data 'frank'
403 Forbidden
> curl -X GET http://rodarmor-worm.appspot.com/hello
bob
```
About
-----
KEYs can be any length, but data is limited to 64 bytes just to avoid too much spam in the test instance datastore.
The sha256 hash of KEYs are used as datastore string IDs, instead of the KEY itself. This allows keys to be arbitrarily long, since they aren't actually stored in the datastore. Also, this lessens the severity of a [potential attack vector](http://ikaisays.com/2011/01/25/app-engine-datastore-tip-monotonically-increasing-values-are-bad/).