.send is not a function on FallbackProvider #2703
cloudonshore
started this conversation in
Ideas
Replies: 1 comment
-
You cannot do this with the FallbackProvider. A Provider in ethers is a porcelain interface. It is not tied to JSON-RPC providers, as not all providers are JSON-RPC-based. In v6, there may be a more generic way to execute an operation against each provider in the FallbackProvider, but in v5 this isn't possible at all. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Is your feature request related to a problem? Please describe.
I'm trying to implement eth node redundancy into an API that calculates gas prices using the
eth_feeHistory
call. I noticed that on a fallback provider I can't send RPC calls likeDescribe the solution you'd like
I would like a way to call arbitrary RPC calls using the fallback provider, where the fallback provider attempts to contact nodes sequentially, and if it encounters a failure, it moves onto the next node.
Describe alternatives you've considered
Using try/catches everywhere in my application to try using two different JSON RPC providers to make sure I have redundancy in case one provider fails or goes offline.
Beta Was this translation helpful? Give feedback.
All reactions