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

Gossip recently computed light client data #7023

Open
wants to merge 5 commits into
base: release-v7.0.0
Choose a base branch
from

Conversation

eserilev
Copy link
Collaborator

@eserilev eserilev commented Feb 21, 2025

Gossip recently constructed light client data when POST validator/contribution_and_proofs is called

i've chosen this endpoint, because its already publishing data to the network, it's called at every slot for validators in an active sync committee, and a POST seems like the better method to trigger publishing data to the network vs GET

Keep track of the latest broadcasted finality and optimistic updates. That way, even if the POST validator/contribution_and_proofs endpoint is spammed with junk data, we'll only gossip the same finality/optimistic update once.

@eserilev eserilev changed the title add logic to gossip light client updates post computation Gossip recently computed light client data Feb 21, 2025
@eserilev eserilev added light-client ready-for-review The code is ready for review v7.0.0 New release c. Q1 2025 labels Feb 21, 2025
@dapplion
Copy link
Collaborator

Is this part of the spec? This way the entire network will broadcast the updates at once

@eserilev eserilev added work-in-progress PR is a work-in-progress and removed ready-for-review The code is ready for review labels Feb 21, 2025
@eserilev
Copy link
Collaborator Author

agreeed that it seems very wasteful for everyone to broadcast light client updates at once. The spec doesnt seem to mention how this should work, I've reached out in the light client channel on eth r&d discord for further clarification

@eserilev
Copy link
Collaborator Author

eserilev commented Feb 23, 2025

Etan has suggested that we restrict the initial light client data publishing to the current sync committee. I think that sounds reasonable to me, but it would require introducing a new beacon api endpoint. I'll work on speccing something out.

@michaelsproul
Copy link
Member

michaelsproul commented Feb 23, 2025

Why do we need a new beacon API? Could we implement something based on the existing sync committee subscription API? e.g. only publish if we have received a sync committee subscription in the last N epochs.

I think we could get that info from the NetworkService which processes the sync committee subscriptions, or by hooking into the existing HTTP handler. Hooking the HTTP handler might be cleaner, as the network code mostly uses channels to communicate so I'm not sure if we should be reaching into it to read info.

@eserilev
Copy link
Collaborator Author

eserilev commented Feb 24, 2025

yeah, you're right, we don't need a new beacon api, I think overloading one of the http endpoints makes the most sense

@eserilev eserilev added ready-for-review The code is ready for review and removed work-in-progress PR is a work-in-progress labels Feb 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
light-client ready-for-review The code is ready for review v7.0.0 New release c. Q1 2025
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants