]> Untitled Git - bdk/commit
Add a ureq version of esplora module
authorTobin Harding <me@tobin.cc>
Tue, 1 Jun 2021 06:36:09 +0000 (16:36 +1000)
committerTobin Harding <me@tobin.cc>
Wed, 28 Jul 2021 23:16:44 +0000 (09:16 +1000)
commitf37e735b437abaa95ae9b9116382ac63085c6efb
tree51bd8e145f36fd232d471c790542437df9e5a527
parentadceafa40c65dbe462fd554b51acdac0421f17d0
Add a ureq version of esplora module

The `Blockchain` implementation for connecting to an Esplora instance is
currently based on `reqwest`. Some users may not wish to use reqwest.

`ureq` is a simple HTTP client (no async) that is useful when `reqwest`
is not suitable.

- Move `esplora.rs` -> `esplora/reqwest.rs`
- Add an implementation based on the `reqwest` esplora code but using `ureq`
- Add feature flags and conditional includes to re-export everything to
  the `esplora` module so we don't effect the rest of the code base.
- Remove the forced dependency on `tokio`.
- Make esplora independent of async-interface
- Depend on local version of macros crate
13 files changed:
.github/workflows/code_coverage.yml
.github/workflows/cont_integration.yml
.github/workflows/nightly_docs.yml
CHANGELOG.md
Cargo.toml
macros/src/lib.rs
src/blockchain/any.rs
src/blockchain/esplora.rs [deleted file]
src/blockchain/esplora/mod.rs [new file with mode: 0644]
src/blockchain/esplora/reqwest.rs [new file with mode: 0644]
src/blockchain/esplora/ureq.rs [new file with mode: 0644]
src/error.rs
src/lib.rs