Re:MongoDB: How to Use the JSON Schema Validator
by amarkov on Wednesday August 22, 2018 @08:49PM
(#17823614)
Schemaless databases are good for scenarios where the database isn't a source of truth. If you have a table full of e.g. per-second heartbeats from a bunch of deployed services, there's no fundamental underlying truth anyone's trying to gather from it, and you can't afford to run a full schema migration every time someone adds a new metric.
I recognize some people do try to use schemaless databases in the way you're describing, and I agree that's weird and dangerous.
Seems like a recipe for disaster to me, but well... A database isn't a "storage format". It's most often the single source of truth for a set of information.
Not being fully sure what data you expect from that source of truth and yet being able to query it is really dangerous. What if you start to update this data after having nullified things you didn't understand ?