-
Notifications
You must be signed in to change notification settings - Fork 8.9k
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
BFT Block Puller: updatable connection source #4571
Conversation
76b559b
to
9c73888
Compare
754fb6c
to
d0f795d
Compare
6612036
to
4682dae
Compare
4682dae
to
65539cd
Compare
Signed-off-by: Yoav Tock <tock@il.ibm.com> Change-Id: Id0b80df892595cf2b9d7b7b50bfa9069f0eb6905
65539cd
to
26e1746
Compare
@@ -0,0 +1,55 @@ | |||
/* |
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.
don't we have any util package in our entire codebase we can move this function to?
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.
It got promoted from orderer/common/cluster/util.go
to common/deliverclient/util.go
, where I plan to put all the stuff that is common to both orderer and peer in the context of the block puller. Can't put it in package common/util
nor protoutil
because of import cycles. I am open to suggestions.
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.
I suppose the import cycle is because of github.com/hyperledger/fabric/common/configtx
? Then can't you move it there?
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.
However if you think there are additional things to be placed here, I guess we can leave it as is.
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.
In terms of import cycles it can be placed in common/configtx
, but I think it is not a good place to put code that parses blocks, as that package deals only with individual txs. I prefer to leave it where it is for the time being. I think that during the refactoring that is about to happen when we overhaul the orderer, several additional things will get moved into that util.go file.
Type of change
Description
Make the connection source update when a config block is processed by the block puller, not when it is committed.
Related issues
#4347