-
Notifications
You must be signed in to change notification settings - Fork 291
Description
Some of the protocols running on top of libp2p consume streams greedily, opening as many streams as they can get their hands on.
We now have resource managers in all libp2p implementations that prevent this from becoming a DoS attack, however, when the resource manager kicks in, all that the peer learns is that the stream was reset. This can happen for any number of reasons, so it's really hard to programmatically react to stream resets.
Once we have error code (#479) and HTTP (#508) we can be a lot smarter. By using the 429 HTTP status code (and an equivalent that we define as a stream error code), we can tell the peer that it is (temporarily) overloading us with requests, allowing it to take action (e.g. slow down, wait until a few in-flight requests have finished, etc.).
Metadata
Metadata
Assignees
Labels
Type
Projects
Status