Skip to content

Use standalone runtime for RPC service#4459

Merged
zhangsoledad merged 2 commits intonervosnetwork:developfrom
chenyukang:rpc-new-runtime
Jun 28, 2024
Merged

Use standalone runtime for RPC service#4459
zhangsoledad merged 2 commits intonervosnetwork:developfrom
chenyukang:rpc-new-runtime

Conversation

@chenyukang
Copy link
Collaborator

@chenyukang chenyukang commented May 14, 2024

What problem does this PR solve?

Currently, we have some RPC API from indexer such as get_cells, get_transactions, get_cells_capacity which may cost a lot of computing resources, it may occupy all the tokio tasks, and ckb can not process blocks in extreme scenarios.

What is changed and how it works?

RPC will run in a standalone tokio runtime, so that we can process block even in extreme scenario.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code ci-runs-only: [ quick_checks,linters ]

Side effects

  • Performance regression
  • Breaking backward compatibility

Release note

Title Only: Include only the PR title in the release note.

@chenyukang chenyukang requested a review from a team as a code owner May 14, 2024 07:22
@chenyukang chenyukang requested review from doitian and removed request for a team May 14, 2024 07:22
@chenyukang chenyukang force-pushed the rpc-new-runtime branch 2 times, most recently from 3e0ec0f to 033768c Compare May 21, 2024 00:56
@chenyukang chenyukang changed the title [WIP] Use standalone runtime for PRC and add resource limitation on slow queries Use standalone runtime for PRC service May 21, 2024
quake
quake previously approved these changes May 21, 2024
@chenyukang chenyukang added this pull request to the merge queue Jun 19, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 19, 2024
@eval-exec eval-exec changed the title Use standalone runtime for PRC service Use standalone runtime for RPC service Jun 28, 2024
@zhangsoledad zhangsoledad added this pull request to the merge queue Jun 28, 2024
Merged via the queue into nervosnetwork:develop with commit c3e799f Jun 28, 2024
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

Successfully merging this pull request may close these issues.

4 participants