[p2p] support network separation#3817
Conversation
|
|
||
| replace golang.org/x/xerrors => golang.org/x/xerrors v0.0.0-20190212162355-a5947ffaace3 | ||
|
|
||
| replace github.com/iotexproject/go-p2p => /Users/chenchen/dev/go-p2p |
There was a problem hiding this comment.
create a PR for go-p2p changes
| return | ||
| } | ||
|
|
||
| func (p *agent) broadcastTopicName(network string) string { |
| status, | ||
| ).Inc() | ||
| }() | ||
| network, err := p.getMessageNetwork(msg) |
There was a problem hiding this comment.
topic, err := p.getMessageTopic(msg)
| a.networks[BlockNetwork] = struct{}{} | ||
| for _, opt := range opts { | ||
| opt(a) | ||
| } |
There was a problem hiding this comment.
if len(a.networks) == 0 { error out }
There was a problem hiding this comment.
node can not join any subnets in p2p level
| // ErrAgentNotStarted is the error returned when p2p agent has not been started | ||
| ErrAgentNotStarted = errors.New("p2p agent has not been started") | ||
| // ErrNoConnectedPeers is a broadcast error when have no connected peers | ||
| ErrNoConnectedPeers = p2p.ErrNoConnectedPeers |
|
Kudos, SonarCloud Quality Gate passed!
|
|
Kudos, SonarCloud Quality Gate passed!
|
|
IIP-16 paused |
da2da0a to
a45755e
Compare
|
| status := _successStr | ||
| if err != nil { | ||
| status = _failureStr | ||
| // Skip the broadcast message if it's from the node itself |
There was a problem hiding this comment.
move to line 291 or delete
bbeabb4 to
bdd9b61
Compare
| l := &iotextypes.Log{} | ||
| l.ContractAddress = log.Address | ||
| l.Topics = [][]byte{} | ||
| var shareTopic hash.Hash256 |
|











Description
P2P support
block,action,consensusthree networks, main changes including:Fixes #(issue)
Type of change
Please delete options that are not relevant.
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Test Configuration:
Checklist: