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

addrman-based PeerDBDiscovery #2

Closed
wants to merge 6 commits into from

Conversation

TheBlueMatt
Copy link
Contributor

Still a //TODO or two left, but figure I'll pull request it now anyway.

@MatthewLM
Copy link

Hi, I tried doing this:

PeerDBDiscovery dbDiscovery = new PeerDBDiscovery(Constants.NETWORK_PARAMETERS, new File(getDir("peers", Context.MODE_PRIVATE), Constants.PEERS_FILENAME), peerGroup);

peerGroup.addPeerDiscovery(dbDiscovery);
dbDiscovery.listenForPeers(peerGroup);

But the onPreMessageReceived method is never called, and it's not called for every received message.

Hmm it looks like it's due to not being registered in the same thread. I'll look into it some more.

bitbandi added a commit to bitbandi/spreadcoinj that referenced this pull request Jan 26, 2015
@schildbach
Copy link
Member

This PR is now 2 years old. Is it still relevant?

HashEngineering referenced this pull request in Groestlcoin/groestlcoinj Oct 7, 2017
kmels referenced this pull request in kmels/bitcoinj Mar 5, 2018
* test should fail, not get stuck

* fix packet magic in unittestparams, fix test badMessage
kmels referenced this pull request in kmels/bitcoinj Mar 18, 2018
Remove bip47meta encryption
jestevez pushed a commit to jestevez/bitcoinj that referenced this pull request Jul 17, 2018
Updated seed peers from DNS, as the old ones do not seem to work anymore
Vutov pushed a commit to Vutov/bitcoingoldj that referenced this pull request Oct 23, 2018
hbyscpp pushed a commit to hbyscpp/bitcoinj that referenced this pull request Feb 23, 2021
Updated AbstractBitcoinNetParams::bitsToTarget to match spec.
msgilligan added a commit to msgilligan/bitcoinj that referenced this pull request Sep 4, 2021
* Move difficultyTarget and time to constructors (where possible)

NetworkParameters and subclasses:

* Move Genesis Block parameters to constructors
* Prefer static final fields (constants) to magic numbers
* Move id initialization to top of constructors
msgilligan added a commit to msgilligan/bitcoinj that referenced this pull request Sep 6, 2021
* Move difficultyTarget and time to constructors (where possible)

NetworkParameters and subclasses:

* Move Genesis Block parameters to constructors
* Prefer static final fields (constants) to magic numbers
msgilligan added a commit to msgilligan/bitcoinj that referenced this pull request Sep 6, 2021
* Move difficultyTarget and time to constructors (where possible)

NetworkParameters and subclasses:

* Move Genesis Block parameters to constructors
* Prefer static final fields (constants) to magic numbers
msgilligan added a commit to msgilligan/bitcoinj that referenced this pull request Sep 7, 2021
* Move difficultyTarget and time to constructors (where possible)

NetworkParameters and subclasses:

* Move Genesis Block parameters to constructors
* Prefer static final fields (constants) to magic numbers
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

Successfully merging this pull request may close these issues.

None yet

3 participants