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

Remove task::block_in_place in transaction importer #1805

Merged
merged 2 commits into from
Jul 16, 2024

Conversation

Alenar
Copy link
Collaborator

@Alenar Alenar commented Jul 8, 2024

Content

This PR includes a small refactor of aggregator & signer CardanoTransactionImporter threading logic to use task::spawn_blocking instead of task::block_in_place.

Pre-submit checklist

  • Branch
    • Tests are provided (if possible)
    • Crates versions are updated (if relevant)
    • Commit sequence broadly makes sense
    • Key commits have useful messages
  • PR
    • No clippy warnings in the CI
    • Self-reviewed the diff
    • Useful pull request description
    • Reviewer requested

Copy link

github-actions bot commented Jul 8, 2024

Test Results

    4 files  ±0     52 suites  ±0   8m 52s ⏱️ -1s
1 148 tests +2  1 148 ✅ +2  0 💤 ±0  0 ❌ ±0 
1 314 runs  +2  1 314 ✅ +2  0 💤 ±0  0 ❌ ±0 

Results for commit 252f549. ± Comparison against base commit 6288370.

♻️ This comment has been updated with latest results.

@Alenar Alenar temporarily deployed to testing-preview July 8, 2024 08:35 — with GitHub Actions Inactive
@Alenar Alenar temporarily deployed to testing-sanchonet July 8, 2024 08:35 — with GitHub Actions Inactive
Copy link
Collaborator

@dlachaume dlachaume left a comment

Choose a reason for hiding this comment

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

LGTM 👍

Copy link
Collaborator

@sfauvel sfauvel left a comment

Choose a reason for hiding this comment

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

LGTM

… importers

This avoid issues with `block_in_place` such as suspension of code
running concurrently in the same task (see:
<https://docs.rs/tokio/latest/tokio/task/fn.block_in_place.html>).
It also avoid the need of specifying `(flavor = "multi_thread")` for the
tests.
* Mithril-aggregator from `0.5.41` to `0.5.42`
* Mithril-signer from `0.2.163` to `0.2.164`
@Alenar Alenar force-pushed the djo/remove_block_in_place branch from 2f9843d to 252f549 Compare July 16, 2024 09:17
@Alenar Alenar temporarily deployed to testing-sanchonet July 16, 2024 09:24 — with GitHub Actions Inactive
@Alenar Alenar merged commit 556b687 into main Jul 16, 2024
40 checks passed
@Alenar Alenar deleted the djo/remove_block_in_place branch July 16, 2024 09:55
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