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

Strip unneeded MTP data #1089

Merged
merged 7 commits into from
Nov 30, 2021
Merged

Strip unneeded MTP data #1089

merged 7 commits into from
Nov 30, 2021

Conversation

psolstice
Copy link
Contributor

PR intention

MTP data takes ~200kB in block. These changes will reduce network traffic and disk space by ~56GB for nodes synced from scratch.

Code changes brief

Code introduces concise form of block storage. If hashMTPRoot for MTP block is all zeroes there will be no MTP data in this block. Protocol version is bumped to 90031.

Before threshold time nothing is changed. After it blocks will be stripped of MTP data if possible. Sender with newer version will send stripped blocks if receiver has version >= 90031. Receiver with newer version will strip received block if full block is received. This PR doesn't cause a hardfork.

Copy link
Contributor

@levonpetrosyan93 levonpetrosyan93 left a comment

Choose a reason for hiding this comment

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

Looks good to me.

@reubenyap reubenyap merged commit 7de8050 into master Nov 30, 2021
@reubenyap reubenyap deleted the mtp-data-strip branch November 30, 2021 14:07
@reubenyap reubenyap added this to the v0.14.9.2 milestone Dec 15, 2021
levonpetrosyan93 pushed a commit that referenced this pull request May 17, 2023
* Allow stripping of MTP data

* Added arguments for MTP data srtipping testing

* Remove one MTP test

* Lifting strict rules preventing connection of older nodes

* Version bump to 0.14.9.2

* MTP data strip time is set on testnet

* Set date for MTP data stripping
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