starter_architecture_flutter_firebase icon indicating copy to clipboard operation
starter_architecture_flutter_firebase copied to clipboard

Using advanced Firestore features (e.g. transactions, batched writes, etc.)

Open amitkot opened this issue 4 years ago • 1 comments

TL;DR

what about Firestore transactions, batched writes, field value operations (e.g. FieldValue.arrayUnion)?

Long version

First off, thank for this repo! I have been developing apps in Flutter and it is refreshing to see a different take on app architecture. I have learnt a lot from your work.

I am considering the abstraction you use for working with Firestore db. The approach of viewing it as a CRUD db makes testing easier and also probably migrating to a different db possible.

This abstraction, however, comes at the cost of not having access to the Firestore's advanced features such as transactions, batched writes, field operations such as FieldValue.arrayUnion(), FieldValue.increment(), etc.

I'm interested to know how would you approach exposing these features while still aiming for testability and portability.

amitkot avatar Jan 05 '21 08:01 amitkot

@bizz84 I would love to hear your opinion on this topic!

amitkot avatar Mar 24 '21 10:03 amitkot