Bitcoin New Block Event Trigger I want to know when a new block is discovered, I am watching debug.log to see if it has changed, I know there is a new block if the line contains "UpdateTip: new best". Is there a better way to do this?
bitcoind offers a zmq hook which you can use to receive notifications on new blocks and transactions.