Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

Batch RPC call #38

Open
shuse2 opened this issue Jan 11, 2023 · 0 comments
Open

Batch RPC call #38

shuse2 opened this issue Jan 11, 2023 · 0 comments

Comments

@shuse2
Copy link
Collaborator

shuse2 commented Jan 11, 2023

Description

Allow caller of RPC to send the request in batch.
It should accept

[
  {
    "jsonrpc": "2.0",
    "method": "message@create",
    "params": "...",
    "id": 1
  },
  {
    "jsonrpc": "2.0",
    "method": "message@create",
    "params": "...",
    "id": 2
  }
]

and it should response as

[
  {
    "id": "1",
    "result": "pong",
    "jsonrpc": "2.0"
  },
  {
    "id": "2",
    "result": "pong",
    "jsonrpc": "2.0"
  }
]

Motivation

If we have multiple small rpc endpoints, calling one by one will be inefficient for network traffic.

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

No branches or pull requests

1 participant