Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: improve request serde in version middleware #322

Open
1 task done
apoorvsadana opened this issue Oct 11, 2024 · 0 comments
Open
1 task done

refactor: improve request serde in version middleware #322

apoorvsadana opened this issue Oct 11, 2024 · 0 comments

Comments

@apoorvsadana
Copy link
Contributor

Is there an existing issue?

  • I have searched the existing issues

Motivation

No response

Request

Our current implementation of RPC request handling in the add_rpc_version_to_method in the version middleware is inefficient due to the use of serde_json::Value for parsing. This approach leads to unnecessary heap allocations and performance overhead. We need to refactor this process to improve efficiency and reduce memory usage.

Solution

Refactor the request handling to parse directly into concrete structs instead of using serde_json::Value.

Thanks to the elaborate comment by @cchudant here

Are you willing to help with this request?

Yes!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant