fix: close streams when protocol limits are reached (#1301)

- If a stream is opened that exceeds inbound/outbound limits, reset that stream (if it is incoming) or abort and throw (if it is outgoing)
- Make the error message more helpful (say which protocol has breached the limit)
- Increase the default stream limits so we don't trigger this by accident when a remote dials us with a protocol we don't support
This commit is contained in:
Alex Potsides
2022-07-22 13:57:01 +01:00
committed by GitHub
parent 54450d4342
commit 3c0fb13bab
8 changed files with 30 additions and 17 deletions

View File

@@ -3,14 +3,14 @@
"version": "0.1.0",
"private": true,
"dependencies": {
"@chainsafe/libp2p-noise": "^6.2.0",
"@chainsafe/libp2p-noise": "^7.0.1",
"ipfs-core": "^0.14.1",
"libp2p": "../../",
"@libp2p/delegated-content-routing": "^2.0.1",
"@libp2p/delegated-peer-routing": "^2.0.1",
"@libp2p/kad-dht": "^3.0.0",
"@libp2p/mplex": "^3.0.0",
"@libp2p/webrtc-star": "^2.0.1",
"@libp2p/mplex": "^4.0.1",
"@libp2p/webrtc-star": "^3.0.0",
"@libp2p/websockets": "^3.0.0",
"react": "^17.0.2",
"react-dom": "^17.0.2",