Bitcoin Core 28.99.0
P2P Digital Currency
mempool_limits.h
Go to the documentation of this file.
1// Copyright (c) 2022 The Bitcoin Core developers
2// Distributed under the MIT software license, see the accompanying
3// file COPYING or http://www.opensource.org/licenses/mit-license.php.
4#ifndef BITCOIN_KERNEL_MEMPOOL_LIMITS_H
5#define BITCOIN_KERNEL_MEMPOOL_LIMITS_H
6
7#include <policy/policy.h>
8
9#include <cstdint>
10
11namespace kernel {
27
31 static constexpr MemPoolLimits NoLimits()
32 {
33 int64_t no_limit{std::numeric_limits<int64_t>::max()};
34 return {no_limit, no_limit, no_limit, no_limit};
35 }
36};
37} // namespace kernel
38
39#endif // BITCOIN_KERNEL_MEMPOOL_LIMITS_H
static constexpr unsigned int DEFAULT_ANCESTOR_SIZE_LIMIT_KVB
Default for -limitancestorsize, maximum kilobytes of tx + all in-mempool ancestors.
Definition: policy.h:61
static constexpr unsigned int DEFAULT_DESCENDANT_LIMIT
Default for -limitdescendantcount, max number of in-mempool descendants.
Definition: policy.h:63
static constexpr unsigned int DEFAULT_DESCENDANT_SIZE_LIMIT_KVB
Default for -limitdescendantsize, maximum kilobytes of in-mempool descendants.
Definition: policy.h:65
static constexpr unsigned int DEFAULT_ANCESTOR_LIMIT
Default for -limitancestorcount, max number of in-mempool ancestors.
Definition: policy.h:59
Options struct containing limit options for a CTxMemPool.
static constexpr MemPoolLimits NoLimits()
int64_t descendant_count
The maximum allowed number of transactions in a package including the entry and its descendants.
int64_t descendant_size_vbytes
The maximum allowed size in virtual bytes of an entry and its descendants within a package.
int64_t ancestor_count
The maximum allowed number of transactions in a package including the entry and its ancestors.
int64_t ancestor_size_vbytes
The maximum allowed size in virtual bytes of an entry and its ancestors within a package.