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

fix(core/keymanager): use tokio rwlock for keymanagers #5494

Merged

Conversation

sdbondi
Copy link
Member

@sdbondi sdbondi commented Jun 23, 2023

Description

Replaces futures-rs Mutex with tokio's RwLock for key manager locks

Motivation and Context

Allow multiple concurrent reads for keymanagers. In general, we prefer to use tokio's locks with the tokio runtime (no investigation done into performance differences).

If there was a particular reason to use futures-rs Mutex we can close this.

How Has This Been Tested?

Existing tests, this change is not benchmarked.

What process can a PR reviewer use to test or verify this change?

Breaking Changes

  • None
  • Requires data directory on base node to be deleted
  • Requires hard fork
  • Other - Please specify

@sdbondi sdbondi requested a review from SWvheerden June 23, 2023 09:52
@github-actions
Copy link

github-actions bot commented Jun 23, 2023

Test Results (CI)

1 170 tests   1 170 ✔️  21m 41s ⏱️
     37 suites         0 💤
       1 files           0

Results for commit adab71e.

♻️ This comment has been updated with latest results.

@ghpbot-tari-project ghpbot-tari-project added P-acks_required Process - Requires more ACKs or utACKs P-reviews_required Process - Requires a review from a lead maintainer to be merged labels Jun 23, 2023
@github-actions
Copy link

github-actions bot commented Jun 23, 2023

Test Results (Integration tests)

  2 files  11 suites   14m 44s ⏱️
26 tests 25 ✔️ 0 💤 1
27 runs  26 ✔️ 0 💤 1

For more details on these failures, see this check.

Results for commit adab71e.

♻️ This comment has been updated with latest results.

@sdbondi sdbondi force-pushed the core-keymanager-use-tokio-lock branch from 973426b to 7603a03 Compare June 23, 2023 12:33
@sdbondi sdbondi force-pushed the core-keymanager-use-tokio-lock branch from 8a00028 to adab71e Compare June 23, 2023 13:26
Copy link
Collaborator

@SWvheerden SWvheerden left a comment

Choose a reason for hiding this comment

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

utAck

@ghpbot-tari-project ghpbot-tari-project removed the P-reviews_required Process - Requires a review from a lead maintainer to be merged label Jun 23, 2023
@SWvheerden SWvheerden merged commit 229aee0 into tari-project:development Jun 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P-acks_required Process - Requires more ACKs or utACKs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants