-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[api] Change block APIs to by default return all transactions #13365
Conversation
⏱️ 38m total CI duration on this PR
🚨 1 job on the last run was significantly faster/slower than expected
|
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.
well the caveat here being that blocksizes can be up to 10K or more txns, so in theory that could be well over a mega... thoughts?
The limit right now is 1900 txns. It could be over a mega, but given that there's already a function that waits a second, I'm not super concerned for now. Choosing UX for this for now. |
@@ -53,6 +53,8 @@ pub struct ApiConfig { | |||
pub max_submit_transaction_batch_size: usize, | |||
/// Maximum page size for transaction paginated APIs | |||
pub max_transactions_page_size: u16, | |||
/// Maximum page size for block transaction APIs | |||
pub max_block_transactions_page_size: u16, |
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.
Call me crazy but is u16 too small? I can imagine a world where MAX_SENDING_BLOCK_TXNS is larger than u16 max. Maybe either make this u32 or cast MAX_SENDING_BLOCK_TXNS to u16 safely (ceil).
The block size has a limit, and therefore, the limit has a limit, where the transactions API would likely be more variable. Therefore, it should be fine to make the block API return the entire block.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
✅ Forge suite
|
✅ Forge suite
|
✅ Forge suite
|
Description
The block size has a limit, and therefore, the limit has a limit, where the transactions API would likely be more variable. Therefore, it should be fine to make the block API return the entire block.
Type of Change
Which Components or Systems Does This Change Impact?
How Has This Been Tested?
Changing default, it has not been tested yet.
Key Areas to Review
Checklist