0

I'm trying to understand the logic around the Mempool. What I understand is a miner will pick transactions based on an incentive given by the sender, i.e. a fee, so that the higher fee, the faster transaction will get confirmed.

But, What if the transaction get picked by a single miner regardless of fee and that miner is very unlucky miner that somehow it never win the block hashing lottery. Is that possible?

My question is:

Is only a single transaction picked by a single miner and the miner hashes the transaction with other transaction, then guessing the nonce, if it wins, then it includes in the block, else return to the Mempool?

Or,

Is only a single transaction picked by multiple miners and all those miners hash the transaction with other transactions, the guessing the nonce and the miner who wins the lottery included it in the block?

0

How it actually works:

You send your transaction to one or more nodes (your wallet does this job for you). Each of the nodes (some of them are miners) sends it immediately to all the nodes it knows (and again and again).

All the miners store the transaction (if it's valid) in their own mempool.

When a new block was created, all miners look in their mempool and try to find the best not-mined transactions, pick those with the highest fee per byte and include it in their block-mining-attemp.

If one of the miner's mempool-transactions is mined, they simply delete it out of your mempool.

  • Thanks for the answer, it's very clear. Stored transactions in their own mempool, let's say, tx1, tx2, tx3 the miner, m1, picks tx1,tx2 -> block-mining-attempt -> get a new block. And, the miner, m2, picks tx1, tx2, tx3 -> what will happen next to tx3, return to his own mempool? – zdk Apr 9 '18 at 11:14
  • 1
    Note that your transaction is not sent directly to miners but rather sent to other nodes on the network which may or may not be miners. – Andrew Chow Apr 9 '18 at 15:50
  • @zdk I'm not 100% sure, but I think, a transaction stays in the mempool when the miner picks it. The miner can remove it later (as soon it's mined by someone). It depends on the implementation of the mempool... – Alpha Apr 9 '18 at 17:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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