Author: Greg Sanders 2017-08-28 16:26:48
Published on: 2017-08-28T16:26:48+00:00
In a recent email on the Bitcoin-dev mailing list, Riccardo Casatta proposed an optimization for transmitting Bitcoin block headers. The proposal suggests that after the first header, subsequent headers need not transmit the previous hash as the receiver can compute it by double hashing the previous header. This optimization could save about 40% bandwidth in a long stream of headers. Casatta mentions that he believes this optimization could be particularly useful in instances where full node security isn't feasible, such as when dealing with private databases that require timestamping. Casatta also suggests using fixed position chunks to leverage HTTP caching and speed up synchronization for new clients. For example, /headers/2016/0 would return the headers from the genesis to the 2015th header, while /headers/2016/1 would give the headers from the 2016th to the 4031st. Other endpoints could have chunks of 20160 blocks or 201600, allowing a client to fast sync the headers with only about 10 HTTP requests.
Updated on: 2023-06-12T15:09:12.694517+00:00