table: Make LRU the default CS replacement policy
Change-Id: I01fe000544da9df860437ffc8869bc6b20e844c0
refs: #4728
diff --git a/daemon/mgmt/tables-config-section.hpp b/daemon/mgmt/tables-config-section.hpp
index d1ac1d4..932df2c 100644
--- a/daemon/mgmt/tables-config-section.hpp
+++ b/daemon/mgmt/tables-config-section.hpp
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2014-2016, Regents of the University of California,
+/*
+ * Copyright (c) 2014-2018, Regents of the University of California,
* Arizona Board of Regents,
* Colorado State University,
* University Pierre & Marie Curie, Sorbonne University,
@@ -38,7 +38,7 @@
* tables
* {
* cs_max_packets 65536
- * cs_policy priority_fifo
+ * cs_policy lru
* cs_unsolicited_policy drop-all
*
* strategy_choice
diff --git a/daemon/table/cs.cpp b/daemon/table/cs.cpp
index 1663d8f..85ef388 100644
--- a/daemon/table/cs.cpp
+++ b/daemon/table/cs.cpp
@@ -37,11 +37,10 @@
NFD_LOG_INIT(ContentStore);
-unique_ptr<Policy>
+static unique_ptr<Policy>
makeDefaultPolicy()
{
- const std::string DEFAULT_POLICY = "priority_fifo";
- return Policy::create(DEFAULT_POLICY);
+ return Policy::create("lru");
}
Cs::Cs(size_t nMaxPackets)