Skip to content

Commit f2d07db

Browse files
zealshamspacebear21
authored andcommitted
Implement Directory and its db as a tower-service
This pr addresses a part of #941 consigned with making Db a tower service. It also removes the payjoin-directory crate and moves all directory functionality into the payjoin-mailroom crate as a tower service.
1 parent 6c3a3e4 commit f2d07db

32 files changed

Lines changed: 380 additions & 849 deletions

.github/ISSUE_TEMPLATE/bug-general.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ body:
77
value: |
88
### This issue tracker is only for technical issues related to the following crates:
99
- [`payjoin-cli`](https://github.com/payjoin/rust-payjoin/tree/master/payjoin-cli)
10-
- [`payjoin-directory`](https://github.com/payjoin/rust-payjoin/tree/master/payjoin-directory)
10+
- [`payjoin-mailroom`](https://github.com/payjoin/rust-payjoin/tree/master/payjoin-mailroom)
1111
- [`payjoin-test-utils`](https://github.com/payjoin/rust-payjoin/tree/master/payjoin-test-utils)
1212
- [`payjoin-ffi`](https://github.com/payjoin/rust-payjoin/tree/master/payjoin-ffi)
1313
@@ -27,7 +27,7 @@ body:
2727
multiple: false
2828
options:
2929
- payjoin-cli
30-
- payjoin-directory
30+
- payjoin-mailroom
3131
- payjoin-test-utils
3232
- payjoin-ffi
3333
- ohttp-relay
@@ -56,7 +56,7 @@ body:
5656
attributes:
5757
label: What version of the selected crate are you using?
5858
description:
59-
Run `payjoin-cli --version` or `payjoin-directory --version` for the binaries.
59+
Run `payjoin-cli --version` or `payjoin-mailroom --version` for the binaries.
6060
For the library crates (`payjoin-test-utils`, and `payjoin-ffi`),
6161
check your respective package manager file to see which version you have installed.
6262
placeholder: e.g. payjoin-0.23.0 or master@ceef77b

.github/ISSUE_TEMPLATE/feature-request.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ body:
99
options:
1010
- payjoin
1111
- payjoin-cli
12-
- payjoin-directory
12+
- payjoin-mailroom
1313
- payjoin-test-utils
1414
- payjoin-ffi
1515
- ohttp-relay

.github/ISSUE_TEMPLATE/general.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ body:
88
options:
99
- payjoin
1010
- payjoin-cli
11-
- payjoin-directory
11+
- payjoin-mailroom
1212
- payjoin-test-utils
1313
- payjoin-ffi
1414
- ohttp-relay

.github/ISSUE_TEMPLATE/good-first-issue.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ body:
99
options:
1010
- payjoin
1111
- payjoin-cli
12-
- payjoin-directory
12+
- payjoin-mailroom
1313
- payjoin-test-utils
1414
- payjoin-ffi
1515
- ohttp-relay

.github/workflows/cron-directory-monitor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ jobs:
88
steps:
99
- uses: actions/checkout@v4
1010
- name: Check /health endpoint
11-
run: cd payjoin-directory && bash contrib/health-check.sh
11+
run: cd payjoin-mailroom && bash contrib/health-check.sh

Cargo-minimal.lock

Lines changed: 6 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -2825,34 +2825,6 @@ dependencies = [
28252825
"url",
28262826
]
28272827

2828-
[[package]]
2829-
name = "payjoin-directory"
2830-
version = "0.0.3"
2831-
dependencies = [
2832-
"anyhow",
2833-
"bhttp",
2834-
"bitcoin 0.32.8",
2835-
"bitcoin-ohttp",
2836-
"clap 4.5.46",
2837-
"config",
2838-
"futures",
2839-
"http-body-util",
2840-
"hyper",
2841-
"hyper-util",
2842-
"ohttp-relay",
2843-
"payjoin",
2844-
"rand 0.8.5",
2845-
"serde",
2846-
"tempfile",
2847-
"tokio",
2848-
"tokio-rustls",
2849-
"tokio-rustls-acme",
2850-
"tokio-stream",
2851-
"tower",
2852-
"tracing",
2853-
"tracing-subscriber",
2854-
]
2855-
28562828
[[package]]
28572829
name = "payjoin-ffi"
28582830
version = "0.24.0"
@@ -2892,16 +2864,21 @@ dependencies = [
28922864
"anyhow",
28932865
"axum",
28942866
"axum-server",
2867+
"bhttp",
2868+
"bitcoin 0.32.8",
2869+
"bitcoin-ohttp",
28952870
"clap 4.5.46",
28962871
"config",
28972872
"flate2",
2873+
"futures",
2874+
"http-body-util",
28982875
"ipnet",
28992876
"maxminddb",
29002877
"ohttp-relay",
29012878
"opentelemetry",
29022879
"opentelemetry-otlp",
29032880
"opentelemetry_sdk",
2904-
"payjoin-directory",
2881+
"payjoin",
29052882
"payjoin-test-utils",
29062883
"rand 0.8.5",
29072884
"reqwest",

Cargo-recent.lock

Lines changed: 6 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -2825,34 +2825,6 @@ dependencies = [
28252825
"url",
28262826
]
28272827

2828-
[[package]]
2829-
name = "payjoin-directory"
2830-
version = "0.0.3"
2831-
dependencies = [
2832-
"anyhow",
2833-
"bhttp",
2834-
"bitcoin 0.32.8",
2835-
"bitcoin-ohttp",
2836-
"clap 4.5.46",
2837-
"config",
2838-
"futures",
2839-
"http-body-util",
2840-
"hyper",
2841-
"hyper-util",
2842-
"ohttp-relay",
2843-
"payjoin",
2844-
"rand 0.8.5",
2845-
"serde",
2846-
"tempfile",
2847-
"tokio",
2848-
"tokio-rustls",
2849-
"tokio-rustls-acme",
2850-
"tokio-stream",
2851-
"tower",
2852-
"tracing",
2853-
"tracing-subscriber",
2854-
]
2855-
28562828
[[package]]
28572829
name = "payjoin-ffi"
28582830
version = "0.24.0"
@@ -2892,16 +2864,21 @@ dependencies = [
28922864
"anyhow",
28932865
"axum",
28942866
"axum-server",
2867+
"bhttp",
2868+
"bitcoin 0.32.8",
2869+
"bitcoin-ohttp",
28952870
"clap 4.5.46",
28962871
"config",
28972872
"flate2",
2873+
"futures",
2874+
"http-body-util",
28982875
"ipnet",
28992876
"maxminddb",
29002877
"ohttp-relay",
29012878
"opentelemetry",
29022879
"opentelemetry-otlp",
29032880
"opentelemetry_sdk",
2904-
"payjoin-directory",
2881+
"payjoin",
29052882
"payjoin-test-utils",
29062883
"rand 0.8.5",
29072884
"reqwest",

Cargo.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ members = [
44
"ohttp-relay",
55
"payjoin",
66
"payjoin-cli",
7-
"payjoin-directory",
87
"payjoin-test-utils",
98
"payjoin-ffi",
109
"payjoin-mailroom",
@@ -15,7 +14,6 @@ resolver = "2"
1514
payjoin-fuzz = { path = "fuzz" }
1615
ohttp-relay = { path = "ohttp-relay" }
1716
payjoin = { path = "payjoin" }
18-
payjoin-directory = { path = "payjoin-directory" }
1917
payjoin-mailroom = { path = "payjoin-mailroom" }
2018
payjoin-test-utils = { path = "payjoin-test-utils" }
2119

contrib/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ if [ -f "$LOCKFILE" ]; then
2424
fi
2525

2626
DEPS="recent minimal"
27-
CRATES="ohttp-relay payjoin payjoin-cli payjoin-directory payjoin-ffi payjoin-mailroom"
27+
CRATES="ohttp-relay payjoin payjoin-cli payjoin-ffi payjoin-mailroom"
2828

2929
for dep in $DEPS; do
3030
cargo --version

contrib/test_local.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/usr/bin/env bash
22
set -e
33

4-
CRATES="ohttp-relay payjoin payjoin-cli payjoin-directory payjoin-ffi payjoin-mailroom"
4+
CRATES="ohttp-relay payjoin payjoin-cli payjoin-ffi payjoin-mailroom"
55

66
cargo --version
77
rustc --version

0 commit comments

Comments
 (0)