Support fallbackToSourceOfTruth on fresh requests
Adds a new fallbackToSourceOfTruth parameter on StoreRequest.fresh to let stream fallback to source of truth in case fetcher returns an error.
Implements https://github.com/dropbox/Store/issues/394
I am looking forward to this feature.
I am a little concerned about distinguishing between network error + data and a terminating network error. I typically need to take alternative action if there is a network error without data.
The way it is constructed now, there might or might not be a subsequent data emission. (I'm thinking about the case of using as a fresh or tryFresh request as opposed to collecting a flow.) My initial thought is that if it falls back to the disk that only a data emission is received with some sort of source information saying it came as a result of fallback to SoT.
On the other hand, I suppose for some users the type of network error might be important.
With #545 merged I think we can close this. Thanks all 🙏🏽