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

Max limit on chunk size #3458

Open
MaksymZavershynskyi opened this issue Oct 5, 2020 · 6 comments
Open

Max limit on chunk size #3458

MaksymZavershynskyi opened this issue Oct 5, 2020 · 6 comments
Assignees
Labels
A-chain Area: Chain, client & related C-enhancement Category: An issue proposing an enhancement or a PR with one. T-core Team: issues relevant to the core team

Comments

@MaksymZavershynskyi
Copy link
Contributor

MaksymZavershynskyi commented Oct 5, 2020

As suggested by @mikhailOK , we need to introduce two types of limits into our protocol for chunks:

  • Limit the total size of the transactions in bytes;
  • Limit the total state diff in bytes (how much the state is changed by an individual chunk);

Both of these limits will allow to early filter out state sync and chunk messages on a network level. Currently, this is partially limited by the gas limit of the chunk, however there are two issues with it:

  • it is complex and laborious to maintain formulas that compute from the gas limit the size of the transactions in bytes, and the size of the state diff in bytes;
  • 10^15 gas might allow the total transactions sizes that are too large and we want to avoid.

CC @SkidanovAlex , @bowenwang1996 , @evgenykuzyakov

@MaksymZavershynskyi MaksymZavershynskyi added the A-chain Area: Chain, client & related label Oct 5, 2020
@SkidanovAlex
Copy link
Collaborator

Why is the total diff of the state change matter?

@MaksymZavershynskyi
Copy link
Contributor Author

Please disregard. I thought it was so that OOM cannot be caused by we can have at most ~32MiB of state diff per chunk, which is 3.2GiB for 100 shards which should be tolerable.

@bowenwang1996
Copy link
Collaborator

Depending on how we want to implement this, #3274 may need to be addressed first.

@bowenwang1996 bowenwang1996 changed the title [Discussion] Max limit on transactions and state update size Max limit on chunk size Oct 16, 2020
@bowenwang1996 bowenwang1996 added C-enhancement Category: An issue proposing an enhancement or a PR with one. T-core Team: issues relevant to the core team labels Jun 29, 2021
@stale
Copy link

stale bot commented Sep 27, 2021

This issue has been automatically marked as stale because it has not had recent activity in the last 2 months.
It will be closed in 7 days if no further activity occurs.
Thank you for your contributions.

@stale stale bot added the S-stale label Sep 27, 2021
@stale
Copy link

stale bot commented Dec 27, 2021

This issue has been automatically marked as stale because it has not had recent activity in the last 2 months.
It will be closed in 7 days if no further activity occurs.
Thank you for your contributions.

@stale stale bot added the S-stale label Dec 27, 2021
@stale
Copy link

stale bot commented Mar 29, 2022

This issue has been automatically marked as stale because it has not had recent activity in the last 2 months.
It will be closed in 7 days if no further activity occurs.
Thank you for your contributions.

@stale stale bot added the S-stale label Mar 29, 2022
@akhi3030 akhi3030 removed the S-stale label Jul 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-chain Area: Chain, client & related C-enhancement Category: An issue proposing an enhancement or a PR with one. T-core Team: issues relevant to the core team
Projects
None yet
Development

No branches or pull requests

4 participants