You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There's an argument -blocknotify for ´multichaind` to call some external program when a new block has been mined. This is great!
For some use cases it would be easier to get notified via an RPC call; the easiest way I can think of is some blocknotify RPC call that just pushes the (still open) socket onto a to-be-notified list, and this list of FDs gets close()d when a new block is available.
(Nearly no memory or other overhead.)
Of course, a few other features might be nice - like a timeout argument, or preferences whether to wake up only for a new block or for a new transaction (unconfirmed), etc. - but just having a wakeup via the same channel that the blockchain gets controlled with would be very nice.
Thanks a lot!
The text was updated successfully, but these errors were encountered:
There's an argument
-blocknotify
for ´multichaind` to call some external program when a new block has been mined. This is great!For some use cases it would be easier to get notified via an RPC call; the easiest way I can think of is some
blocknotify
RPC call that just pushes the (still open) socket onto a to-be-notified list, and this list of FDs getsclose()
d when a new block is available.(Nearly no memory or other overhead.)
Of course, a few other features might be nice - like a
timeout
argument, or preferences whether to wake up only for a new block or for a new transaction (unconfirmed), etc. - but just having a wakeup via the same channel that the blockchain gets controlled with would be very nice.Thanks a lot!
The text was updated successfully, but these errors were encountered: