Page MenuHomePhabricator

[native] Retry feature flags call
ClosedPublic

Authored by tomek on Jul 31 2023, 7:26 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Nov 4, 8:51 PM
Unknown Object (File)
Fri, Nov 1, 7:23 AM
Unknown Object (File)
Fri, Nov 1, 7:23 AM
Unknown Object (File)
Fri, Nov 1, 7:23 AM
Unknown Object (File)
Fri, Nov 1, 7:21 AM
Unknown Object (File)
Fri, Nov 1, 4:09 AM
Unknown Object (File)
Oct 6 2024, 11:00 AM
Unknown Object (File)
Oct 6 2024, 10:45 AM
Subscribers

Details

Summary

Retry feature flags call. If number of tries is exceeded, rethrow an error.

Depends on D8652

Test Plan

Add console logs and simulate failed requests - the requests should be retried up to numberOfTries times with delays.

Diff Detail

Repository
rCOMM Comm
Branch
feature-flags-timeout
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

tomek requested review of this revision.Jul 31 2023, 9:11 AM
native/components/feature-flags-provider.react.js
111 ↗(On Diff #29277)

You can skip last sleep because there will be no more retries from then, it only delays the rethrow

Avoid sleep before throwing

native/components/feature-flags-provider.react.js
111 ↗(On Diff #29277)

Yeah, you're obviously right

This revision is now accepted and ready to land.Aug 1 2023, 6:47 AM
This revision was automatically updated to reflect the committed changes.