silkrpc icon indicating copy to clipboard operation
silkrpc copied to clipboard

Add support for JSON batch requests

Open canepat opened this issue 4 years ago • 0 comments

Specification: JSON Batch spec Comparison: Erigon RPCDaemon batch issue

Implementation hints:

  • Request request_ -> std::vector<Request> requests_ in Connection
  • Request& req -> std::vector<Request>& requests in RequestParser::parse
  • RequestParser::consume using i-th Request as long as result is not indeterminate and begin != end (Parser::reset before each iteration)
  • asio::co_spawn to launch separate coroutine stacks in Connection::do_read, one for each Request

canepat avatar Jun 18 '21 18:06 canepat