paradigmxyz / reth

Modular, contributor-friendly and blazing-fast implementation of the Ethereum protocol, in Rust
https://reth.rs/
Apache License 2.0
3.96k stars 1.19k forks source link

perf(rpc): `eth_getTransactionByBlock*` should not fetch the whole block #11100

Closed joshieDo closed 1 month ago

joshieDo commented 1 month ago

Describe the feature

RPC calls such aseth_getTransactionByBlockHashAndIndex & eth_getTransactionByBlockNumberAndIndex should not need to fetch the whole block (with all transactions), just to get the one.

https://github.com/paradigmxyz/reth/blob/b4ad28dfb4e049a54969513d6c4552783f7f4b4f/crates/rpc/rpc-eth-api/src/helpers/transaction.rs#L189-L198

Additional context

No response

KoxyG commented 1 month ago

Hi @joshieDo i am very interested in working on this issue. Can you pls assign me to this?

joshieDo commented 1 month ago

sorry @KoxyG, it's something bit of an exotic usecase and in internal discussions we decided not to proceed with it.