Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PubSub ¶
type PubSub interface { Publish(block blocks.Block) Subscribe(ctx context.Context, keys ...cid.Cid) <-chan blocks.Block Shutdown() }
PubSub is a simple interface for publishing blocks and being able to subscribe for cids. It's used internally by bitswap to decouple receiving blocks and actually providing them back to the GetBlocks caller.
Click to show internal directories.
Click to hide internal directories.