-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
kad: Provide partial results to speedup
GetRecord
queries (#315)
This PR provides the partial results of the `GetRecord` kademlia query. - A new `GetRecordPartialResult` event is introduced for kademlia - `GetRecordSuccess` is modified to include only the query ID - Kademlia `GetRecord` implementation no longer stores network records internally and forwards valid (unexpired) ones back to the user The change is needed to speedup authority discovery for substrate based chains. More context can be found at: paritytech/polkadot-sdk#7077 (comment) ### Next Steps - [x] Adjust testing to API breaking change - [x] Investigate CPU impact (as suggested by @dmitry-markin this should be unnoticeable 🙏 ) --------- Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
- Loading branch information
Showing
6 changed files
with
258 additions
and
153 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
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.