Skip to content

Commit 39b2913

Browse files
committed
add DEPENDENCIES.md
1 parent a15c224 commit 39b2913

3 files changed

Lines changed: 123 additions & 0 deletions

File tree

CONTRIBUTING.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,8 @@ Public API exposure includes, but is not limited to:
129129

130130
For crates that are already `1.0.0` or above, an incompatible version bump means a MAJOR bump. For `0.x.y` crates, an incompatible version bump usually means a MINOR bump, for example `0.2.3 -> 0.3.0`. A PATCH bump on a `0.x.y` crate is still treated as compatible within the same minor line, for example `0.2.3 -> 0.2.4`.
131131

132+
For a visual representation of the dependency hierarchy of the different Rust crates, see the [DEPENDENCIES.md](DEPENDENCIES.md) file.
133+
132134
### Your First Code Contribution
133135
>In order to contribute, a basic learning about git and github is needed. If you're not familiar with them, have a look at https://docs.github.com/en/get-started/start-your-journey/git-and-github-learning-resources to dig into and learn how to use them.
134136

DEPENDENCIES.md

Lines changed: 119 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,119 @@
1+
# Dependencies
2+
3+
The main Rust SRI stack is split across two monorepos:
4+
- [`stratum`](https://github.com/stratum-rust/stratum): low-level foundational crates
5+
- [`sv2-apps`](https://github.com/stratum-rust/sv2-apps): high-level application crates
6+
7+
All crates across these two repositories follow a well-defined dependency hierarchy:
8+
9+
```mermaid
10+
flowchart TB
11+
subgraph STR["stratum repo (low-level crates)"]
12+
direction TB
13+
derive["derive_codec_sv2"]
14+
buffer["buffer_sv2"]
15+
noise["noise_sv2"]
16+
binary["binary_sv2"]
17+
framing["framing_sv2"]
18+
codec["codec_sv2"]
19+
common["common_messages_sv2"]
20+
job["job_declaration_sv2"]
21+
mining["mining_sv2"]
22+
template["template_distribution_sv2"]
23+
ext["extensions_sv2"]
24+
channels["channels_sv2"]
25+
parsers["parsers_sv2"]
26+
handlers["handlers_sv2"]
27+
sv1["sv1_api"]
28+
translation["stratum_translation"]
29+
core["stratum-core"]
30+
end
31+
32+
subgraph APPS["sv2-apps repo (application crates)"]
33+
direction TB
34+
sapps["stratum-apps"]
35+
bcsv2["bitcoin_core_sv2"]
36+
jdc["jd_client_sv2"]
37+
tr["translator_sv2"]
38+
jds["jd_server_sv2"]
39+
pool["pool_sv2"]
40+
it["integration_tests_sv2"]
41+
end
42+
43+
derive --> binary
44+
buffer -. "with_buffer_pool" .-> binary
45+
noise --> framing
46+
binary --> framing
47+
buffer -. "with_buffer_pool" .-> framing
48+
binary --> codec
49+
framing --> codec
50+
buffer --> codec
51+
noise -. "noise_sv2 feature" .-> codec
52+
53+
binary --> common
54+
binary --> job
55+
binary --> mining
56+
binary --> template
57+
binary --> ext
58+
binary --> sv1
59+
60+
binary --> channels
61+
mining --> channels
62+
template --> channels
63+
64+
binary --> parsers
65+
framing --> parsers
66+
common --> parsers
67+
job --> parsers
68+
mining --> parsers
69+
template --> parsers
70+
ext --> parsers
71+
72+
parsers --> handlers
73+
framing --> handlers
74+
common --> handlers
75+
job --> handlers
76+
mining --> handlers
77+
template --> handlers
78+
ext --> handlers
79+
binary --> handlers
80+
81+
sv1 --> translation
82+
mining --> translation
83+
channels --> translation
84+
binary --> translation
85+
86+
binary --> core
87+
buffer --> core
88+
noise --> core
89+
framing --> core
90+
codec --> core
91+
common --> core
92+
job --> core
93+
mining --> core
94+
template --> core
95+
ext --> core
96+
channels --> core
97+
parsers --> core
98+
handlers --> core
99+
sv1 -. "sv1 feature" .-> core
100+
translation -. "translation feature" .-> core
101+
102+
core -. "git/cargo dep" .-> sapps
103+
core -. "git/cargo dep" .-> bcsv2
104+
105+
sapps --> jdc
106+
sapps --> tr
107+
sapps --> jds
108+
sapps --> pool
109+
sapps --> it
110+
111+
bcsv2 --> jdc
112+
bcsv2 --> jds
113+
bcsv2 --> pool
114+
115+
jds --> pool
116+
jdc --> it
117+
tr --> it
118+
pool --> it
119+
```

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ If you’re looking to run Sv2 applications at the most recent changes, check ou
3636
- `stratum-core/` - Entrypoint for all the low-level crates in `sv2/` and `sv1/`implementations
3737
- `stratum-translation` - Stratum V1 ↔ Stratum V2 translation utilities
3838

39+
For a visual representation of the dependency hierarchy of the different Rust crates, see the [DEPENDENCIES.md](DEPENDENCIES.md) file.
40+
3941
## Local Integration Testing
4042

4143
To run integration tests locally:

0 commit comments

Comments
 (0)