I know my question might sound familiar to the question as follow: When does a miner decide to stop collecting transactions and start calculating hashes to try to win?
But actually, the reply marked as answer in that topic didn't answer the question: when will miners stop waiting/listening to new transactions?
According the answer in the link above, miners will start calculating nonce number but as far as I know, the nonce number is result of hash calculation of block header. Since the block header contains the hash of the merkle tree's root which is generated by all the transactions included in the block, so waiting and adding new transactions means the hash of the merkle tree's root will keep changing so how can miners determine to stop and concentrate in 'mining' the nonce from a stable source of transactions (or merkle tree's root hash)?
Let's simplify the questions by an example in case you cannot understand my language: miner A receives transaction a1 and then start calculating the nonce number for 1 minute (let's assume that in this period of time, there's no new transactions come and interrupt the process) but then a transaction a2 arrives, what will miner A do? Adding a2 into the candidate block, getting new hash of merkle tree's root and restarting to find the nonce number? Or just ignore the transaction a2? If A chooses to ignore new transactions to be included, can anybody tell me when it will do that (assume all of the transactions collected are not larger than the MAX_BLOCK_SIZE constant)?
Any replies or explainations for some of my questions are highly appreciated. Thank you!!