Skip to content

Commit 2a3cae9

Browse files
gianbelinchejuan518munozjuanbono
authored
feat(eigenda): EigenDA M0 (#3650)
## What ❔ This PR extracts the eigenda client into a separate crate and adds new metrics for the grafana dashboard. Completing M0 milestone. <!-- What are the changes this PR brings about? --> <!-- Example: This PR adds a PR template to the repo. --> <!-- (For bigger PRs adding more context is appreciated) --> ## Why ❔ <!-- Why are these changes done? What goal do they contribute to? What are the principles behind them? --> <!-- The `Why` has to be clear to non-Matter Labs entities running their own ZK Chain --> <!-- Example: PR templates ensure PR reviewers, observers, and future iterators are in context about the evolution of repos. --> ## Is this a breaking change? - [ ] Yes - [x] No ## Operational changes <!-- Any config changes? Any new flags? Any changes to any scripts? --> <!-- Please add anything that non-Matter Labs entities running their own ZK Chain may need to know --> ## Checklist <!-- Check your PR fulfills the following items. --> <!-- For draft PRs check the boxes as you complete them. --> - [ ] PR title corresponds to the body of PR (we generate changelog entries from PRs). - [ ] Tests for the changes have been added / updated. - [ ] Documentation comments have been added / updated. - [ ] Code has been formatted via `zkstack dev fmt` and `zkstack dev lint`. --------- Co-authored-by: Juan Munoz <juanmunoz890@gmail.com> Co-authored-by: juan518munoz <62400508+juan518munoz@users.noreply.github.com> Co-authored-by: Juan Bono <juanbono94@gmail.com>
1 parent 662fe08 commit 2a3cae9

File tree

15 files changed

+151
-3015
lines changed

15 files changed

+151
-3015
lines changed

core/Cargo.lock

Lines changed: 94 additions & 88 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

core/Cargo.toml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -230,11 +230,7 @@ tonic = { version = "0.11.0", default-features = false }
230230
pbjson-types = "0.6.0"
231231

232232
# Eigen
233-
tokio-stream = "0.1.16"
234-
rust-kzg-bn254 = "0.2.1"
235-
ark-bn254 = "0.5.0"
236-
num-bigint = "0.4.6"
237-
serial_test = { version = "3.1.1", features = ["file_locks"] }
233+
rust-eigenda-client = "0.1.1"
238234

239235
# Here and below:
240236
# We *always* pin the latest version of protocol to disallow accidental changes in the execution logic.

core/deny.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ ignore = [
1515
"RUSTSEC-2021-0145",
1616
"RUSTSEC-2021-0139",
1717
"RUSTSEC-2024-0388", # `derivative` is unmaintained, crypto dependenicies (boojum, circuit_encodings and others) rely on it
18+
"RUSTSEC-2024-0436", # `paste` is an unmaintained dependency of various crates (like alloy-primitives, sqlx-core)
1819
]
1920

2021
[licenses]

core/node/da_clients/Cargo.toml

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -56,18 +56,4 @@ tonic = { workspace = true, features = ["tls-roots", "prost", "codegen"] }
5656
pbjson-types.workspace = true
5757

5858
# Eigen dependencies
59-
tokio-stream.workspace = true
60-
rand.workspace = true
61-
sha3.workspace = true
62-
tiny-keccak.workspace = true
63-
ethabi.workspace = true
64-
rust-kzg-bn254.workspace = true
65-
ark-bn254.workspace = true
66-
num-bigint.workspace = true
67-
zksync_web3_decl.workspace = true
68-
zksync_eth_client.workspace = true
69-
thiserror.workspace = true
70-
tempfile.workspace = true
71-
72-
[dev-dependencies]
73-
serial_test.workspace = true
59+
rust-eigenda-client.workspace = true

core/node/da_clients/src/eigen/README.md

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -3,35 +3,3 @@
33
EigenDA is as a high-throughput data availability layer for rollups. It is an EigenLayer AVS (Actively Validated
44
Service), so it leverages Ethereum's economic security instead of bootstrapping a new network with its own validators.
55
For more information you can check the [docs](https://docs.eigenda.xyz/).
6-
7-
## Temporary
8-
9-
In order to implement the integration we generated some `.proto` files from EigenDA repo that were compiled using the
10-
following function:
11-
12-
```rust
13-
pub fn compile_protos() {
14-
let fds = protox::compile(
15-
[
16-
"proto/common.proto",
17-
"proto/disperser.proto",
18-
],
19-
["."],
20-
)
21-
.expect("protox failed to build");
22-
23-
tonic_build::configure()
24-
.build_client(true)
25-
.build_server(false)
26-
.skip_protoc_run()
27-
.out_dir("generated")
28-
.compile_fds(fds)
29-
.unwrap();
30-
}
31-
```
32-
33-
The generated folder is considered a temporary solution until the EigenDA has a library with either a protogen, or
34-
preferably a full Rust client implementation.
35-
36-
proto files are not included here to not create confusion in case they are not updated in time, so the EigenDA
37-
[repo](https://github.com/Layr-Labs/eigenda/tree/master/api/proto) has to be a source of truth for the proto files.

core/node/da_clients/src/eigen/blob_info.rs

Lines changed: 0 additions & 168 deletions
This file was deleted.

0 commit comments

Comments
 (0)