Skip to content
This repository was archived by the owner on Oct 23, 2022. It is now read-only.

Simplified node internals and creation v3 #394

Merged
merged 8 commits into from
Sep 23, 2020

Conversation

koivunej
Copy link
Collaborator

Supercedes #345.

Rebased and fixed on top of #392 master.

@koivunej
Copy link
Collaborator Author

Git etiquette Q: I should had probably removed those signed offs by @ljedrz? Strange it doesn't get done automatically.

Also, I most likely changed how the span is created, or then I just updated to have the default like it's in the latest master.

@ljedrz
Copy link
Member

ljedrz commented Sep 23, 2020

I don't mind the signed-off bits; as long as it works 👌.

@koivunej
Copy link
Collaborator Author

Waiting for CI, I have two minor doc changes related to the defaults of IpfsOptions::{kad_protocol_name,span} but I'd say this would be ready to go after those.

@koivunej koivunej marked this pull request as ready for review September 23, 2020 11:25
... instead of Ipfs. this was the original idea in rs-ipfs#343 perhaps.
@koivunej
Copy link
Collaborator Author

Now with the Arc<Repo<_>> instead of Ipfs dependency in p2p::Behaviour we've at least discussed internally.

use multibase::Base;
use std::{convert::TryInto, sync::Arc};
use tokio::task;

/// Behaviour type.
#[derive(NetworkBehaviour)]
#[derive(libp2p::NetworkBehaviour)]
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this was done as rust analyzer has this week started having issues with duplicate use's, which I kind of hope will end up being the rustc behaviour in the future as I found this "two items for the same name" confusing as well.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no downsides to doing it this way 👍

Copy link
Member

@ljedrz ljedrz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👌

@koivunej
Copy link
Collaborator Author

windows build agrees (wasn't sure of it)

bors r+

@bors
Copy link
Contributor

bors bot commented Sep 23, 2020

Build succeeded:

@bors bors bot merged commit a7418ae into rs-ipfs:master Sep 23, 2020
This was referenced Sep 23, 2020
@koivunej koivunej deleted the simplified_node branch September 24, 2020 12:55
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants