getPastEvents BSC Error: "Connection termination"

Hello!

Iā€™m trying to get past events using HTTP BSC but got an error: ā€œupstream connect error or disconnect/reset before headers. reset reason: connection terminationā€.

On the local machine, the request is successfully executed. Not on the server. What could be the reason?

Please, help!

you are using speedy nodes and same request works from a location but from another location?

Thank you for answers!

Yes, I am using speedy nodes.

I am sending the same request from two locations: from the local machine and from the Amazon server. Request does not work on Amazon server (ends with error).

Initially, the request was without the toBlock parameter. Everything worked great. But 10 days ago an error appeared:

Invalid JSON RPC response: "fromBlock must be less than or equal to toBlock

To fix this, I had to force ā€œtoBlockā€ parameter. The request started working. But a new error appeared on the server, which I write about in this thread.

So what could be the problem?

are you using a block interval less than 2k?

Yes, Iā€™m using block interval less than 2k

maybe it is something related to that server then, maybe some connection is blocked somewhere, speedy nodes use cloudflare