4 ms·
I know nothing about Cassandra. I question however the ability of Redis to index JSON fields and store/retrieve the JSON document in a way that is easy to prog
by hoodoof 11y ago
I know nothing about Cassandra.
I question however the ability of Redis to index JSON fields and store/retrieve the JSON document in a way that is easy to program and reason about. I'm not an expert though so can you please correct me?
- aidos 11y agoThe JSON field isn't being indexed or reasoned about - it's just a text blob. This is a pure KV model.
- hoodoof 11y agoActually the article has two references to using fields for indexing, one which says: "Fields only exist to be indexed. If a field is not needed for an index, store it in one blob/text field (such as JSON or XML)."
- keyanp 11y agoCassandra is optimized for write heavy workloads, inverse to MySQL. It also effortlessly scales horizontally and is designed to do so. The use case is clear and definitely different than that of MySQL. As for the second point, you can store the JSON data in a Redis "hash" datatype: https://matt.sh/introduction-to-redis-data-types https://matt.sh/introduction-to-redis-data-types Although MySQL also supports in-memory KV storage with (nearly?) constant time lookups (http://dev.mysql.com/doc/refman/5.7/en/innodb-adaptive-hash.html http://dev.mysql.com/doc/refman/5.7/en/innodb-adaptive-hash....), I think Redis is a bit easier to partition.