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

support async read-index-task & timer #43

Merged
merged 19 commits into from
Feb 17, 2022
Merged

support async read-index-task & timer #43

merged 19 commits into from
Feb 17, 2022

Conversation

solotzg
Copy link
Collaborator

@solotzg solotzg commented Jan 14, 2022

What problem does this PR solve?

Problem Summary:

  • add interface to make read-index asynchronously.
    • fn_make_read_index_task: generate read-index task
    • fn_poll_read_index_task: poll read-index task, return 0 if response is not ready
    • fn_set_read_index_resp: serialize read index response to specific area.
    • fn_make_async_waker: generate waker to notify when response is ready
    • fn_gc_rust_ptr: gc rust ptr in engine store side
  • fn_insert_batch_read_index_resp and fn_handle_batch_read_index can be removed later.

What is changed and how it works?

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

None

@solotzg solotzg self-assigned this Jan 14, 2022
mock-engine-store/src/lib.rs Outdated Show resolved Hide resolved
components/raftstore/src/engine_store_ffi/mod.rs Outdated Show resolved Hide resolved
Signed-off-by: Zhigao Tong <[email protected]>
Signed-off-by: Zhigao Tong <[email protected]>
Signed-off-by: Zhigao Tong <[email protected]>
@solotzg solotzg changed the title support async read index task support async read-index-task & timer Jan 18, 2022
Signed-off-by: Zhigao Tong <[email protected]>
@CalvinNeo CalvinNeo self-requested a review February 7, 2022 05:36
Copy link

@birdstorm birdstorm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@solotzg solotzg merged commit 4d6a940 into pingcap:raftstore-proxy Feb 17, 2022
@solotzg solotzg deleted the async-read-index branch February 17, 2022 06:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants