Fork Situation in MutliChain

+2 votes
Hi,

I know a fork situation occurs when both miner tried to mine a block at the same time in the blockchain, and it will be resolve by the next block. The block begin added to that branch will be the main multichain, the other branch will be removed?

I understand that bitcoin blockchain fork will always wait for 6 completed block before it is discarded. How about MultiChain, will it discard the branch by the next block or after 6 completed block?

Thank You
asked Sep 20, 2016 by Sian20R

1 Answer

+1 vote
As in bitcoin, the longest chain wins, but in MultiChain's case it's not based on proof-of-work, but rather blocks which are signed by approved miners. In bitcoin the issue of 6 blocks is when you can have sufficient confidence that you are on the right chain, but old blocks on the wrong chain are not discarded by the node.
answered Sep 20, 2016 by MultiChain
So for Multichain blockchain, the next block added to a 1st fork branch. What will happened to the 2nd fork branch? Will block be added to this 2nd fork branch again or will it continue from the 1st fork branch?

Thank You
Unless you're unlucky and both branches are extended simultaneously by different nodes, the longer branch will take over the network, and then all nodes will continue mining on top of that. This is exactly the same kind of fork resolution logic that there is in the public blockchain network.
What happens to the transaction from the shorter branch? Do they get cancelled an send back ?
Transactions in the shorter branch re-enter the memory pool of nodes, which leaves them in the regular situation of waiting for confirmation, but being visible to all nodes. The only exception is if some of those transactions conflict with transactions which are already confirmed on the longer branch, or already in the memory pool, in which case they are discarded.
Reopening to question. I was indeed unlucky and the two branchs extended it own chains. This scenario was a bitcoin-protocol chain, with rapid tx generation. The question is if there is some sort of "disconnect" as I see the getpeerinfo output without the peer node. After this, the two nodes never reconnect and the fork remains undefinetily.
It's more likely that a disconnect caused the fork to persist, rather than the other way round. Where are you hosting the nodes and what is the network setup between then?
...