4 ms·
Given the restrictions I’d be curious to hear if anyone has compared the two approaches: 1. Something similar to the article 2. Use a generic key value store,
by endisneigh 4y ago
Given the restrictions I’d be curious to hear if anyone has compared the two approaches:
1. Something similar to the article
2. Use a generic key value store, pipeline the data to a rdbms like SQLite or Postgres. Use the kv store for all simple queries, delegate to the rdbms for joins/complicated queries
If you used a cluster of syclladb or foundationDB you could get similar read/write performance but those are kv stores.
If you happen to shard by customer you could duplicate keys and values into separate databases per tenant. You could effectively reindex common queries to use kv directly and have others go to rdbms.
—-
More generally I wish there was a rdbms with easily pluggable storage engines or one where you can use a key value store as the storage.
I’d trade some performance for the flexibility
- acomjean 4y agoDon't Postgres and mysql already have the Json datatype, that pretty much allows creating Key/Value stores? https://www.postgresql.org/docs/current/functions-json.html https://www.postgresql.org/docs/current/functions-json.html
- endisneigh 4y agoThe main reason to use a kv store is performance and shard-ability