-
Notifications
You must be signed in to change notification settings - Fork 175
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
Add source param to getLightClientOptimisticUpdate #288
Conversation
types/api.yaml
Outdated
|
||
SyncAggregateSource: | ||
type: string | ||
enum: ["block", "signedcontributionandproof_pool", "synccommitteemessage_pool"] |
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.
these are really hard to read...
given block means block.body.sync_aggregate
, maybe it makes sense to do something like
pool_committee_message
pool_contribution_and_proof
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.
Thanks! Picked an awful name to trigger suggestions 😄
Who are the right people to decide on this vs. the alternative you mentioned? I'm not really across the space, and would prefer the right people ultimately make the decision on this one, i'm happy to approve and merge if there's agreement... |
Let's sit on it for 2 more weeks to collect input during interop |
I don't like the side effect of GET request to "MUST subscribe to topics and aggregate" which is a heavy operation. The functionality is already available using the validator namespace, and is more explicit (turn on subscription, then just ask for producing contributions whenever one has interest in it). This makes it explicit to express intent, instead of having nasty side effect to GET requests. For application, they typically have a certain minimum percentage of signatures they want to ensure, so this new endpoint doesn't help that much either because application doesn't know when that threshold is reached, or it waits longer than necessary to ask the BN, so the API is not really optimal for that use case either. |
Agree with @etan-status 's points, so closing |
Route
getLightClientOptimisticUpdate
exposes aLightClientOptimisticUpdate
produced with the SyncAggregate of the head block. This PR allows to customize this behaviour to support consumers that need a more "timely" SyncAggregate.Proposed values of
source
param:block
(default): Get SyncAggregate from current's head block body,body.sync_aggregate
pool_contribution_and_proof
: Construct SyncAggregate from aggregatingSignedContributionAndProof
objects in the node's pool received from the gossip topicsync_committee_contribution_and_proof
. MUST aggregate messages withmessage.contribution.slot == current_slot
andmessage.contribution.beacon_block_root == head_root
.pool_committee_message
: Construct SyncAggregate from aggregatingSyncCommitteeMessage
objects in the node's pool received from the gossip topicssync_committee_{subnet_id}
. MUST aggregate messages withslot == current_slot
andbeacon_block_root == head_root
. After receiving asignatures
request, the node SHOULD subscribe to all sync committee subnets.Since
source
param is optional and defaults toblock
I guess this is non-breaking change with the current rules of the repo right?