lnd.xprv/discovery
Conner Fromknecht a4b4fe666a
discovery: make batch size distinct from chunk size, reduce to 500
This commit reduces the number of channels a syncer will request from
the remote node in a single QueryShortChanIDs message. The current size
is derived from the chunkSize, which is meant to signal the maximum
number of short chan ids that can fit in a single ReplyChannelRange
message. For EncodingSortedPlain, this number is 8000, and we use the
same number to dictate the size of the batch from the remote peer.

We modify this by introducing a separately configurable batchSize, so
that both can be tuned independently. The value is chosen to reduce the
amount of buffering the remote party will perform, only requiring them
queue 500 responses, as opposed to 8000. In turn, this reduces larges
spikes in allocation on the remote node at the expense of a few extra
round trips for the control messages. However, will be negligible since
the control messages are much smaller than the messages being returned.
2019-04-06 15:27:26 -07:00
..
bootstrapper.go discovery: update autopilot.Node usage to match recent API changes 2018-08-29 15:45:39 -07:00
chan_series.go discovery/chan_series+utils: include max htlc when syncing with peers 2019-01-22 08:42:28 +01:00
gossiper_test.go discovery+server: use new gossiper's SyncManager subsystem 2019-04-03 15:44:43 -07:00
gossiper.go discovery+server: use new gossiper's SyncManager subsystem 2019-04-03 15:44:43 -07:00
log.go multi: init subsystem loggers via build pkg 2018-10-05 13:04:45 +09:00
message_store_test.go discovery/message_store: add gossip message store 2019-02-14 18:29:39 -08:00
message_store.go discovery/message_store: add gossip message store 2019-02-14 18:29:39 -08:00
mock_test.go peer: add SendMessageLazy 2019-03-05 17:08:22 -08:00
reliable_sender_test.go discovery: replace waitPredicate with lntest version 2019-04-03 15:08:12 -07:00
reliable_sender.go discovery: add missing offline peer check before sending message reliably 2019-03-28 17:21:28 -07:00
sync_manager_test.go discovery: introduce gossiper SyncManager subsystem 2019-04-03 15:08:32 -07:00
sync_manager.go discovery: make batch size distinct from chunk size, reduce to 500 2019-04-06 15:27:26 -07:00
syncer_test.go discovery: make batch size distinct from chunk size, reduce to 500 2019-04-06 15:27:26 -07:00
syncer.go discovery: make batch size distinct from chunk size, reduce to 500 2019-04-06 15:27:26 -07:00
utils.go discovery/chan_series+utils: include max htlc when syncing with peers 2019-01-22 08:42:28 +01:00