feat(consensus): make validator execution concurrency configurable (v0.123) - #1723
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
|
/run-e2e studio |
4 similar comments
|
/run-e2e studio |
|
/run-e2e studio |
|
/run-e2e studio |
|
/run-e2e studio |
Replace the hardcoded asyncio.Semaphore(8) in CommittingState with the CONSENSUS_VALIDATOR_MAX_CONCURRENT env var (default 8, min 1) so large committees (23-47+ validators) are not serialized into ~6 rounds of 8. Port of the v0.121 change. Refs #1721
e4a013f to
a83d7b6
Compare
|
Retargeted to /run-e2e studio |
|
/run-e2e studio |




Refs #1721 — port of the same change targeting v0.121.
What
asyncio.Semaphore(8)inCommittingState.handlewith a module-levelVALIDATOR_MAX_CONCURRENTread from theCONSENSUS_VALIDATOR_MAX_CONCURRENTenv var (default 8, clamped to >= 1).backend/protocol_rpc/endpoints.pythat referenced the hardcoded value..env.example.Why
A 47-validator committee currently runs through a fixed window of 8 concurrent validator executions (~6 sequential rounds), dominating transaction latency. The cap itself is legitimate (GenVM subprocess memory / fd / DB-pool bounds) but the value 8 was arbitrary and not tunable. Deployments with adequate memory can now size it to their committee sizes. Default behavior is unchanged.
Testing done
python3 -m py_compileon both edited modules.