-
-
Notifications
You must be signed in to change notification settings - Fork 411
fix: emit blob_sidecar event as soon as we receive BlobSidecars
#7967
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
blob_sidecar event as soon as we receive BlobSidecars
| await sleep(msToBlockSlot); | ||
| } | ||
|
|
||
| chain.emitter.emit(routes.events.EventType.blockGossip, {slot, block: blockRoot}); |
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.
moved event down to emit it after we publish to the network
| ]; | ||
| await promiseAllMaybeAsync(publishPromises); | ||
|
|
||
| if (chain.emitter.listenerCount(routes.events.EventType.blockGossip)) { |
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.
we should probably add this check to a bunch more events, I don't see why we would emit them if there is no listener
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## unstable #7967 +/- ##
============================================
- Coverage 55.74% 55.71% -0.04%
============================================
Files 833 833
Lines 59383 59418 +35
Branches 4582 4583 +1
============================================
- Hits 33105 33104 -1
- Misses 26211 26247 +36
Partials 67 67 🚀 New features to boost your workflow:
|
Performance Report🚀🚀 Significant benchmark improvement detected
Full benchmark results
|
|
🎉 This PR is included in v1.32.0 🎉 |
Motivation
Right now we only emit
blob_sidecarevent during block import when we have received all blobs but this is not ideal as the event is mostly used to gather timing information of when blobs are received by nodes in the network. We should emit the event as soon as possible similar to #7953.Description
Emit
blob_sidecarevent as soon as we receiveBlobSidecarpublishBlockapi if we are proposerblob_sidecargossip topic from the networkengine_getBlobsV1methodblob_sidecars_by_rootmethod