Open jsha opened 9 years ago
One issue with the proposal above: The fetchAndStoreBlocks promise resolution is used to determine when to clear an entry from activeFetches. Need to be able to keep the entry in activeFetches until the full batch is done.
Steps to reproduce:
Get a user with > 5k blocks to the rate limit, e.g. by refreshing the my blocks page repeatedly. Push it past the rate limit, in such a way that the block batch starts but doesn't finish until fifteen minutes later.
Actual result: ECONNRESET in the update-blocks logs.
Expected result: Probably update-blocks should respond to the RPC once the rate limit is hit to avoid keeping the client waiting for an answer it probably won't care about in fifteen minutes. Also, update-blocks should catch the ECONNRESET error and not log it.