Skip to content
This repository has been archived by the owner on Jan 11, 2024. It is now read-only.

Refactor top down #258

Merged
merged 10 commits into from
Jul 25, 2023
Merged

Refactor top down #258

merged 10 commits into from
Jul 25, 2023

Conversation

cryptoAtwill
Copy link
Contributor

Refactoring top down checkpoint submission:

  • Introduced TopDownManager struct that handles the top down checkpoint submission process
  • Introduced TopDownHandler trait that can be implemented by SubnetManager to provide utility functions for TopDownManager.
  • Removed previous checkpoint/fvm, checkpoint/fevm_fvm, checkpoint/fevm folders as they are no longer needed.

@cryptoAtwill cryptoAtwill requested a review from adlrocha July 18, 2023 08:57
Copy link
Contributor

@adlrocha adlrocha left a comment

Choose a reason for hiding this comment

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

I left a few suggestions. I haven't looked in depth to the implementation of the functions (only the code structure, as I assumed this just moved code around). Let me know if I should look deeper into something.

Once the comments are addressed, if you have tested it and works feel free to merge.

src/checkpoint/bottomup.rs Outdated Show resolved Hide resolved
src/checkpoint/setup.rs Outdated Show resolved Hide resolved
/// The trait that handles the bottom up checkpoint submission data preparation and actual submission.
#[async_trait]
pub trait TopDownHandler:
Send + Sync + VoteQuery<TopDownCheckpoint> + CheckpointUtilQuery<TopDownCheckpoint>
Copy link
Contributor

Choose a reason for hiding this comment

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

After seeing this, I feel VoteQuery and CheckpointUtilQuery can indeed be merged as mentioned above.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I renamed CheckpointUtilQuery to CheckpointQuery and CheckpointQuery inherits VoteQuery.

src/manager/mod.rs Show resolved Hide resolved
src/manager/fevm.rs Outdated Show resolved Hide resolved
@adlrocha adlrocha merged commit c8e08d9 into refactor_checkpoint Jul 25, 2023
@adlrocha adlrocha deleted the refactor_top_down branch July 25, 2023 10:24
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.

None yet

2 participants