|
|
@ -104,11 +104,13 @@ public class MergeBesuControllerBuilder extends BesuControllerBuilder { |
|
|
|
ethPeers.setBestChainComparator(mergeBestPeerComparator); |
|
|
|
ethPeers.setBestChainComparator(mergeBestPeerComparator); |
|
|
|
mergeContext.observeNewIsPostMergeState(mergeBestPeerComparator); |
|
|
|
mergeContext.observeNewIsPostMergeState(mergeBestPeerComparator); |
|
|
|
|
|
|
|
|
|
|
|
if (mergePeerFilter.isPresent()) { |
|
|
|
Optional<MergePeerFilter> filterToUse = Optional.of(new MergePeerFilter()); |
|
|
|
|
|
|
|
|
|
|
|
mergeContext.observeNewIsPostMergeState(mergePeerFilter.get()); |
|
|
|
if (mergePeerFilter.isPresent()) { |
|
|
|
mergeContext.addNewForkchoiceMessageListener(mergePeerFilter.get()); |
|
|
|
filterToUse = mergePeerFilter; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
mergeContext.observeNewIsPostMergeState(filterToUse.get()); |
|
|
|
|
|
|
|
mergeContext.addNewForkchoiceMessageListener(filterToUse.get()); |
|
|
|
|
|
|
|
|
|
|
|
EthProtocolManager ethProtocolManager = |
|
|
|
EthProtocolManager ethProtocolManager = |
|
|
|
super.createEthProtocolManager( |
|
|
|
super.createEthProtocolManager( |
|
|
@ -121,7 +123,7 @@ public class MergeBesuControllerBuilder extends BesuControllerBuilder { |
|
|
|
ethMessages, |
|
|
|
ethMessages, |
|
|
|
scheduler, |
|
|
|
scheduler, |
|
|
|
peerValidators, |
|
|
|
peerValidators, |
|
|
|
mergePeerFilter); |
|
|
|
filterToUse); |
|
|
|
|
|
|
|
|
|
|
|
return ethProtocolManager; |
|
|
|
return ethProtocolManager; |
|
|
|
} |
|
|
|
} |
|
|
|