Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Send "notfound" message when inventory is not found. #1132
Note: I know we have 'notfound' message but I can't affirm this is being used for that. If this is already implemented this way, we should close this issue.
Do you have any solution you want to propose?
Where in the software does this update applies to?
@shargon could you confirm if this already exists?
I think it should only send
The original proposal would increase traffic quite a bit. For scenario 2 it would
The client already has all these hashes so it is only generating traffic because the client is too lazy to track the request itselves. In the worst case scenario it would request the maximum 2000 headers, the node only has one and you'll get 1999 * 32 = 63968 bytes (excluding the
How would the information get back to the requesting party? I think we should minimize the responsibilities of the remote node in the syncing process and keep them as basic as possible. It either gives the requested data or not (or optionally informs it can't because it's missing). After that it is up to the requesting party to find an alternative way to get the data it wants (e.g. by trying a different node).
I still secretly hope we can get a new command as suggested in #522 to skip all this header requesting and sending overload. From the P2P handshake we can tell the current height of the remote node and we can sync by just sending
to get the full blocks, without needing any hash or figuring out if the remote node actually has the hash. Once
With the above you'll not even have to ask the client if they have certain hashes or blocks, you know before even asking based on their height!