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

[dag] support for highest committed round and latest ledger info on bootstrap #10122

Merged
merged 1 commit into from
Sep 26, 2023

Conversation

ibalajiarun
Copy link
Contributor

@ibalajiarun ibalajiarun commented Sep 19, 2023

Description

This PR changes bootstrapper so that the correct latest ledger info is passed to all the DAG components. If the ledger info in storage ends the epoch, then a genesis ledger info is created and given to the different DAG components. Similarly, for the parent block info for the adapter.

Also, extracts the highest committed round from dag store and isolates it with Arc<RwLock<>>

Test Plan

@ibalajiarun
Copy link
Contributor Author

@ibalajiarun ibalajiarun changed the title [dag] separate out highest committed round provider [dag] support for highest committed round and latest ledger info on bootstrap Sep 19, 2023
pub struct OrderedNotifierAdapter {
executor_channel: UnboundedSender<OrderedBlocks>,
storage: Arc<dyn DAGStorage>,
parent_block_info: Arc<RwLock<BlockInfo>>,
highest_committed_anchor_round: Arc<RwLock<Round>>,
Copy link
Contributor

Choose a reason for hiding this comment

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

i think we can just use atomicu64 instead?

Copy link
Contributor

Choose a reason for hiding this comment

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

But you still need the Arc because it is shared with state_sync_trigger, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Okay, we needed to cache the ledger info as well, so I introduced LedgerInfoProvider and a trait. New commit, lmk.

pub struct OrderedNotifierAdapter {
executor_channel: UnboundedSender<OrderedBlocks>,
storage: Arc<dyn DAGStorage>,
parent_block_info: Arc<RwLock<BlockInfo>>,
highest_committed_anchor_round: Arc<RwLock<Round>>,
Copy link
Contributor

Choose a reason for hiding this comment

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

But you still need the Arc because it is shared with state_sync_trigger, right?

@ibalajiarun ibalajiarun force-pushed the balaji/highest-commit-round branch 2 times, most recently from 71a1893 to b43b70b Compare September 21, 2023 16:36
@ibalajiarun ibalajiarun force-pushed the balaji/highest-commit-round branch 2 times, most recently from 4e12b67 to c596ce5 Compare September 21, 2023 16:49
Base automatically changed from balaji/split-notifier to main September 22, 2023 20:04
@zekun000 zekun000 enabled auto-merge (rebase) September 26, 2023 18:34
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

[dag] additional ledger info verification checks

[dag] separate out highest committed round provider

[dag] introduce a ledger info provider trait
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

✅ Forge suite compat success on aptos-node-v1.6.2 ==> 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b

Compatibility test results for aptos-node-v1.6.2 ==> 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b (PR)
1. Check liveness of validators at old version: aptos-node-v1.6.2
compatibility::simple-validator-upgrade::liveness-check : committed: 4716 txn/s, latency: 6802 ms, (p50: 7100 ms, p90: 9900 ms, p99: 10300 ms), latency samples: 179240
2. Upgrading first Validator to new version: 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b
compatibility::simple-validator-upgrade::single-validator-upgrade : committed: 1862 txn/s, latency: 15983 ms, (p50: 18900 ms, p90: 22200 ms, p99: 22400 ms), latency samples: 93100
3. Upgrading rest of first batch to new version: 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b
compatibility::simple-validator-upgrade::half-validator-upgrade : committed: 1393 txn/s, submitted: 1407 txn/s, expired: 13 txn/s, latency: 16277 ms, (p50: 18300 ms, p90: 22000 ms, p99: 26400 ms), latency samples: 89215
4. upgrading second batch to new version: 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b
compatibility::simple-validator-upgrade::rest-validator-upgrade : committed: 2633 txn/s, latency: 11641 ms, (p50: 13300 ms, p90: 16000 ms, p99: 16500 ms), latency samples: 113220
5. check swarm health
Compatibility test for aptos-node-v1.6.2 ==> 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b passed
Test Ok

@github-actions
Copy link
Contributor

✅ Forge suite realistic_env_max_load success on 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b

two traffics test: inner traffic : committed: 5845 txn/s, latency: 6709 ms, (p50: 6300 ms, p90: 8700 ms, p99: 15600 ms), latency samples: 2536760
two traffics test : committed: 100 txn/s, latency: 2679 ms, (p50: 2500 ms, p90: 3200 ms, p99: 8300 ms), latency samples: 1820
Latency breakdown for phase 0: ["QsBatchToPos: max: 0.221, avg: 0.212", "QsPosToProposal: max: 0.357, avg: 0.199", "ConsensusProposalToOrdered: max: 0.682, avg: 0.646", "ConsensusOrderedToCommit: max: 0.578, avg: 0.538", "ConsensusProposalToCommit: max: 1.230, avg: 1.184"]
Max round gap was 1 [limit 4] at version 1329542. Max no progress secs was 3.632036 [limit 10] at version 1329542.
Test Ok

@github-actions
Copy link
Contributor

✅ Forge suite framework_upgrade success on aptos-node-v1.5.1 ==> 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b

Compatibility test results for aptos-node-v1.5.1 ==> 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b (PR)
Upgrade the nodes to version: 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 4198 txn/s, latency: 4988 ms, (p50: 5000 ms, p90: 7800 ms, p99: 9000 ms), latency samples: 235140
5. check swarm health
Compatibility test for aptos-node-v1.5.1 ==> 6baa45c6ad2cbc5e39e394a2904bd0b8e470886b passed
Test Ok

@zekun000 zekun000 merged commit 62de329 into main Sep 26, 2023
42 of 44 checks passed
@zekun000 zekun000 deleted the balaji/highest-commit-round branch September 26, 2023 23:10
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.

3 participants