Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use reconnecting RPC client #521

Open
ebma opened this issue May 7, 2024 · 0 comments
Open

Use reconnecting RPC client #521

ebma opened this issue May 7, 2024 · 0 comments

Comments

@ebma
Copy link
Member

ebma commented May 7, 2024

Context

Sometimes, it happens that the underlying RPC client used by Subxt disconnects (e.g. due to network issues). In this case, the client throws an error that is not easy to detect in subxt, see paritytech/subxt#1190.

This makes our client stuck in an infinite retry loop.

[2024-05-07T13:56:14Z INFO  runner::runner] Error fetching executable: SubxtError: Rpc error: RPC error: The background task been terminated because: Networking or low-level protocol error: WebSocket connection error: connection closed; restart required. Retrying...
[2024-05-07T13:56:15Z INFO  runner::runner] Error fetching executable: SubxtError: Rpc error: RPC error: The background task been terminated because: Networking or low-level protocol error: WebSocket connection error: connection closed; restart required. Retrying...

TODO

This PR adds a new experimental implementation of an RPC client that automatically reconnects. This implementation is only available in subxt v0.35 or later. I tried bumping the subxt dependencies we use in Spacewalk to that version but I encountered conflicts because our Polkadot dependencies are too outdated.

  • Once we update our polkadot dependencies to a later version, try bumping subxt to v0.35 or later and use the experimental RPC client implementation hidden behind the reconnecting-rpc-client feature of subxt.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant