【交易所】如何创建撮合引擎

In my last article I wrote about how you can build an Ethereum Wallet Manager using nodejs, watch for incoming deposits and execute withdrawals.

I wanted to continue with showing you how to build a similar wallet using Bitcoin, but I had the opportunity to work on the trading engine for the exchange instead and I am super excited to share what I learned out of that experience.

What is a matching engine?

A matching or trading engine is a piece of software that keeps a record of all open orders in a market and generates new trades if the two orders can be fulfilled by each other.

To think about it in other terms: if you have a market where users can sell Ether for Bitcoin, you want to keep track of things like what is the current buy/sell price of Ether in Bitcoins, what buy

上一篇:自己实现数据结构系列五---BinarySearchTree


下一篇:php – Ebay Auth令牌