Skip to content

Commit

Permalink
app: change max tx bytes constant to 96KB (#4683)
Browse files Browse the repository at this point in the history
## Describe your changes
During team sync today we decided that this new value is superior.



## Issue ticket number and link
Follow-up to related work in #4614, #4627, and #4632.

## Checklist before requesting a review

- [x] If this code contains consensus-breaking changes, I have added the
"consensus-breaking" label. Otherwise, I declare my belief that there
are not consensus-breaking changes, for the following reason:

> This change does affect consensus and so should be treated carefully.

Co-authored-by: Conor Schaefer <[email protected]>
  • Loading branch information
conorsch and conorsch authored Jun 28, 2024
1 parent a47cbf1 commit 9ba5a03
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions crates/core/app/src/app/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ type InterBlockState = Arc<StateDelta<Snapshot>>;
/// The maximum size of a CometBFT block payload (1MB)
const MAX_BLOCK_TXS_PAYLOAD_BYTES: usize = 1024 * 1024;

/// The maximum size of a single individual transaction (30KB).
const MAX_TRANSACTION_SIZE_BYTES: usize = 30 * 1024;
/// The maximum size of a single individual transaction (96KB).
const MAX_TRANSACTION_SIZE_BYTES: usize = 96 * 1024;

/// The maximum size of the evidence portion of a block (30KB).
const MAX_EVIDENCE_SIZE_BYTES: usize = 30 * 1024;
Expand Down
2 changes: 1 addition & 1 deletion testnets/cometbft_config_template.toml
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ keep-invalid-txs-in-cache = false

# Maximum size of a single transaction.
# NOTE: the max size of a tx transmitted over the network is {max_tx_bytes}.
max_tx_bytes = 30720
max_tx_bytes = 98304

# Maximum size of a batch of transactions to send to a peer
# Including space needed by encoding (one varint per transaction).
Expand Down

0 comments on commit 9ba5a03

Please sign in to comment.