Valkey Integration¶
Real-time synchronization of FPS parameters across multiple hosts via a Valkey key-value store.
See also: FPS · Performance Tuning · Programmer's Guide
Overview¶
milk-fps-valkey is a standalone bridge that
bidirectionally syncs FPS parameters between local
shared memory and a central Valkey (or Redis) server.
This enables:
- Multi-host parameter sharing: FPS changes on one machine instantly appear on all others.
- Remote monitoring and control: inspect or modify parameters from any machine on the network.
- External tool integration: any Valkey client (Python, Node.js, CLI) can read/write FPS parameters.
Host A Valkey Server Host B
┌──────────┐ ┌──────────────┐ ┌──────────┐
│ FPS SHM │◄────────►│ fps:hostA:* │◄────────►│ FPS SHM │
│ │ push/ │ fps:hostB:* │ push/ │ │
│ milk-fps-│ pull │ │ pull │ milk-fps-│
│ valkey │ │ PubSub │ │ valkey │
└──────────┘ └──────────────┘ └──────────┘
Quick Start¶
1. Start Valkey¶
2. Start FPS Processes¶
3. Start the Sync Bridge¶
All local FPS parameters are now mirrored to Valkey.
4. Multi-Host¶
On each host, point to the same Valkey server:
Key Features¶
| Feature | Description |
|---|---|
| Bidirectional sync | Changes propagate both ways |
| Low-latency pull | PubSub notifications (ms) |
| Echo prevention | Local changes are not re-applied |
| Auto-reconnect | Recovers from Valkey restarts |
| Regex filtering | Sync only matching FPS names |
Common Options¶
| Option | Default | Description |
|---|---|---|
-V, --valkey-host |
127.0.0.1 |
Valkey server address |
-P, --valkey-port |
6379 |
Valkey server port |
-i, --interval |
0.1 |
Poll interval (seconds) |
-h, --help |
— | Show help |
Detailed Documentation¶
For full architecture details, key schema, PubSub protocol, troubleshooting, and C API reference, see the comprehensive README:
Building¶
milk-fps-valkey is not built by default. It
requires libvalkey as an additional dependency:
See
src/fpsvalkey/README.md
for detailed build instructions and prerequisites.