Why does Firestore have a (seemingly small) limit of 200 on single-field index exemptions?
If anything, allowing more would only help reduce costs for the user and for Google, wouldn't it?
We need to hold that information in memory of every process that could handle a write to your database, and compare the incoming write to this list of exemptions. This creates a need for both memory management and latency impact.
There are techniques to make it easier to create least exemptions (and less configuration effort for you!). For example, Maps/Objects let you create your own defaults pretty easily.
For example, add a single exemption for a field called for arguments sake _auto_off_, and set all indexes off. Use the field as a map and now every new field in that map will be not indexed without needing an exemption for that new field.
If you decide you do need to query against a field in this map, you can create an exemption for that field in the map explicitly, such as _auto_of_.ranking.

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With