Tell HN: Memcached and Redis Considered Harmful

6 points by welder ↗ HN
It's 2021 and we have extremely fast key-value lookups using LevelDB/RocksDB, but we're still using RAM-based caching tools [1] [2] [3]. It's time to consider RAM-based caching harmful, and start caching with SSDs for larger datasets and lower costs. For ex: SSDB [4]

[1] https://redis.io/

[2] https://memcached.org/

[3] https://news.ycombinator.com/item?id=29532552

[4] https://github.com/ideawu/ssdb#ssdb-vs-redis

5 comments

[ 4.4 ms ] story [ 20.8 ms ] thread
what is your argument for it being harmful?
Except people don't only use Redis for caching or having a fast key-value database.

Redis is also a very convenient way to share a state between multiple instances of our software that need to have access to the same data.

Just like we would have some dicts/lists/sets in RAM (in the heap) during the runtime of a single instance, we have that stuff in Redis so we can share data between multiples remote processes. That's it. (And it makes sense to keep that stuff in RAM, I guess.)

We wouldn't use an SSD/long-term storage to keep heap memory of a running program, right? ;)

>Redis is also a very convenient way to share a state between multiple instances of our software that need to have access to the same data.

Aren't there better tools for this? etcd, consul, zookeeper etc.

I have the feeling (I might be wrong) that etcd, etc., would be more suited for long-lived state/data. What we need is a pretty short-lived shareable state. The data is very transient.
I don't get it. What is harmful? [3] had a comment talking about lacking battle tested maturity of ssdb and [4] shows less performance in writes and a very, very minor improvement in reads for ssdb.