Skip to content
Snippets Groups Projects
  • Michal Kucharczyk's avatar
    `fatxpool`: size limits implemented (#6262) · ace62f12
    Michal Kucharczyk authored
    This PR adds size-limits to the fork-aware transaction pool.
    
    **Review Notes**
    - Existing
    [`TrackedMap`](https://github.com/paritytech/polkadot-sdk/blob/58fd5ae4/substrate/client/transaction-pool/src/graph/tracked_map.rs#L33-L41)
    is used in internal mempool to track the size of extrinsics:
    
    https://github.com/paritytech/polkadot-sdk/blob/58fd5ae4
    
    /substrate/client/transaction-pool/src/graph/tracked_map.rs#L33-L41
    
    - In this PR, I also removed the logic that kept transactions in the
    `tx_mem_pool` if they were immediately dropped by the views. Initially,
    I implemented this as an improvement: if there was available space in
    the _mempool_ and all views dropped the transaction upon submission, the
    transaction would still be retained in the _mempool_.
    
    However, upon further consideration, I decided to remove this
    functionality to reduce unnecessary complexity. Now, when all views drop
    a transaction during submission, it is automatically rejected, with the
    `submit/submit_and_watch` call returning `ImmediatelyDropped`.
    
    
    Closes: #5476
    
    ---------
    
    Co-authored-by: default avatarSebastian Kunert <skunert49@gmail.com>
    Co-authored-by: default avatarBastian Köcher <git@kchr.de>
    Unverified
    ace62f12
Code owners
Assign users and groups as approvers for specific file changes. Learn more.