3 Commits

Author SHA1 Message Date
Thomas Eizinger
81c424ea9e
feat(swarm): make stream uprade errors more ergonomic
The currently provided `ConnectionHandlerUpgrErr` is very hard to use. Not only does it have a long name, it also features 3 levels of nesting which results in a lot of boilerplate. Last but not least, it exposes `multistream-select` as a dependency to all protocols.

We fix all of the above by renaming the type to `StreamUpgradeError` and flattening out its interface. Unrecoverable errors during protocol selection are hidden within the `Io` variant.

Related: #3759.

Pull-Request: #3882.
2023-05-08 08:55:17 +00:00
Thomas Eizinger
dcbc04e89e
feat(swarm): rename NetworkBehaviourAction to ToSwarm
Resolves #3123.

Pull-Request: #3658.
2023-03-24 13:43:49 +00:00
Max Inden
9d1116fd5d
feat(perf): implement libp2p perf protocol
Implementation of the libp2p perf protocol according to https://github.com/libp2p/specs/pull/478/.

//CC @MarcoPolo  as the author of the specification.

**Don't (yet) expect this to produce reliable performance metrics.**

Pull-Request: #3508.
2023-03-19 18:20:42 +00:00