What performance considerations should you keep in mind when enabling TLS on a high throughput Redis deployment?
Short answer
TLS introduces some additional CPU overhead for encrypting and decrypting traffic and a small amount of latency for the initial handshake, so on very high throughput systems it helps to use connection pooling to avoid repeated handshakes, ensure the server hardware has adequate…
Advertisement
AModel answer
TLS introduces some additional CPU overhead for encrypting and decrypting traffic and a small amount of latency for the initial handshake, so on very high throughput systems it helps to use connection pooling to avoid repeated handshakes, ensure the server hardware has adequate CPU capacity, and benchmark the actual impact under realistic load before rolling it out broadly.
redis-benchmark -h redis.example.com -p 6379 --tls \
--cert client.crt --key client.key --cacert ca.crt -qReal-world example
A high traffic gaming platform benchmarks its Redis cluster with and without TLS enabled, confirming that connection pooling in its client library keeps the added latency low enough to remain within acceptable limits.
Likely follow-ups
- How does TLS overhead compare between using it for internal cluster traffic versus client to server traffic?
- Are there hardware acceleration options for TLS encryption?
Related topics