Skip to content

Clarify and Clean Up Unused Transaction Size & Block Transaction Constants #139

@raymondkfcheung

Description

@raymondkfcheung

pallet-transaction-storage defines several constants that appear unused or unclear in purpose:

/// Maximum bytes that can be stored in one transaction.
// TODO: find out what is "allocator" and "allocator limit"
// Setting higher limit also requires raising the allocator limit.
// TODO: not used, can we remove or use?
pub const DEFAULT_MAX_TRANSACTION_SIZE: u32 = 8 * 1024 * 1024;

// TODO: not used, can we remove or use?
pub const DEFAULT_MAX_BLOCK_TRANSACTIONS: u32 = 512;

Tasks:

  • Determine the intended role of these defaults.
  • Confirm whether they are actually used anywhere in the runtime or pallet logic.
  • Clarify what “allocator” / “allocator limit” refers to and whether it constrains these values.
  • Decide whether to remove them, replace them with configuration items, or integrate them properly.
  • Update comments and code accordingly.

Related:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions