Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/robinbraemer/cacher
cacher - testing out gRPC
https://github.com/robinbraemer/cacher
Last synced: 27 days ago
JSON representation
cacher - testing out gRPC
- Host: GitHub
- URL: https://github.com/robinbraemer/cacher
- Owner: robinbraemer
- Created: 2019-04-28T13:18:31.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-12-15T15:00:35.000Z (11 months ago)
- Last Synced: 2024-06-20T20:33:00.808Z (5 months ago)
- Language: Go
- Homepage:
- Size: 31.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# cacher
I'm trying out gRPC and have made a mem-cache and a small performance test.
Get it:
```
git clone https://github.com/robinbraemer/cacher.git && cd cacher
```Run the server:
```
go run server/*
```Run the client:
```
go run client/*
```**Commands:**
- set [key] [string] - Sets an entry
- get [key] - Gets an entry
- del [key] - Deletes an entry
- all - Gets all entries using server-side stream
- empty - Empty the cache
- clear - Clear console
- fill [count] - Fills the cache and benefits from HTTP/2 connection reuse
- slow-fill [count] - Fills the cache without connection reuse**Results on my PC**
- `fill-slow 10000` takes `10.481s` to `14.674s`
- `fill 10000` takes `2s` to `3.341s`