Converge the coexisting subscription mechanisms
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 25/100
- Loại issue
- Tái cấu trúc
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Ít trao đổi
- Công nghệ
- rust
- Lĩnh vực
- distributed-systems
Hướng nghiên cứu
Bắt đầu bằng cách so sánh các triển khai subscription được nêu trong crates/core/src/scheduler.rs, crates/app/src/sse/mod.rs, crates/core/src/sigagg.rs và app/node/wire.rs, sử dụng ngữ nghĩa wireX của Charon làm tham chiếu parity. Xác định các dạng subscription được chuẩn hóa cùng với các quy tắc về vòng đời, loại bỏ, độ trễ, lỗi và hủy đăng ký, sau đó di chuyển các triển khai lệch chuẩn và xác minh rằng ngữ nghĩa được ghi lại là nhất quán trên toàn bộ workspace.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Summary
The workspace has six mutually incompatible subscription patterns, with divergent semantics for lifetime, drop, lagging, and error propagation:
- tokio
broadcast+ spawned pump — only in the scheduler (the solebroadcastuse in the workspace). Vec<mpsc::Sender<T>>fan-out — SSE listener, with both a builder-time and an actor-round-trip runtimesubscribe(sse/mod.rs#L68).watch::Receiver-returningsubscribe()— p2p peers, dkg sync, readiness.- Sync
Box<dyn Fn>callback vectors — consensus wrapper/qbft/priority; the prioritiser's is documented "Not thread safe relative to a running instance". Arc<dyn Fn> -> BoxFuturecallback vectors — sigagg, parsigdb, fetcher (a consuming-builder variant), bcast, parsigex, validatorapi. Five different receiver forms (&self,&mut self,async &self,self -> Self, interiorMutex).- Charon-style function-pointer wiring in
app/node/wire.rs.
Semantics diverge where it matters:
Laggedis handled only in the scheduler, by silently and permanently unsubscribing the lagging subscriber;Closedalso breaks silently.- Subscriber errors: scheduler logs and continues;
sigaggpropagates with?, so one failing subscriber aborts the remaining ones (same in parsigdb) — this asymmetry is load-bearing for duty completion. - No
subscribe()anywhere returns an unsubscribe handle (scheduler TODO), and the scheduler documents a known leak of detached tasks for stuck handlers.
Related: #84 (make sub calling non-blocking).
Proposed change
This is a design task first: pick one or two blessed shapes (e.g. broadcast/watch channels for events, an async-callback registry with defined error semantics for duty pipeline stages), and document lifetime/drop/lag/error rules. Then migrate the outliers. Concrete decisions to make:
- Should a subscriber error abort sibling subscribers (current sigagg/parsigdb) or be isolated (current scheduler)? Charon's
wireXsemantics are the parity reference. - What happens on lag: drop events, kill the subscription (current), or apply backpressure?
- Unsubscribe/drop story: handles vs relying on channel closure.
- Ngôn ngữ chính
- Rust
- Star
- 8
- Fork
- 5
- Merge trung bình
- 4 ngày 18 giờ
- Pull request đã merge (30 ngày)
- 4
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của NethermindEth/pluto
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 52/100
NethermindEth/pluto#719 ·
-
enhancement rust
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 45/100
NethermindEth/pluto#640 ·
-
rust
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 45/100
NethermindEth/pluto#638 · 1 bình luận ·
-
enhancement rust
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
NethermindEth/pluto#635 ·
-
Improve `alpha test peers`: match Charon's probes; reduce timeoutsCó thể đã có người làm @varex83agent đã nhận 24 ngày trước. Đang mởbug track:orchestration-cli
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 28/100
NethermindEth/pluto#632 ·
Tất cả issue của NethermindEth/pluto
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
farion1231/cc-switch#8829 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug ci good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
longbridge/gpui-kit#3677 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
E-pr-welcome
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 77/100
seanmonstar/reqwest#3121 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 68/100
ilya-zlobintsev/LACT#1235 ·
Maintainer thường phản hồi trong vòng 1 ngày