Comment

Comment by canadi

add_docs() API always UPSERTS and so yes, updates are through "_id". The system auto-assigns an "_id" only when it is not supplied by the user or when an existing field is not mapped as the "_id" field at collection creation time. You will have to use delete_docs() before add_docs(), if you want replace-document behavior.

Our backend architecture is quite scalable and actually grows and shrinks with the demand continuously.

And yes, all documents are automatically indexed and replicated for fast query performance, which is more expensive than just storing them in "_id"->"doc" format. For our use cases and value prop, this one time indexing cost pays for itself several times over by saving time during query processing.

parent canadi 8 years ago

No comments yet

Be the first to share your thoughts.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton