-
Notifications
You must be signed in to change notification settings - Fork 11.3k
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
[Consensus] introduce consensus only simtests #20683
base: main
Are you sure you want to change the base?
Conversation
…e ip allocation issues. Create example simtest.
…. Extract the authority building method and reuse across containers.
The latest updates on your projects. Learn more about Vercel for Git ↗︎ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work!
sui-macros.workspace = true | ||
sui-protocol-config.workspace = true | ||
sui-simulator.workspace = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be in [target.'cfg(msim)'.dependencies]
, and potentially other additional dependencies.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or maybe it is better to have a consensus-simulator
crate?
@@ -0,0 +1,11 @@ | |||
// Copyright (c) Mysten Labs, Inc. | |||
// SPDX-License-Identifier: Apache-2.0 | |||
pub mod node; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why pub
?
}; | ||
|
||
#[derive(Clone)] | ||
#[allow(unused)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why unused
?
use std::sync::Arc; | ||
use tracing::info; | ||
|
||
pub(crate) struct AuthorityNodeContainer { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is it necessary to create this struct when not using simtest
target?
Description
PR is introducing the framework to enable us run Consensus-only simtests. Looking on the existing sui-swarm it would be a bit challenging to reuse as APIs are different and especially when we need to access consensus specific components.
The PR is using similar patterns that have been used in sui-swarm but I am expecting to refine this as we go. This might be a good start for now. A simple simtest method has been added for the time being
test_committee_start_simple
. Eventually we want to replace the tests onauthority_node
and add a few more cases. Motivation to do this has been the Garbage Collection work when investigating some edge cases where reproducibility was important to confirm the issues.Example to run this simtest with additional logging, a high regional variance in latency, and outputting the result in
output.txt
Test plan
CI
Release notes
Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required.
For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates.