Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nodes the seeder is tracking may not always persist to disk due to races between ThreadDumper and ThreadCrawler #108

Open
cculianu opened this issue Mar 18, 2024 · 0 comments

Comments

@cculianu
Copy link

If ThreadDumper wakes up to save to disk periodically, it may miss nodes that are otherwise good and won't save them to disk. This is because it basically is getting nodes to save to disk from CAddrDb from its two lists: ourId and unkId.

However, when the crawler threads run, they "take" IPs to check from the CAddrDb class. These nodes are temporarily "popped" off the internal lists ourId and/or unkId (only to be returned later once a good/bad result is determined by the crawler).

So if ThreadDumper wakes up while any crawlers are actively checking nodes.. those nodes won't get saved to disk. :'(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant