I want to build a middleware that adds additional data to JSON RPC responses. This middleware would sit on the same hardware or machine as the GETH node.
The traditional approach would be to simply accept the JSON-RPC requests from a client, forward it to the GETH node and add some additional data in the response on its way back to the client.
I wanted to know if there is a way through which I can completely avoid the protocol overhead of JSON-RPC and directly interface with the GETH node? Because this way I could theoretically, handle more requests. Also I wouldn't have to redundantly parse and stringify the response.
By a direct interface, I mean, interface through some API and not actually manually changing GETH code.