paradigmxyz / reth

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

Add a way to override certain RPC handler impls #1913

Closed mattsse closed 1 year ago

mattsse commented 1 year ago

Describe the feature

depending on the setup, some functions should be disabled and instead return an error like:

cast eth_coinbase

(code: -32600, message: Unsupported method: eth_coinbase. See available methods at https://docs.alchemy.com/alchemy/documentation/apis, data: None)

this will likely be possible with this (unreleased) jsonrpsee PR: https://github.com/paritytech/jsonrpsee/commit/b4e3b6e182cd50bef220f4f78314b480651ce9ff

once available we need a helper type that allows to configure functions by name and an error handler.

Additional context

No response

github-actions[bot] commented 1 year ago

This issue is stale because it has been open for 14 days with no activity.