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

FAB-18204 Ch.Part.API: decouple multichannel and etcdraft #1862

Merged
merged 1 commit into from
Sep 10, 2020
Merged

FAB-18204 Ch.Part.API: decouple multichannel and etcdraft #1862

merged 1 commit into from
Sep 10, 2020

Conversation

tock-ibm
Copy link
Contributor

@tock-ibm tock-ibm commented Sep 9, 2020

The etcdraft package imports the multichannel package.
This prevents the multichannel package from using the onboarding
and cluster packages, which depend on etcdraft.

Here etcdraft is decoupled from multichannel by declaring an
interface that capture the dependecy on the Registrar.

This also eliminates some of the opaque function pointers to the
Registrar that the etcdraft package was using.

Signed-off-by: Yoav Tock [email protected]
Change-Id: If8112edd7a8fe08a151bb3ca19bf0eeeedc2fb31

Type of change

  • Improvement (improvement to code, performance, etc)

Description

Refactoring to remove dependency.

Related issues

Task: FAB-18204
Epic: FAB-17712

@tock-ibm tock-ibm requested a review from a team as a code owner September 9, 2020 15:27
@tock-ibm tock-ibm marked this pull request as draft September 9, 2020 15:28
The etcdraft package imports the multichannel package.
This prevents the multichannel package from using the onboarding
and cluster packages, which depend on etcdraft.

Here etcdraft is decoupled from multichannel by declaring an
interface that capture the dependecy on the Registrar.

This also eliminates some of the opaque function pointers to the
Registrar that the etcdraft package was using.

Signed-off-by: Yoav Tock <[email protected]>
Change-Id: If8112edd7a8fe08a151bb3ca19bf0eeeedc2fb31
@tock-ibm tock-ibm marked this pull request as ready for review September 9, 2020 19:39
Copy link
Contributor

@jyellick jyellick left a comment

Choose a reason for hiding this comment

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

Looks like an improvement to me. I still question a little why the consensus plugins should be responsible for transitioning to follower state, or calling 'CreateChain', but, better than the opaque function pointers.

@jyellick jyellick merged commit 331d950 into hyperledger:master Sep 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants