<div dir="ltr">Hi everyone,<br><br><br>I&#39;d like to propose a new set of requirements as a policy on when to accept new transactions into the mempool and relay them.  This policy would affect transactions which have as inputs other transactions which are not yet confirmed in the blockchain.<br><br>The motivation for this policy is <a href="https://github.com/bitcoin/bitcoin/pull/6470">6470</a> which aims to limit the size of a mempool.  <a href="https://github.com/bitcoin/bitcoin/pull/6470#issuecomment-125324736">As discussed in that pull</a>, once the mempool is full a new transaction must be able to pay not only for the transaction it would evict, but any dependent transactions that would be removed from the mempool as well.  In order to make sure this is always feasible, I&#39;m proposing 4 new policy limits.<div><br></div><div>All limits are command line configurable.<br><br>The first two limits are required to make sure no chain of transactions will be too large for the eviction code to handle:<br><br>Max number of descendant txs : No transaction shall be accepted if it would cause another transaction in the mempool to have too many descendant transactions (all of which would have to be evicted if the ancestor transaction was evicted).  Default: 1000<br><br>Max descendant size : No transaction shall be accepted if it would cause another transaction in the mempool to have the total size of all its descendant transactions be too great.  Default : maxmempool / 200  =  2.5MB<br><br>The third limit is required to make sure calculating the state required for sorting and limiting the mempool and enforcing the first 2 limits is computationally feasible:<br><br>Max number of ancestor txs:  No transaction shall be accepted if it has too many ancestor transactions which are not yet confirmed (ie, in the mempool). Default: 100<br><br>The fourth limit is required to maintain the pre existing policy goal that all transactions in the mempool should be mineable in the next block.<br><br>Max ancestor size: No transaction shall be accepted if the total size of all its unconfirmed ancestor transactions is too large.  Default: 1MB<br><br>(All limits include the transaction itself.)<br><br>For reference, these limits would have affected less than 2% of transactions entering the mempool in April or May of this year.  During the period of 7/6 through 7/14, while the network was under stress test, as many as 25% of the transactions would have been affected.<br><br></div><div>The code to implement the descendant package tracking and new policy limits can be found in <a href="https://github.com/bitcoin/bitcoin/pull/6557">6557</a> which is built off of 6470.<br><br></div><div>Thanks,</div><div>Alex</div><div><br></div></div>