-
Notifications
You must be signed in to change notification settings - Fork 0
Updates to the attestation propagation sim #9
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
Conversation
Seggregate nodes into Mesh Nodes, Mesh Attester Nodes and Non-mesh attester nodes.
| case <-ctx.Done(): | ||
| return pubsub.ValidationReject | ||
| case <-time.After(100 * time.Millisecond): | ||
| // Timeout after 50ms (should be well within batch processing time) |
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.
stale comment
Makefile
Outdated
| uv run plot_propagation.py $(NODE_COUNT) --topology-file $(TOPOLOGY_FILE) --peer-count $(PEER_COUNT) --non-mesh-node-peer-count $(NON_MESH_NODE_PEER_COUNT) --batch-interval $(BATCH_INTERVAL) --batch-verifier-time $(BATCH_VERIFIER_TIME) -o plots/batch_$(BATCH_INTERVAL)ms_node$(NODE_COUNT)_mesh_nodes$(MESH_NODE_COUNT)_mesh_attesters$(MESH_ATTESTER_COUNT)_non_mesh_attesters$(NON_MESH_ATTESTER_COUNT).png | ||
| @test -f plots/batch_$(BATCH_INTERVAL)ms_node$(NODE_COUNT)_mesh_nodes$(MESH_NODE_COUNT)_mesh_attesters$(MESH_ATTESTER_COUNT)_non_mesh_attesters$(NON_MESH_ATTESTER_COUNT).png && echo "Plot generated: plots/batch_$(BATCH_INTERVAL)ms_node$(NODE_COUNT)_mesh_nodes$(MESH_NODE_COUNT)_mesh_attesters$(MESH_ATTESTER_COUNT)_non_mesh_attesters$(NON_MESH_ATTESTER_COUNT).png" || echo "Plot generation failed" |
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.
The names are a little long. Probably we could shorten them
|
|
||
| # Build args with topology file | ||
| args = f"-node-id {i} -node-count {node_count} -msg-size {msg_size} -topology-file {topology_file}" | ||
| # Build args with topology file, nodes to publish, and batch parameters |
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.
stale comment.
Implement a SlotTicker to keep track of runs
| return | ||
| } | ||
|
|
||
| time.Sleep(bv.batchVerifierTime) |
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.
Instead of having a hard coded batch verifier time. It would be better to define the time taken per signature and multiply it with the batch size. That would be more accurate.
Split nodes by client types
updates to attsim
raulk
left a comment
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.
Merging to review everything at once on main.
This PR has logic to:
Mesh Nodes,Mesh Attester NodesandNon-Mesh Attester Nodes.Mesh Nodesare nodes which subscribe to the topic but do not publish.Mesh Attester Nodessubscribe to the topic and also publish messages.Non-Mesh Attester Nodesdo not subscribe to the topic but publish messages. Attsim uses nodeIds to give each node a unique ID. We reserve the first n IDs for the nMesh Nodes, The next k ids for the kMesh Attester Nodesand the remaining ids forNon-Mesh Attester Nodes.Non-Mesh Attester Nodesare only connected toMesh NodesandMesh Attester Nodeswith a degree which can be specified in theNON_MESH_NODE_PEER_COUNTflag in the Makefile.BATCH_INTERVALi.e how frequently the batch is flushed and verified andBATCH_VERIFIER_TIMEto define the time taken for the batch verifier to run. The BLS batch verification simulation is integrated into the async validator for the topic. When we receive a message for async validation, it is sent to the BLS batch verification simulator where it sits in a batch until it is flushed and the batch verifier runs(it just runs as a sleep in this case)Slotsimilar to an Ethereum slot. We use this to run the simulation for any given number of times.SimConfigfile to which we will eventually move all simulation parameters.