reth icon indicating copy to clipboard operation
reth copied to clipboard

remove WsHttpServerKind type and simplify server launch

Open mattsse opened this issue 1 year ago • 4 comments

Describe the feature

the rpc-builder process has too many steps Currently, we have a type for all server variants we're using:

https://github.com/paradigmxyz/reth/blob/b89af430e2f45f8a6e53776a6e5150c1b21458c6/crates/rpc/rpc-builder/src/lib.rs#L2018-L2020

TODO

remove intermediary types so that the launch process becomes a single function that configures the server and starts it without doing multiple steps, which is basically this function:

https://github.com/paradigmxyz/reth/blob/b89af430e2f45f8a6e53776a6e5150c1b21458c6/crates/rpc/rpc-builder/src/lib.rs#L1752-L1752

this means this function must also go

https://github.com/paradigmxyz/reth/blob/b89af430e2f45f8a6e53776a6e5150c1b21458c6/crates/rpc/rpc-builder/src/lib.rs#L1637-L1643

and instead everything should be a single function that configures the tower services without intermediary types. Optionlayer is likely useful here for cors,auth

Additional context

No response

mattsse avatar Apr 06 '24 05:04 mattsse

will take a look

justcode740 avatar Apr 06 '24 05:04 justcode740

@mattsse i took an initial crack at it, just getting back up to speed on things. are there some tests I can run to make sure i'm on the right track?

smatthewenglish avatar Apr 09 '24 20:04 smatthewenglish

existing tests should cover this, but could be better, something we can look into next :)

mattsse avatar Apr 09 '24 21:04 mattsse

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

github-actions[bot] avatar May 20 '24 01:05 github-actions[bot]

If this is still stale, I think I can do it, let me know!

ozgunozerk avatar May 24 '24 15:05 ozgunozerk

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

github-actions[bot] avatar Jun 23 '24 01:06 github-actions[bot]

This issue was closed because it has been inactive for 7 days since being marked as stale.

github-actions[bot] avatar Jul 29 '24 01:07 github-actions[bot]