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

Add sane configuration values for batch calls #211

Closed
Tracked by #126
m-Peter opened this issue Apr 19, 2024 · 0 comments · Fixed by #277
Closed
Tracked by #126

Add sane configuration values for batch calls #211

m-Peter opened this issue Apr 19, 2024 · 0 comments · Fixed by #277
Assignees
Milestone

Comments

@m-Peter
Copy link
Collaborator

m-Peter commented Apr 19, 2024

curl -XPOST https://previewnet.evm.nodes.onflow.org --header 'Content-Type: application/json' --data-raw '[{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1},{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":2}]' | jq

[
  {
    "jsonrpc": "2.0",
    "id": 1,
    "result": "0xabf"
  },
  {
    "jsonrpc": "2.0",
    "id": 2,
    "result": "0x286"
  }
]

The gateway supports out of the box batch calls (it comes from re-using the original server implementation). This is quite a handy feature, that can save bandwidth. But for production, we would also want to add some sane config values, regarding maximum number of calls and maximum response length, to avoid any performance issues.

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

Successfully merging a pull request may close this issue.

1 participant