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

[Byzantine testing] - View Lagging node #3609

Merged
merged 16 commits into from
Sep 3, 2024
Merged

Conversation

lukeiannucci
Copy link
Contributor

@lukeiannucci lukeiannucci commented Aug 23, 2024

Closes (#3608)

This PR:

Adds a byzantine test where we have one node that is constantly behind by a a configurable set of views on the receive handle. When node receives an event for current view it will return an event that is cached.
Also this PR cleans up where we keep the Byzantine tests.

This PR does not:

Key places to review:

ViewDelay struct and how it implements EventTransformerState to see the logic of how we handle delayed views. Also /crates/testing/src/byzantine this is where i moved the byzantine logic to. And crates/testing/tests/tests_2 is where byzantine tests are placed.

@lukeiannucci lukeiannucci linked an issue Aug 23, 2024 that may be closed by this pull request
@CLAassistant
Copy link

CLAassistant commented Aug 26, 2024

CLA assistant check
All committers have signed the CLA.

@lukeiannucci lukeiannucci marked this pull request as ready for review August 26, 2024 19:27
@lukeiannucci lukeiannucci requested a review from bfish713 as a code owner August 26, 2024 19:27
crates/testing/tests/tests_2/byzantine_tests.rs Outdated Show resolved Hide resolved
crates/testing/src/byzantine/byzantine_behaviour.rs Outdated Show resolved Hide resolved
crates/testing/src/byzantine/byzantine_behaviour.rs Outdated Show resolved Hide resolved
crates/testing/src/byzantine/byzantine_behaviour.rs Outdated Show resolved Hide resolved
crates/testing/src/byzantine/byzantine_behaviour.rs Outdated Show resolved Hide resolved
@bfish713
Copy link
Collaborator

I'm not sure this does what it's supposed to do, my read of the logic is that is delays each event type by a number of views. So if we get a proposal for view 2 with a delay of 1 we'll actually broadcast the proposal for 1 but we wouldn't broadcast a DAC or VID share for view 1. With votes this is really awkward because it means at minimum the voting is delayed until our next leadership because that's the next time we'll get a vote

@lukeiannucci lukeiannucci force-pushed the li/byzantine-view-delay branch from c8048c7 to c374244 Compare August 27, 2024 14:00
@lukeiannucci lukeiannucci requested a review from ss-es as a code owner August 27, 2024 14:00
@lukeiannucci lukeiannucci requested a review from bfish713 August 27, 2024 17:41
Copy link
Contributor

@ss-es ss-es left a comment

Choose a reason for hiding this comment

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

Not sure if there was anything specific you wanted me to check, but looks fine to me overall - just one minor comment about remove (not 100% sure if that's what the method is) vs. get.

crates/testing/src/byzantine/byzantine_behaviour.rs Outdated Show resolved Hide resolved
@lukeiannucci lukeiannucci force-pushed the li/byzantine-view-delay branch from 64414de to e8b5582 Compare September 3, 2024 16:44
Copy link
Contributor

@ss-es ss-es left a comment

Choose a reason for hiding this comment

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

Looks good to me!

@lukeiannucci lukeiannucci force-pushed the li/byzantine-view-delay branch from aa9bacf to 8ca07b5 Compare September 3, 2024 19:38
@lukeiannucci lukeiannucci merged commit 60e3731 into main Sep 3, 2024
36 checks passed
@lukeiannucci lukeiannucci deleted the li/byzantine-view-delay branch September 3, 2024 20:13
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.

[Byzantine testing] - View Lagging node
6 participants