private void processInvalid(
      final String[] commaSplit, final AbstractPrioritizedTransactions prioritizedTransactions) {
    final Bytes rlp = Bytes.fromHexString(commaSplit[commaSplit.length - 1]);
    final Transaction tx = Transaction.readFrom(rlp);
    if (tx.getSender().equals(senderToLog)) {
      LOG.warn("D {}, Before {}", tx.getNonce(), prioritizedTransactions.logSender(senderToLog));
    }
    prioritizedTransactions.remove(new PendingTransaction.Remote(tx), INVALIDATED);
    if (tx.getSender().equals(senderToLog)) {
      LOG.warn("After {}", prioritizedTransactions.logSender(senderToLog));
    }
  }
Ignored by default since this is useful to debug issues having a dump of txs that could be
quite big and so could take many minutes to execute. To generate the input file for the test
enable the LOG_FOR_REPLAY logger by adding these parts to the log4j2 configuration: in the
Appenders section add

<pre>{@code
<RollingFile name="txCSV" fileName="/data/besu/tx.csv" filePattern="/data/besu/tx-%d{MM-dd-yyyy}-%i.csv.gz">
   <PatternLayout>
       <Pattern>%m%n</Pattern>
   </PatternLayout>
   <Policies>
       <OnStartupTriggeringPolicy />
   </Policies>
</RollingFile>
}</pre>

in the Loggers section add

<pre>{@code
<Logger name="LOG_FOR_REPLAY" level="TRACE" additivity="false">
   <AppenderRef ref="txCSV" />
</Logger>
}</pre>

restart and let it run until you need it, then copy the CSV in the test resource folder.

@throws IOException when fails to read the resource
ethereum/eth/src/test/java/org/hyperledger/besu/ethereum/eth/transactions/layered/ReplayTest.java