This repository has been archived by the owner on Jun 26, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 27
chore: remove peer-info usage on topology #42
Merged
vasco-santos
merged 3 commits into
v0.3.x
from
chore/remove-peer-info-usage-on-topology
Apr 17, 2020
Merged
chore: remove peer-info usage on topology #42
vasco-santos
merged 3 commits into
v0.3.x
from
chore/remove-peer-info-usage-on-topology
Apr 17, 2020
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This was referenced Apr 7, 2020
BREAKING CHANGE: topology api now uses peer-id instead of peer-info
vasco-santos
force-pushed
the
chore/remove-peer-info-usage-on-topology
branch
from
April 16, 2020 14:43
d98bc11
to
3daa016
Compare
jacobheun
suggested changes
Apr 16, 2020
vasco-santos
force-pushed
the
chore/remove-peer-info-usage-on-topology
branch
from
April 16, 2020 15:01
f767f15
to
0627fa1
Compare
Co-Authored-By: Jacob Heun <[email protected]>
vasco-santos
force-pushed
the
chore/remove-peer-info-usage-on-topology
branch
from
April 16, 2020 15:03
0627fa1
to
e4d4016
Compare
jacobheun
approved these changes
Apr 16, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple small things (nit can be ignored). This LGTM
src/topology/multicodec-topology.js
Outdated
for (const peerInfo of peerInfoIterable) { | ||
if (this.multicodecs.filter(multicodec => peerInfo.protocols.has(multicodec)).length) { | ||
_updatePeers (peerDataIterable) { | ||
for (const peerData of peerDataIterable) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: exploding the properties might tidy this function up a little.
for (const { id, protocols } of peerDataIterable) {
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done :)
Co-Authored-By: Jacob Heun <[email protected]>
vasco-santos
force-pushed
the
chore/remove-peer-info-usage-on-topology
branch
from
April 16, 2020 15:26
37ca858
to
c46dd73
Compare
jacobheun
pushed a commit
that referenced
this pull request
Apr 21, 2020
* chore: remove peer-info usage on topology BREAKING CHANGE: topology api now uses peer-id instead of peer-info
jacobheun
pushed a commit
that referenced
this pull request
Jun 5, 2020
* chore: remove peer-info usage on topology BREAKING CHANGE: topology api now uses peer-id instead of peer-info
jacobheun
pushed a commit
that referenced
this pull request
Jun 5, 2020
* chore: remove peer-info usage on topology BREAKING CHANGE: topology api now uses peer-id instead of peer-info
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In the context of deprecating
peer-info
as described on libp2p/js-libp2p#589, this PR removes thepeer-info
usage on topology.This changes have impact on pubsub modules, as well as the dht
BREAKING CHANGE: topology api now uses peer-id instead of peer-info