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

Light client specs checklist #2315

Open
2 of 6 tasks
hwwhww opened this issue Apr 7, 2021 · 0 comments
Open
2 of 6 tasks

Light client specs checklist #2315

hwwhww opened this issue Apr 7, 2021 · 0 comments

Comments

@hwwhww
Copy link
Contributor

hwwhww commented Apr 7, 2021

  • 1. Server discovery: How can light clients find servers efficiently?
  • 2. Find LightClientSnapshot initially: as @djrtwo mentioned, Req/Resp may not be good snapshot resource.
    • [Proposal] Can we say, we expect 3rd party to provide LightClientSnapshot + Merkle proofs or multi-proof of each field, where the proof can be verified against WS source?
  • 3. Block tree verification in current time-out procedure and reorg: In the current spec, a timeout-triggered (8192 slots, ~27 hours ) update logic exists:
    • Step 1, on_light_client_update, light client appends the valid update
    • Step 2, when timeout, call apply_light_client_update to update the store snapshot with the most voted update from store.valid_updates.
    • [Proposal]: In step 1, for the non-finality update (update.finality_header == BeaconBlockHeader()), should we add assert of checking if the update.header is descendant of snapshot.header. (<-- as @vbuterin suggested, make the light client updates always rooted in a finalized block.)
      • This procedure assumes that the light client already has store.valid_updates before timeout. That is, at the timeout slot, either (i) the server has to send a chain of updates to the light clients, or (ii) the light client has to request for the updates.
    • Or apply other reorgable light client solutions? (Light client reorg mechanism #2182)
  • 4. Use gossip as default sync resource and then servers just as backup?
  • 5. More comprehensive/production client-server model
    • @protolambda: If this is a push-update, and there is no explicit subscription kind of approach for a light client, then we should spec out when and how often the server pushes the update.

Other questions:

  • EPOCHS_PER_SYNC_COMMITTEE_PERIOD is 2**8 epochs = 2**13 slots ~= 27 hours. LIGHT_CLIENT_UPDATE_TIMEOUT is also 2**13 slots ~= 27 hours.
    1. Should we just keep one constant?
    2. If not, is EPOCHS_PER_SYNC_COMMITTEE_PERIOD >= LIGHT_CLIENT_UPDATE_TIMEOUT an invariant?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants
@hwwhww and others