Skip to content

Commit 5de717b

Browse files
committed
[FAB-7519] Remove broadcast handler from peer
Peer reuses the AtomicBroadcast service to be used for events service, while the only API in use is Deliver and Broadcast is not implemented. However broadcast handler being initialized and not used, this commit simply removes the initialization of not used part. Change-Id: Ia367c0d9a2724f0d3b981db3e20e426938e4317f Signed-off-by: Artem Barger <bartem@il.ibm.com>
1 parent ce8c0ab commit 5de717b

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

core/peer/atomicbroadcast.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,9 @@ import (
2222
"github.com/hyperledger/fabric/common/deliver"
2323
"github.com/hyperledger/fabric/common/flogging"
2424
"github.com/hyperledger/fabric/common/policies"
25-
"github.com/hyperledger/fabric/orderer/common/broadcast"
2625
"github.com/hyperledger/fabric/protos/common"
2726
ab "github.com/hyperledger/fabric/protos/orderer"
28-
logging "github.com/op/go-logging"
27+
"github.com/op/go-logging"
2928
)
3029

3130
const pkgLogID = "common/peer"
@@ -37,7 +36,6 @@ func init() {
3736
}
3837

3938
type server struct {
40-
bh broadcast.Handler
4139
dh deliver.Handler
4240
}
4341

@@ -65,7 +63,6 @@ func (s *server) Deliver(srv ab.AtomicBroadcast_DeliverServer) error {
6563
func NewAtomicBroadcastServer(timeWindow time.Duration, mutualTLS bool) ab.AtomicBroadcastServer {
6664
s := &server{
6765
dh: deliver.NewHandlerImpl(DeliverSupportManager{}, policies.ChannelReaders, timeWindow, mutualTLS),
68-
bh: broadcast.NewHandlerImpl(nil),
6966
}
7067
return s
7168
}

0 commit comments

Comments
 (0)