Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/birkenfeld/cache-rs
Experimental NICOS cache implementation in Rust
https://github.com/birkenfeld/cache-rs
Last synced: 19 days ago
JSON representation
Experimental NICOS cache implementation in Rust
- Host: GitHub
- URL: https://github.com/birkenfeld/cache-rs
- Owner: birkenfeld
- Created: 2015-07-03T08:22:55.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2024-10-03T13:27:18.000Z (3 months ago)
- Last Synced: 2024-10-31T10:43:04.272Z (2 months ago)
- Language: Rust
- Homepage:
- Size: 231 KB
- Stars: 1
- Watchers: 5
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# cache-rs
A Rust implementation of the [NICOS](http://nicos-controls.org) cache server and
protocol.## Building
cargo build --release
should download all required dependencies.
## Basic usage
cargo run --release -- [options]
Options are:
Usage: cache-rs [options]
cache-rs --helpA Rust implementation of the NICOS cache.
Options:
-v Debug logging output?
--bind ADDR Bind address (host:port) [default: 127.0.0.1:14869]
--store STOREPATH Store path or URI [default: data]
--log LOGPATH Logging path [default: log]
--pid PIDPATH PID path [default: pid]
-d Daemonize?
--user USER User name for daemon
--group GROUP Group name for daemon
--clear Clear the database on startup?## Stores
There are two history store backends supported: flat files and PostgreSQL.
* For flat files, the `--store` path should be a simple directory path.
* For Postgres, it should be `postgresql://user@host/database`.
When you have created the database, run once with `--clear` to create the
schema.## Benchmarks
Use
python bench.py -n <#keys> -s <#clients>
Useful benchmarks are:
python bench.py ask_only -n 100000
python bench.py single_writer -n 20000 -s 25
python bench.py multi_writer -n 20000 -s 25
python bench.py udp -n 10000**Take care** to restart the cache with `--clear` after each benchmark to get
reproducible numbers. The large amount of messages degrades hashtable
performance for subsequent benchmarks.