-
Notifications
You must be signed in to change notification settings - Fork 215
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sync2: eliminate unneeded DB accesses when peers are in sync
`FPTree`, and thus `DBSet` hold enough information in memory for peers to decide whether they are in sync or not. In this state, the peers only exchange probe requests that cover the whole set, and we only need to know fingerprint and count of the set. For that, no database queries are necessary. This change eliminates unnecessary database access, simplifies `OrderedSet` interface and adds a test case that checks that synced peers do not make any queries except those needed to advance `DBSet` (include any newly added items).
- Loading branch information
Showing
16 changed files
with
551 additions
and
347 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.