Repository navigation
v2.0.1
BoltCache 2.0 is a ground-up rework: it now works with redis-cli, redis-benchmark and Redis client libraries, and it's about 2x faster than 1.0. This patch release makes go install work and restores the release notes that were missing from 2.0.0.
Fixed in 2.0.1
go install github.com/wutlu/boltcache/v2@latestworks. Go requires a/v2suffix in the module path of v2+ releases, so the module path is nowgithub.com/wutlu/boltcache/v2.- Release notes are included in GitHub releases again.
What's new in 2.0
- Redis compatible: 120 commands over RESP: strings, lists, sets, hashes, TTL/
SCAN, pub/sub,MULTI/EXEC/WATCH,INFO... 1.x answered onlyPING/SET/GETand hung on everything else. - Real Lua scripting with
EVAL/EVALSHA. Scripts are atomic, sandboxed and time-limited. - Eviction:
max_memoryandmax_keysare enforced withlru,lfu,random,ttlornoeviction. - Crash-safe persistence: types and binary data survive restarts, and 1.x data files are converted automatically.
- Security: token auth is now actually enforced on REST, RESP and TCP. There's also CSRF protection, rate limiting and TLS for HTTP.
- Ops: Prometheus
/metrics,/health, JSON logs, a multi-arch distroless Docker image, and binaries for Linux, macOS, Windows and FreeBSD. - Fixes for data races, data loss after restarts, dropped commands and an XSS in the web client.
On an M1 Pro with redis-benchmark, BoltCache is ahead of Redis 8.4: +5–10% without pipelining and 1.25–2x with pipeline 16.
⚠️ Upgrading from 1.x
- Authentication is enforced when
security.auth.enabledis true. - Writing a different type to an existing key returns
WRONGTYPE. - Port 6381 and the
clustercommand were removed. cors_originsdefaults to same-origin.
See the full changelog and the README's Upgrading from 1.x section.
Install
docker run -d -p 6382:6382 -p 8090:8090 -v boltcache-data:/data ghcr.io/wutlu/boltcache:2.0.1
go install github.com/wutlu/boltcache/v2@v2.0.1Or download a binary below. Then: redis-cli -p 6382 PING.