| 91 | } |
| 92 | |
| 93 | void NvmCacheTest::coldRoll() { |
| 94 | // to simulate a cold roll, we shutdown safely and then explicitly create a |
| 95 | // new one for the ram part |
| 96 | if (cache_->shutDown() != LruAllocator::ShutDownStatus::kSuccess) { |
| 97 | throw std::runtime_error("Failed to cold roll"); |
| 98 | } |
| 99 | cache_ = |
| 100 | std::make_unique<LruAllocator>(LruAllocator::SharedMemNew, allocConfig_); |
| 101 | id_ = cache_->addPool("default", poolSize_, poolAllocsizes_); |
| 102 | } |
| 103 | |
| 104 | void NvmCacheTest::iceRoll() { |
| 105 | // shutdown with warm roll and indicatae that we want to drop navy |