discovery/sync_manager: init all syncers with IgnoreHistoricalFilters
This commit is contained in:
parent
35a2de23a3
commit
a3e690e253
@ -82,6 +82,12 @@ type SyncManagerCfg struct {
|
|||||||
// SyncManager when it should attempt a historical sync with a gossip
|
// SyncManager when it should attempt a historical sync with a gossip
|
||||||
// sync peer.
|
// sync peer.
|
||||||
HistoricalSyncTicker ticker.Ticker
|
HistoricalSyncTicker ticker.Ticker
|
||||||
|
|
||||||
|
// IgnoreHistoricalFilters will prevent syncers from replying with
|
||||||
|
// historical data when the remote peer sets a gossip_timestamp_range.
|
||||||
|
// This prevents ranges with old start times from causing us to dump the
|
||||||
|
// graph on connect.
|
||||||
|
IgnoreHistoricalFilters bool
|
||||||
}
|
}
|
||||||
|
|
||||||
// SyncManager is a subsystem of the gossiper that manages the gossip syncers
|
// SyncManager is a subsystem of the gossiper that manages the gossip syncers
|
||||||
@ -400,6 +406,7 @@ func (m *SyncManager) createGossipSyncer(peer lnpeer.Peer) *GossipSyncer {
|
|||||||
sendToPeerSync: func(msgs ...lnwire.Message) error {
|
sendToPeerSync: func(msgs ...lnwire.Message) error {
|
||||||
return peer.SendMessageLazy(true, msgs...)
|
return peer.SendMessageLazy(true, msgs...)
|
||||||
},
|
},
|
||||||
|
ignoreHistoricalFilters: m.cfg.IgnoreHistoricalFilters,
|
||||||
})
|
})
|
||||||
|
|
||||||
// Gossip syncers are initialized by default in a PassiveSync type
|
// Gossip syncers are initialized by default in a PassiveSync type
|
||||||
|
Loading…
Reference in New Issue
Block a user