You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Firestore handles offline write requests by never completing the request's future until internet connection comes back online. This is not optimal if a person is in a low-connectivity area for a while. The app currently waits five seconds for the future to complete before assuming that Firestore is waiting, notifies the user, and then proceeds as if the request was successful, and later completes the write when the app receives internet connection again. This is not ideal either as it may suppress errors silently, and may surprise the user as write request status is currently not exposed.
One way to help remediate these problems is to expose offline writes in a queue page, so that the user is not left with surprises. Unfortunately, this still doesn't handle submission errors. Additionally, if there is no way to get Firestore's pending writes, we may have to store them ourselves--though this may allow us to handle submission errors as we will still have submissions that fail, and be able to retry.
There may be a better solution.
Also applies to recycling_checkin
Notes:
a queued write silently fails (ex. changing write rules in between a write being queued and a write going to Firestore) unless caught, but catching is difficult across app sessions and when the user has moved onto other screens by then
after going offline the Firestore plugin has no knowledge of updated security rules, and queued writes affected by updated security rules will fail
this is addressed by Firebase, and their recommended solution is ensuring the app does not rely on completed futures, and the offline write will apply once the device is reconnected. This is still somewhat troublesome; what if a queued write fails?
The text was updated successfully, but these errors were encountered:
Firestore handles offline write requests by never completing the request's future until internet connection comes back online. This is not optimal if a person is in a low-connectivity area for a while. The app currently waits five seconds for the future to complete before assuming that Firestore is waiting, notifies the user, and then proceeds as if the request was successful, and later completes the write when the app receives internet connection again. This is not ideal either as it may suppress errors silently, and may surprise the user as write request status is currently not exposed.
One way to help remediate these problems is to expose offline writes in a queue page, so that the user is not left with surprises. Unfortunately, this still doesn't handle submission errors. Additionally, if there is no way to get Firestore's pending writes, we may have to store them ourselves--though this may allow us to handle submission errors as we will still have submissions that fail, and be able to retry.
There may be a better solution.
Also applies to recycling_checkin
Notes:
The text was updated successfully, but these errors were encountered: