2

A transaction is stored in the mempool before it is confirmed. However, the Bitcoin node can't verify incoming transactions with 'light speed' to add them to a mempool—it obviously needs some time. So, all the incoming transactions have to wait for their turn to be verified before getting added to a mempool.
Is there some kind of queue implemented in the Bitcoin node to store all the incoming transactions before adding them to the mempool?

1 Answer 1

0

Is there some kind of queue implemented in the Bitcoin node to store all the incoming transactions before adding them to the mempool?

Simply the network buffers.

At least in the current Bitcoin Core implementation, messages received from peers are processed one by one by taking them from the network receive buffers. If that message includes a transaction, it will be processed (including adding to the mempool if applicable, and relaying to other parties) before continuing to process further messages from the same or other peers.

Obviously, this is an implementation detail, and other Bitcoin software may operate differently.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.