The Wayback Machine - https://web.archive.org/web/20201031031758/https://github.com/paritytech/substrate/pull/7464
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use inbound peerslot slots when a substream is received, rather than a connection #7464

Open
wants to merge 4 commits into
base: master
from

Conversation

@tomaka
Copy link
Member

@tomaka tomaka commented Oct 29, 2020

Fix #7074

This implements the change described in #7074.

It took me a lot of time, but I came up with this refactoring of the communication between the behaviour and the handler. I believe that the new asynchronous protocol between the behaviour and handler is sound, in other words that it is not prone to race conditions.
I invite you to look at the documentation of group.rs for explanations.

The implementation of this new protocol, though, seems faulty. I'm opening as a draft because I know that tests aren't passing, and I want to do more re-review, debugging, and styling passes myself.


@romanb @mxinden (or any other reviewer)
Feel free to comment now about at the new protocol explained on top of group.rs, if you wish so.
The exact code changes are still to follow.

@tomaka tomaka requested review from romanb and mxinden Oct 29, 2020
@tomaka tomaka added this to Triage in Networking via automation Oct 29, 2020
@tomaka
Copy link
Member Author

@tomaka tomaka commented Oct 29, 2020

Sorry for the lack of thorough explanations at the moment. This PR was very tiring to make, and I'm just very happy/relieved to finally open it and shut down my IDE. I'll edit the OP to provide more context tomorrow or next week.

@tomaka tomaka marked this pull request as ready for review Oct 30, 2020
@tomaka
Copy link
Member Author

@tomaka tomaka commented Oct 30, 2020

Marked as ready for CI purposes only.

tomaka added 3 commits Oct 27, 2020
…a connection
@tomaka tomaka force-pushed the tomaka:fix-7074 branch from 256722e to 4182faf Oct 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
1 participant
You can’t perform that action at this time.