You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bitswap now uses FullClose in SendMessage when sending outbound blocks. Unfortunately, this waits for the other side to send back an EOF (a full round trip). That's terrible.
Unfortunately, there isn't a good solution. The obvious one is to fire off a goroutine to wait for the EOF (we need to wait somewhere) but that's going to suck in terms of memory usage. However, that may be the only reasonable short-term solution.
I'm going to see if I can find a way for the swarm to handle this for us in a constant number of go routines (I may also just create a temporary external "service" until we can figure out the interfaces).
Note: this is causing interop problems with js-ipfs as it doesn't appear to be closing streams in bitswap. See: ipfs/interop#28.
The text was updated successfully, but these errors were encountered:
Otherwise, we tie up the bitswap worker until the other side responds with an EOF.
fixes#5247
related to libp2p/go-libp2p-net#28
License: MIT
Signed-off-by: Steven Allen <[email protected]>
Bitswap now uses
FullClose
inSendMessage
when sending outbound blocks. Unfortunately, this waits for the other side to send back an EOF (a full round trip). That's terrible.Unfortunately, there isn't a good solution. The obvious one is to fire off a goroutine to wait for the EOF (we need to wait somewhere) but that's going to suck in terms of memory usage. However, that may be the only reasonable short-term solution.
I'm going to see if I can find a way for the swarm to handle this for us in a constant number of go routines (I may also just create a temporary external "service" until we can figure out the interfaces).
Note: this is causing interop problems with js-ipfs as it doesn't appear to be closing streams in bitswap. See: ipfs/interop#28.
The text was updated successfully, but these errors were encountered: