Closed ngtuna closed 5 years ago
There are multiple PRs to solve this https://github.com/tomochain/tomochain/pull/526 https://github.com/tomochain/tomochain/pull/534 https://github.com/tomochain/tomochain/pull/529
should be good to close now as all pieces of PRs are merged.
TomoX matching engine (ME) takes advantages of red-black tree data structure to quickly search match-able bid-ask orders. ME in TomoX is designed to be very unique compared to the alternatives: ME will be executed in all 150 masternodes in TomoChain network following PoSV consensus. Particularly, masternode take cycle turn to execute ME on the local orderbook data it has; then create block with matched transactions included. A randomly chosen masternode will validate block (incl. those matched transactions) by also executing ME on the local data. If everything's fine, that block passes the PoSV validation. Other masternodes will do the same verification steps.