INV overhead and batched INVs to reduce full node traffic



Summary:

One idea to reduce the size of transaction hashes is to use a 4 to 6 byte shorthash, which would have a low chance of resulting in collision with another transaction in a large mempool. To protect against potential attacks, different salt values can be set up for each connection and a salted hash can be used instead of the full thing. This technique could potentially reduce INV traffic by 5-8x in the asymptotic case, or maybe 2-3x for a realistic case. The additional memory overhead per peer per tx would be about 12 bytes, but it would save up to 28 bytes per peer*tx of network bandwidth. In typical conditions, this could result in 1.792 MB net traffic saved per block (7.7 GB/month) at the expense of 12 MB of RAM. Short hashes like this have been proposed many times before for block propagation, but using them in INV messages is a new idea. The author is looking for feedback on any major problems with the idea.


Updated on: 2023-06-11T04:09:40.190421+00:00