Dan Cline
79452eadaf
chore: make clippy happy ( #6666 )
2024-02-19 06:31:47 +00:00
DaniPopes
b1b059fe9b
chore: clean up lints ( #5881 )
2023-12-28 16:23:50 +00:00
Bjerg
6af8e0f7ea
chore: use new aquamarine macro ( #5785 )
2023-12-15 14:49:01 +00:00
DaniPopes
5f9a917fb1
feat: Alloy migration ( #4737 )
...
Co-authored-by: Alessandro Mazza <121622391+alessandromazza98@users.noreply.github.com >
Co-authored-by: Supernovahs.eth <91280922+supernovahs@users.noreply.github.com >
Co-authored-by: Oliver Nordbjerg <hi@notbjerg.me >
2023-09-28 15:55:39 +00:00
DaniPopes
8f9d2908ca
chore: add and fix more lints, improve docs ( #4765 )
2023-09-25 15:46:46 +00:00
Matthias Seitz
a5dbbe4187
fix: don't starve high priority requests ( #2660 )
2023-05-13 13:18:24 -04:00
Dan Cline
b28c40223e
chore: move block body to primitives ( #1874 )
2023-03-20 21:14:23 -07:00
François Garillot
075544e889
refactor: various cleanups ( #1833 )
...
Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de >
2023-03-18 14:13:09 +01:00
Matthias Seitz
54744b3e6b
fix(net): always reset peer state on response ( #1179 )
2023-02-06 00:53:00 -08:00
Matthias Seitz
28cb91c6b4
perf(net): use qualified types for headers client future ( #1115 )
2023-02-01 13:12:48 +01:00
Aurélien
c5bc272057
fix: report reputation changes correctly ( #1086 )
...
Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de >
2023-01-31 11:05:13 -08:00
Aurélien
e2ac4d3f3c
feat: convert HeadersClient BodiesClient futures into associated types ( #1063 )
2023-01-30 01:25:15 -08:00
Aurélien
0666e29427
feat: move ReputationChangeKind to network-api ( #1035 )
2023-01-25 13:17:26 +01:00
Matthias Seitz
a24048a237
refactor: deprecate downloader trait ( #959 )
2023-01-24 13:38:11 +01:00
Matthias Seitz
d32710e1ea
chore: make FetchClient Cloneable ( #970 )
2023-01-22 12:27:06 -08:00
Matthias Seitz
009d2056f9
fix: mark response correctly ( #966 )
2023-01-22 16:48:04 +01:00
Aurélien
583426bb95
Prevent follow-up requests if a response is likely bad ( #946 )
2023-01-21 20:13:20 -08:00
Ikechukwu Ahiara Marvellous
ac9f26fcab
Extend HeadersClient, BodiesClient with a priority argument ( #935 )
...
Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de >
2023-01-20 14:20:46 +01:00
Matthias Seitz
a1dfafe331
docs: additional response handling docs ( #917 )
2023-01-18 11:33:56 -05:00
Matthias Seitz
79fad91ca0
feat(net): integrate num active peers in downloader ( #900 )
...
Co-authored-by: Roman Krasiuk <rokrassyuk@gmail.com >
2023-01-17 01:31:52 -08:00
Tomás
a5bdfe54dd
feat(net): prioritize requesting peers with low latency ( #835 )
...
Co-authored-by: lambdaclass-user <github@lambdaclass.com >
2023-01-13 16:01:39 +01:00
Dimitris Apostolou
31cb66902e
fix: Fix typos ( #773 )
2023-01-09 01:43:51 +01:00
Sanket Shanbhag
1b5bc5e1f7
Rotate peers when fetching ( #743 )
2023-01-06 12:21:42 +01:00
Bjerg
ade1ea4216
refactor: clean up StateFetcher::next_peer ( #738 )
...
* refactor: clean up `StateFetcher::next_peer`
The `&mut Peer` is unused, so we do not need to
return it.
* chore: idiomatic rust
2023-01-05 23:38:31 +01:00
Matthias Seitz
d9d0ba14c4
docs: add outgoing request diagram ( #630 )
2022-12-28 20:36:53 +01:00
Andrew Kirillov
d4d8a8c882
Moves code walkthrough book chapters to docs ( #629 )
...
* replaced template blocks with code blocks in stages chapter
* replaced template blocks with code blocks in network chapter
* moved book sections to docs
* fix indentation in recover_signer codeblock
* remove unnecessary TODO comment in network.md
2022-12-28 10:24:39 +01:00
Andrew Kirillov
a51fa4fd63
docs(book): start book chapter for network crate ( #445 )
...
* WIP FOR DRAFT PR
* WIP draft, walking through usage in pipeline
* diving deeper into instantiation of NetworkHandle & FetchClient
* WIP network management task & eth requests task done (ish)
* address pr comments: networkmanager as standalone task, networkconfig as main entrypoint for setup
* complete draft of the crate docs
* restructured, starts w/ expl of
* added more snippets/anchors
* using ignore flag on code blocks, brief explanation of struct
* typos addressed
2022-12-27 14:53:15 -08:00
Matthias Seitz
c1f124d3e3
feat(net): temporarily ban bad peers ( #492 )
...
* feat(net): temporarily ban bad peers
* use half duration interval
* Update crates/net/network/src/peers/manager.rs
Co-authored-by: Bjerg <onbjerg@users.noreply.github.com >
* fix bad test
Co-authored-by: Bjerg <onbjerg@users.noreply.github.com >
2022-12-16 18:22:25 +01:00
Roman Krasiuk
daaf039fbf
feat(sync): state transition indexes ( #449 )
...
* introduce state transitions and revert/modify block bodies table
* init refactor
* revamp transaction iteration based on bodies and add state transition mappings
* change expected return on empty db execution
* interim commit
* fix body downloader & stage
* refactor(bodies/dl): make fetch bodies fn more clear
* chore: disable unused vars/fns temporarily until exec is back
* chore: fmt
* test: fix tests
* use transitions in execution stage
* clarify empty unwind test
* remove last_tx_index fn
* rename fn and var names
* fix full block response comment
* rename fetcher`s get_block_body to get_block_bodies
* Update crates/stages/src/db.rs
Co-authored-by: Georgios Konstantopoulos <me@gakonst.com >
* fmt
* fix index overlap check error
* uncomment eth chain command
* fix doc comment
* typos
* cleanup
* any_last_tx_index -> last_tx_index
Co-authored-by: Georgios Konstantopoulos <me@gakonst.com >
Co-authored-by: Oliver Nordbjerg <hi@notbjerg.me >
2022-12-16 08:37:49 -08:00
Roman Krasiuk
22dc50e5f6
feat(sync): download peer penalization ( #427 )
...
* feat(sync): download peer penalization
* peer penalization
* add tracing on penalization
* add trace on request
* rename consensus back
* clippy
* fix tests
* nit: download result
* nit: fix comment
* rename penalize() to report_bad_message() and move DownloadError
Co-authored-by: Georgios Konstantopoulos <me@gakonst.com >
2022-12-15 10:42:18 +02:00
mempirate
c23c65fc3b
feat(net): draft for sending status updates through NetworkHandle ( #436 )
...
* feat(net): draft for sending status updates through `NetworkHandle`
* feat(net): draft for sending status updates through `NetworkHandle`
* fix(net): remove unused import
* feat(net): implement getters for status update sender half
* docs(net): document methods
* chore: cargo fmt
* feat(net): move status updating logic to NetworkManager and NetworkHandle
* feat(net): move status updating logic to NetworkManager and NetworkHandle
* fix(net): fix headers stage testing
* fix: derive default
* fix: remove StatusUpdate struct
Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de >
2022-12-15 08:59:28 +01:00
Roman Krasiuk
5057e8ec0a
feat(p2p): refactor downloaders and add peer id to the result ( #410 )
...
* feat(p2p): refactor downloaders and add peer id to the result
* rm unused import
* fix tests
* clean up deps
* Update crates/interfaces/src/p2p/error.rs
Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de >
* add split fn
Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de >
2022-12-13 17:14:45 +01:00
Matthias Seitz
b0149f0b9f
fix(net): prevent bad loop if no peers available ( #359 )
...
* fix(net): prevent bad loop if no peers available
* test: add poll fetcher test
2022-12-09 12:39:08 +01:00
Matthias Seitz
2f73345696
misc(net): unify naming ( #358 )
2022-12-08 09:12:58 -08:00
Matthias Seitz
a0c35f1f48
refactor: replace reverse with HeadersDirection ( #305 )
2022-12-01 17:59:33 +01:00
Matthias Seitz
3355b0c605
test(net): add e2e request body test ( #304 )
...
* test(net): add e2e request body test
* test(net): add e2e request header test
2022-12-01 15:35:14 +01:00
Matthias Seitz
7879389059
chore(net): deny unused and cleanup ( #289 )
2022-11-29 20:57:40 +01:00
Matthias Seitz
b5300aafec
feat(net): add request timeout ( #273 )
2022-11-28 14:41:39 -08:00
Matthias Seitz
0e436ae543
feat(net): add missing report on bad response ( #271 )
2022-11-27 23:33:04 -08:00
Matthias Seitz
fd840e1c66
refactor: bodies client API ( #257 )
...
* refactor: bodies client API
* chore: fix errors
2022-11-26 10:04:42 +01:00
Matthias Seitz
fb2861f112
feat(net): integrate HeadersClient ( #251 )
...
* refactor: headers client
* chore: rustfmt
* chore(clippy): make clippy happy
* feat(net): integrate HeadersClient
* fix: parse td as U256 with from_little_endian
* conflicts
Co-authored-by: Georgios Konstantopoulos <me@gakonst.com >
2022-11-25 14:26:43 +01:00
Matthias Seitz
f4dbeddc97
refactor: rename FetchClient and move to submodule ( #245 )
...
* refactor: rename FetchClient and move to submodule
* chore(clippy): make clippy happy
2022-11-24 11:43:05 +01:00