Skip to content

Merge bitcoin_cli::BitcoindClient and bitcoincore_rpc::Client #42

@sr-gi

Description

@sr-gi

We are currently using two different RPC clients to interact with bitcoind.

On the one hand, we have our local bitcoin_cli::BitcoindClient that is required for our ChainPoller (base for ChainMonitor and the chain::Listen trait implemented by the main tower components). This is a minimal bitcoin-cli implementation that only handles a handful of commands to pull data from bitcoind and it's mainly async.

On the other hand, bitcoincore_rpc::Client is a more extensive bitcoin-cli implementation that we use to, for instance, send and get transaction data from bitcoind. It also has several data structures that parse the json responses sent by bitcoind. This is sync.

In order to replace BitcoindClient by Client, we'd need the latter to implement an async version of the methods that the former is using. There are, currently, some efforts on that regard:

rust-bitcoin/rust-bitcoincore-rpc#201
rust-bitcoin/rust-bitcoincore-rpc#212

The latter is specially interesting.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions