Skip to content

hosting and consuming checkpoint sync server API#479

Merged
ch4r10t33r merged 27 commits intomainfrom
checkpoint-state
Jan 14, 2026
Merged

hosting and consuming checkpoint sync server API#479
ch4r10t33r merged 27 commits intomainfrom
checkpoint-state

Conversation

@ch4r10t33r
Copy link
Copy Markdown
Contributor

@ch4r10t33r ch4r10t33r commented Jan 12, 2026

  • Add /lean/states/finalized API endpoint to serve finalized checkpoint state as SSZ binary
  • Add --checkpoint-sync-url CLI parameter to enable checkpoint sync from another zeam node
  • Implement client-side checkpoint state download, verification, and anchor state initialization

Motivation
Closes #469

Checkpoint sync allows new zeam nodes to bootstrap from a trusted node's finalized state rather than syncing from genesis. This significantly reduces initial sync time for nodes joining the network.

Attached screenshot demonstrating the working of the endpoint
Screenshot 2026-01-13 at 18 37 30
Screenshot 2026-01-13 at 18 37 52

@ch4r10t33r ch4r10t33r marked this pull request as draft January 12, 2026 10:37
@ch4r10t33r ch4r10t33r requested a review from g11tech January 12, 2026 13:19
@ch4r10t33r ch4r10t33r marked this pull request as ready for review January 12, 2026 13:22
@g11tech g11tech changed the title Checkpoint Sync API and Client Support hosting and consuming checkpoint sync server API Jan 12, 2026
@ch4r10t33r ch4r10t33r requested a review from g11tech January 12, 2026 18:36
@g11tech g11tech requested a review from anshalshukla January 12, 2026 18:44
@anshalshukla
Copy link
Copy Markdown
Collaborator

I think --metrics-port basically runs the API server on that port and /metrics is an endpoint over API server. I think we should update flags to use --api-port, not sure if there is a standard that has to be followed here amongst all the clients and also this will lead to changes in quickstart as well.

@ch4r10t33r
Copy link
Copy Markdown
Contributor Author

ch4r10t33r commented Jan 13, 2026

We should use std.http.Client here

Yes, I agree. We should address this and follow standard names. But, let me deal with it as a separate PR. I'll create an issue for this.

Created: #486

@anshalshukla
Copy link
Copy Markdown
Collaborator

LGTM!

@ch4r10t33r ch4r10t33r requested a review from g11tech January 13, 2026 13:30
@ch4r10t33r ch4r10t33r marked this pull request as draft January 13, 2026 17:15
@ch4r10t33r ch4r10t33r marked this pull request as ready for review January 13, 2026 18:46
@ch4r10t33r ch4r10t33r requested a review from g11tech January 13, 2026 18:47
@ch4r10t33r ch4r10t33r requested a review from g11tech January 14, 2026 11:29
@ch4r10t33r ch4r10t33r merged commit 059de39 into main Jan 14, 2026
12 checks passed
@ch4r10t33r ch4r10t33r deleted the checkpoint-state branch January 14, 2026 11:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

serve finalized checkpoint state on an api and use it to checkpoint start the client

3 participants