Building a bitcoin exchange - what database technologies to evaluate?
Hi guys,
I'm considering R&Ding the technology to run a scalable bitcoin exchange. I'd like to start by evaluating existing NewSQL and NoSql databases for suitability, but there are now so many choices this process is rather difficult.
Scalability is a big concern, but consistency is more important since an exchange deals directly with financial transactions and will almost certainly require cross-table atomicity.
Does anyone have any suggestions on where to start, other than google?
Cheers, Paul.
6 comments
[ 3.0 ms ] story [ 21.0 ms ] threadSecurity, reliability, consistency and integrity are likely to be much more important. How will your system handle encryption and ACLs, how will it recover from partial system failures, when there's an inconsistency how will you resolve the authoritative truth, how are you going to store transaction logs (i.e. read-only media), etc ?
You can look into the buttercoin project on github. Current exchange technology is not scalable past something like 50 operations per second, because of blocking issues. Using something like LMAX (which is used by betfair), you're probably able to get something like 1,000 operations per second. It's still in beta, but it can be out of beta if you can dig into coffeescript.
LMAX seems ideal because if something goes wrong, you can switch machines, load up the transaction history, and get going again in minutes.
Current stock exchanges may not be a great place to look, as they track thousands of individual stocks. A bitcoin exchange is different, as it's more akin to a stock exchange where there's only 1 stock and multiple currencies.
http://buttercoin.net/
http://martinfowler.com/articles/lmax.html
[1] https://justcoin.com
[2] https://github.com/justcoin/snow
Source: We're in the final testing stages of a UK based exchange.