hyperledger-labs / Scorex

Scorex 2.0 Core
Apache License 2.0
543 stars 115 forks source link

Move max inactive connection deadline to settings #379

Closed kushti closed 3 years ago

kushti commented 3 years ago

Currently, scheduleDroppingDeadConnections in NetworkController has the following magic constant:

// A peer should send out sync message to us at least once per settings.syncStatusRefreshStable duration. // We wait for more, namely settings.syncStatusRefreshStable.toMillis 3 val timeout = settings.syncStatusRefreshStable.toMillis 3

But better to have dedicated setting for detecting inactive connections, e.g. "inactiveConnectionDeadline"

kushti commented 3 years ago

done