mirror of https://github.com/status-im/consul.git
Use config struct to create NetworkTransport layer when setting up raft
This commit is contained in:
parent
393ce1581b
commit
c68fce89b5
|
@ -494,7 +494,9 @@ func (s *Server) setupRaft() error {
|
|||
}
|
||||
|
||||
// Create a transport layer.
|
||||
trans := raft.NewNetworkTransportWithServerAddressProvider(s.raftLayer, 3, 10*time.Second, s)
|
||||
transConfig := &raft.NetworkTransportConfig{Stream: s.raftLayer, MaxPool: 3, Timeout: 10 * time.Second, ServerAddressProvider: s}
|
||||
|
||||
trans := raft.NewNetworkTransportWithConfig(transConfig)
|
||||
s.raftTransport = trans
|
||||
|
||||
// Make sure we set the LogOutput.
|
||||
|
|
Loading…
Reference in New Issue