Revision df3eee455c9d2a4a9698a35aa0dfe6d5d2efd53d authored by Callum Waters on 04 February 2020, 12:02:20 UTC, committed by GitHub on 04 February 2020, 12:02:20 UTC
Closes issue #4338 Uses a wrapper function around both the signedHeader and validatorSet calls to the primary provider which attempts to retrieve the information 5 times before deeming the provider unavailable and replacing the primary provider with the first alternative before trying recursively again (until all alternatives are depleted) Employs a mutex lock for any operations involving the providers of the light client to ensure no operations occurs whilst the new primary is chosen. Commits: * created swapProvider function * eliminates old primary provider after replacement. Uses a mutex when changing providers * renamed to replaceProvider * created wrapped functions for signed header and val set * created test for primary provider replacement * implemented suggested revisions * created Witnesses() and Primary() * modified backoffAndJitterTime * modified backoffAndJitterTime * changed backoff base and jitter to functional arguments * implemented suggested changes * removed backoff function * changed exp function to match go version * halved the backoff time * removed seeding and added comments * fixed incorrect test * extract backoff timeout calc into a function Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
1 parent 9b9f1be
File | Mode | Size |
---|---|---|
.vuepress | ||
app-dev | ||
architecture | ||
guides | ||
imgs | ||
interviews | ||
introduction | ||
networks | ||
ru | ||
tendermint-core | ||
tools | ||
.python-version | -rw-r--r-- | 7 bytes |
.textlintrc.json | -rw-r--r-- | 137 bytes |
DEV_SESSIONS.md | -rw-r--r-- | 5.7 KB |
DOCS_README.md | -rw-r--r-- | 3.1 KB |
README.md | -rw-r--r-- | 1.4 KB |
package-lock.json | -rw-r--r-- | 417.0 KB |
package.json | -rw-r--r-- | 549 bytes |
post.sh | -rwxr-xr-x | 56 bytes |
pre.sh | -rwxr-xr-x | 158 bytes |
stop-words.txt | -rw-r--r-- | 85 bytes |
tendermint-core-image.jpg | -rwxr-xr-x | 122.6 KB |
versions | -rw-r--r-- | 7 bytes |
Computing file changes ...