Currently the mempool isn't persisted across restarts. The historical argument against doing this is that it would make transactions immortal. Expiration now addresses that issue.

Without preserving the mempool node behavior changes drastically across restarts which complicates production use (e.g. mining overly small/low fee blocks) as well as development testing. The lack of retention also causes the loss of txn priority modifications made with prioritisetransaction which makes the API less reliable.

{
    
#ifdef _MSC_VER
    
    _CrtSetReportMode(_CRT_WARN, _CRTDBG_MODE_FILE);
    _CrtSetReportFile(_CRT_WARN, CreateFileA("NUL", GENERIC_WRITE, 0, NULL, OPEN_EXISTING, 0, 0));
#endif
#if _MSC_VER >= 1400
    
    _set_abort_behavior(0, _WRITE_ABORT_MSG | _CALL_REPORTFAULT);
#endif
#ifdef WIN32
    
    
    
#ifndef PROCESS_DEP_ENABLE
    
    
#define PROCESS_DEP_ENABLE 0x00000001
#endif
    typedef BOOL (WINAPI *PSETPROCDEPPOL)(DWORD);
    PSETPROCDEPPOL setProcDEPPol = (PSETPROCDEPPOL)GetProcAddress(GetModuleHandleA("Kernel32.dll"), "SetProcessDEPPolicy");
    if (setProcDEPPol != NULL) setProcDEPPol(PROCESS_DEP_ENABLE);
#endif
    if (!SetupNetworking())
        return InitError("Initializing networking failed");
#ifndef WIN32
    if (!GetBoolArg("-sysperms", false)) {
        umask(077);