6

Lets say we have one instance of bitcoind running on the production server. And our exchange software/application interacts with it using RPC callbacks for:

  1. address generation
  2. withdrawal
  3. notifications

Now the question is what is the capacity of bitcoind? What would be the limit for number of transactions per minute? What is bitcoind performance? Any suggestions?

1

address generation

Make sure your using HD here (A wallet created with bitcoin core 0.13 will be HD).

Address generation is pretty fast, make sure your using a large keypool –keypool=5000 in the conf-file maybe. Also, you can pre-generate addresses and stored them in a cache-database. But be aware, if an attacker manages to compromise that cache-database, he can probably redirect funds.

Address generation can also be done outside of bitcoin-core. Check BIP32 (HD Wallets) and maybe have a look at public key derivation. If you need performance, have a look at libbtc (C library with CLI, can derive addresses very fast).

withdrawal

At this point, you very likely are stepping into the realm of "hot wallets". Make sure your building a secure environment. This step involves ECDSA (signing of inputs) which requires the according private keys. Signing is not very fast (depends on your requirement). But you can perfectly measure this with a regtest setup (sign 1000 transactions and measure performance).

notifications

Don't use -walletnotify (it forks a process = very slow). Try to use ZMQ (you might need to add some extra code for the wallet).

0

Best way would be to measure and test this in your environment using bitcoind and testnet.

Keep in mind that if you want to increase your performance it should be possible to run different instances of bitcoind (just change the port number for RPC calls) and then devise a scheme (eg round robin) where you distribute the load between the different instances.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.