Closed anhcao142 closed 3 years ago
I can't reproduce this issue. I can do 1000 concurrent requests without any issue and I have not seen this issue when doing load testing in the past.
How are you running the node and sidecar? Are you using a public node?
Yeah, I'm currently using with public node wss://rpc.polkadot.io
. Haven't tried it with local node yet
I had no issue while using the public node
I still unable to provide a reproduce source code, but I have a service that repeatedly checks if there is a new block and fetches it, and after like half a day this error appears. I have to restart the substrate-api-sidecar
server to fix it temporarily. I think it has something to do with the WebSocket server after connecting for a while.
Currently, I have a version of substrate-api-sidecar
that I modified to use JSON-RPC instead of WebSocket, and it seems stable. The server has been running for more than a day without any connection issues.
I am also facing this issue. Don't know the exact solution. For now I am using the nginx load balancer and whenever this error occurs, I am restarting the instances.
@anhcao142 Has this still been an issue for you? polkadot-js's ws provider has a built in reconnect which has proven to work for me when a connection drops. In terms of bottlenecks I havent been able to reproduce the issue above.
It's not recommended to be scraping from a public node, as unexpected error may occur and are way more common.
Closing this issue for now, please reopen if it reoccurs.
Hi @TarikGul, thanks for asking, I haven't encountered this anymore.
@anhcao142 Sweet thanks for letting me know! :)
Description
This usually happens when I try to call multiple requests get block at the same time and after a while, this error appears in the substrate-api-sidecar server. Here is the error log:
Steps to Reproduce
Expected vs. Actual Behavior I don't know if the connection is auto-renewal after the log or it just stays disconnected.