What happens when the client goes offline?

If the client has an intermittent internet connection how is this handled with fauna? Can they continue interacting with the app and it just syncs everything back up upon reconnections? Or do the operations fail and they have to wait until they get back online with a stable connection to continue?

This is not entirely clear to me. Are you talking about streaming? Since if you are not talking about streaming then the query will fail, you would receive an error and can then opt to try again. If you are talking about streaming, you will get an error in the stream and can reconnect (as done here GitHub - fauna-brecht/fauna-streaming-example)

I think it definitely makes sense to have a client-side library that does a kind of caching in the long run and know some libraries already provide such an offline caching mode. Is that what you are looking for? I don’t think we have currently something like that on the roadmap and it definitely should be super transparent to users that caching writes comes with a big risk of not being able to merge data anymore without data loss due to conflicting transactions.

Extra information:
Fauna will not cache transactions for you for them to be executed once the connection comes back. It would also make little sense considering that Fauna delivers strong consistency guarantees on transactions which means that if you write/update something, Fauna guarantees that it’s done when the call returns without an error and without potential race conditions or data loss (which can happen in other databases that don’t provide strong guarantees).

Caching transactions would mean that there might be conflicting transactions already pushed by another user by the time your ‘writes/updates’ will be synced on reconnection which throws Fauna’s guarantees overboard.