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

refactor(consensus): change the broadcast fn in context to take 'ref mut self' #2241

Merged
merged 1 commit into from
Jul 22, 2024

Conversation

matan-starkware
Copy link
Contributor

@matan-starkware matan-starkware commented Jul 22, 2024

This allows us to remove the Arc and also avoid cloning the sender on every call.
The cost is that we leak the fact that futures Sender requires .


This change is Reviewable

Copy link

codecov bot commented Jul 22, 2024

Codecov Report

Attention: Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.

Project coverage is 66.31%. Comparing base (6d7bd09) to head (d0f50df).

Files Patch % Lines
...papyrus_consensus/src/papyrus_consensus_context.rs 0.00% 4 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2241   +/-   ##
=======================================
  Coverage   66.31%   66.31%           
=======================================
  Files         139      139           
  Lines       18341    18339    -2     
  Branches    18341    18339    -2     
=======================================
- Hits        12163    12162    -1     
+ Misses       4883     4881    -2     
- Partials     1295     1296    +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@ShahakShama ShahakShama left a comment

Choose a reason for hiding this comment

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

Reviewed 6 of 6 files at r1, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @matan-starkware)

ShahakShama
ShahakShama previously approved these changes Jul 22, 2024
Copy link
Contributor

@ShahakShama ShahakShama left a comment

Choose a reason for hiding this comment

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

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @matan-starkware)

@matan-starkware matan-starkware changed the title refactor(consensus): change the broadcast fn in context to take ref mut self refactor(consensus): change the broadcast fn in context to take ref mut self' Jul 22, 2024
@matan-starkware matan-starkware changed the title refactor(consensus): change the broadcast fn in context to take ref mut self' refactor(consensus): change the broadcast fn in context to take 'ref mut self' Jul 22, 2024
@matan-starkware matan-starkware force-pushed the matan/consensus/m3/reorganize_shc_expectations_v2 branch from 699dc57 to 4323456 Compare July 22, 2024 10:31
@matan-starkware matan-starkware force-pushed the matan/consensus/m3/context_broadcast_mut branch from 0c973ac to e0d1548 Compare July 22, 2024 10:32
@matan-starkware matan-starkware force-pushed the matan/consensus/m3/reorganize_shc_expectations_v2 branch from 4323456 to d23c070 Compare July 22, 2024 12:43
@matan-starkware matan-starkware force-pushed the matan/consensus/m3/context_broadcast_mut branch from e0d1548 to 317834b Compare July 22, 2024 12:44
Base automatically changed from matan/consensus/m3/reorganize_shc_expectations_v2 to main July 22, 2024 13:11
@matan-starkware matan-starkware dismissed ShahakShama’s stale review July 22, 2024 13:11

The base branch was changed.

@matan-starkware matan-starkware force-pushed the matan/consensus/m3/context_broadcast_mut branch from 317834b to 9da4700 Compare July 22, 2024 14:11
Copy link
Contributor

@ShahakShama ShahakShama left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @matan-starkware)

…mut self'

This allows us to remove the Arc<Mutex> and also avoid cloning the sender on every call.
The cost is that we leak the fact that futures Sender requires .
@matan-starkware matan-starkware force-pushed the matan/consensus/m3/context_broadcast_mut branch from 9da4700 to d0f50df Compare July 22, 2024 14:35
@matan-starkware matan-starkware added this pull request to the merge queue Jul 22, 2024
Merged via the queue into main with commit 6403530 Jul 22, 2024
19 checks passed
@matan-starkware matan-starkware deleted the matan/consensus/m3/context_broadcast_mut branch July 22, 2024 17:08
dan-starkware pushed a commit that referenced this pull request Jul 23, 2024
…mut self' (#2241)

This allows us to remove the Arc<Mutex> and also avoid cloning the sender on every call.
The cost is that we leak the fact that futures Sender requires .
dan-starkware pushed a commit that referenced this pull request Jul 23, 2024
…mut self' (#2241)

This allows us to remove the Arc<Mutex> and also avoid cloning the sender on every call.
The cost is that we leak the fact that futures Sender requires .
@github-actions github-actions bot locked and limited conversation to collaborators Jul 24, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants