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

core: use finalized block as the chain freeze indicator #2181

Closed
wants to merge 4 commits into from

Conversation

jingjunLi
Copy link
Contributor

@jingjunLi jingjunLi commented Jan 25, 2024

Description

This pull request uses the finalized block tag as the indicator for chain freezing.

Originally, the latest 90K blocks will be retained in the key-value store by default, which are regarded as "non-finalized" in the context of Proof-of-work. However, in Proof-of-stake, we do have the concrete finalized block tag from the consensus client. Therefore, it makes more sense to directly rely on the Finalized for chain freezing.

Rationale

By deploying it on a full node, we can see there are only 23 blocks left in the key-value store.
image

Example

add an example CLI or API response...

Changes

Notable changes:

  • add each change in a bullet point here
  • ...

@jingjunLi jingjunLi marked this pull request as draft January 25, 2024 07:23
@fynnss
Copy link
Contributor

fynnss commented Jan 30, 2024

Change the freezerRecheckInterval to 15s or less?

Currently it's 1min and will generate 20 blocks during the interval, plus 2-3 un-finalized blocks.

@jingjunLi
Copy link
Contributor Author

Change the freezerRecheckInterval to 15s or less?

Currently it's 1min and will generate 20 blocks during the interval, plus 2-3 un-finalized blocks.

fixed

core: fix freezerRecheckInterval to 15s
@jingjunLi
Copy link
Contributor Author

Merge it to #2227

@jingjunLi jingjunLi closed this Feb 22, 2024
@jingjunLi jingjunLi deleted the improve-chain-freezer branch May 31, 2024 09:16
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.

3 participants