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

Direct headers announcement (rebase of #6494) #7129

merged 2 commits into from Nov 29, 2015


Copy link

sipa commented Nov 29, 2015

This is a rebase of #6494, with one line (which @sdaftuar commented he forgot to remove) deleted.

It also adds a commit to add the change to the bips document and the release notes.

sdaftuar and others added 2 commits Nov 18, 2014
This replaces using inv messages to announce new blocks, when a peer requests
(via the new "sendheaders" message) that blocks be announced with headers
instead of inv's.

Since headers-first was introduced, peers send getheaders messages in response
to an inv, which requires generating a block locator that is large compared to
the size of the header being requested, and requires an extra round-trip before
a reorg can be relayed.  Save time by tracking headers that a peer is likely to
know about, and send a headers chain that would connect to a peer's known
headers, unless the chain would be too big, in which case we revert to sending
an inv instead.

Based off of @sipa's commit to announce all blocks in a reorg via inv,
which has been squashed into this commit.

Rebased-by: Pieter Wuille
Copy link

gmaxwell commented Nov 29, 2015


@sipa sipa merged commit 49fb8e8 into bitcoin:master Nov 29, 2015
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
sipa added a commit that referenced this pull request Nov 29, 2015
49fb8e8 Documentation updates for BIP 130 (Pieter Wuille)
50262d8 Allow block announcements with headers (Suhas Daftuar)
snogcel referenced this pull request in snogcel/bitcore-p2p-dash Aug 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.