Blog
2 min readNexrade

nexrade-cache — Redis-compatible cache for trading bots (Windows, no WSL)

Run a Redis-protocol cache natively on Windows without WSL or Docker. Rust + RESP2/3, and why it is a better fit for local trading bots than shipping a full Redis install.

nexrade-cache · redis · windows · infrastructure

Bots that re-fetch the same orderbook every 200 ms do not need a full Redis cluster. They need a fast, local, protocol-compatible cache that starts in one command — including on a Windows trading box where you do not want WSL.

nexrade-cache is a Redis-compatible server written in Rust: RESP2/3, TLS via rustls, Prometheus metrics, and an optional WebAssembly target. Same redis-cli / client libraries you already use.

Why Windows (and why not WSL)

Many trading setups run on Windows VPS or dual-boot desktops. Official Redis still points Windows users at WSL, Memurai, or third-party ports. That means:

  • Extra VM layer and disk I/O for every key op
  • Different networking story (localhost vs WSL IP)
  • Heavier install for a bot that only needs a few thousand keys

nexrade-cache ships as a native Windows binary (and Linux). No WSL, no Docker required for local use. Point redis_host / redis_port at 127.0.0.1:6379 and your Python stack keeps working.

Performance

On single-key workloads (SET / GET / INCR) under loopback load, nexrade-cache is typically ~10–13% faster than Redis 7.0.15 in the same class of test (redis-benchmark -c 50 -n 100000 -q, no TLS). Exact numbers depend on CPU and build flags — the important part is not trading away Redis protocol compatibility for that gain.

Use it when:

  • Sub-ms local cache latency matters more than Redis Cluster features
  • You want one process next to the bot, not a managed Redis bill
  • Windows hosts should not pull in WSL just for caching

When you need clustering, AOF/RDB durability guarantees, or a managed fleet — use Redis proper. nexrade-cache is the sharp tool for the common bot case.

Install

Binary (Linux / macOS)

curl -fsSL https://raw.githubusercontent.com/nexrade/nexrade-cache/main/install.sh | bash

Windows

Download the Windows release asset from GitHub Releases (or build from source with a Rust toolchain). Run the executable; it listens on 6379 by default. No WSL, no Hyper-V dependency for the happy path.

# after placing the binary on PATH
nexrade-cache
redis-cli ping
# PONG

Docker (any OS)

docker run -p 6379:6379 nexrade/nexrade-cache

Fit with the nexrade trading library

The nexrade library can use Redis for orderbooks, tickers, balances, orders, and klines — namespaced per exchange and account. On Windows, nexrade-cache is the drop-in server:

import nexrade

binance = nexrade.Binance({
    "redis_host": "127.0.0.1",
    "redis_port": 6379,
})
print(binance.get_price("BTCUSDT"))

Optional remote config:

binance = nexrade.Binance({
    "redis_host": "redis.internal",
    "redis_port": 6380,
    "redis_password": "secret",
    "redis_index": 1,
})

Disable caching entirely with enable_cache=False if every read should hit the network.

When to use it

  • Windows bot hosts without installing Redis via WSL
  • Local development and single-node edge deploys
  • Shared cache between multiple bot processes on one machine
  • CI / SSH / Docker logs workflows that still speak Redis protocol

Skip it when you need multi-node clustering, strict persistence SLAs, or a managed Redis product.

Want to try the path this note describes? Create a free API key, or return to the full list of notes.