8000 fixed deterministic logic for first findnode method by jeongkyun-oh · Pull Request #1835 · klaytn/klaytn · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Aug 19, 2024. It is now read-only.

fixed deterministic logic for first findnode method #1835

Merged
merged 1 commit into from
May 1, 2023

Conversation

jeongkyun-oh
Copy link
Contributor
@jeongkyun-oh jeongkyun-oh commented Apr 24, 2023

Proposed changes

  • While initial lookup, the returned PN list is used after findNewNode method. The PN list will be constructed with nodeByDistance struct, which is implemented for Kademlia algorithm originally by Ethereum. The list is made deterministic and it always returns the same PN. This PR fixes this problem.

Types of changes

Please put an x in the boxes related to your change.

  • Bugfix
  • New feature or enhancement
  • Others

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING GUIDELINES doc
  • I have signed the CLA
  • Lint and unit tests pass locally with my changes ($ make test)
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)
  • Any dependent changes have been merged and published in downstream modules

Related issues

  • Please leave the issue numbers or links related to this PR here.

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...

@jeongkyun-oh jeongkyun-oh self-assigned this Apr 24, 2023
@JayChoi1736
Copy link
Contributor
JayChoi1736 commented Apr 26, 2023

test result :

v1.10.2 (before PR)

스크린샷 2023-04-26 오후 3 07 29

v1.10.2 (before PR, after EN reboot)
스크린샷 2023-04-26 오후 3 12 32

After PR
스크린샷 2023-04-26 오후 2 54 19

@jeongkyun-oh jeongkyun-oh marked this pull request as ready for review April 27, 2023 00:20
8000 Copy link
Contributor
@yoomee1313 yoomee1313 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it looks good to me.

@jeongkyun-oh jeongkyun-oh merged commit 26aceea into klaytn:dev May 1, 2023
@jeongkyun-oh jeongkyun-oh deleted the 230424-update-simple-storage branch May 1, 2023 23:55
@JayChoi1736 JayChoi1736 mentioned this pull request Jul 24, 2023
20 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0