fw: use RetxSuppressionExponential in best-route
Retransmission suppression algorithm of best route strategy
is changed from fixed interval to exponential backoff.
This is a semantical change which requires an increment of the
strategy's version number from 2 to 3.
Version 2 is not retained because it's mostly same as version 3.
refs #1913
Change-Id: I0f18511a3b96384b071024864e638ae3b3ec7080
diff --git a/daemon/fw/best-route-strategy2.cpp b/daemon/fw/best-route-strategy2.cpp
index d243a37..2ec786c 100644
--- a/daemon/fw/best-route-strategy2.cpp
+++ b/daemon/fw/best-route-strategy2.cpp
@@ -31,7 +31,7 @@
NFD_LOG_INIT("BestRouteStrategy2");
-const Name BestRouteStrategy2::STRATEGY_NAME("ndn:/localhost/nfd/strategy/best-route/%FD%02");
+const Name BestRouteStrategy2::STRATEGY_NAME("ndn:/localhost/nfd/strategy/best-route/%FD%03");
NFD_REGISTER_STRATEGY(BestRouteStrategy2);
BestRouteStrategy2::BestRouteStrategy2(Forwarder& forwarder, const Name& name)
diff --git a/daemon/fw/best-route-strategy2.hpp b/daemon/fw/best-route-strategy2.hpp
index 603be0e..bf3eba2 100644
--- a/daemon/fw/best-route-strategy2.hpp
+++ b/daemon/fw/best-route-strategy2.hpp
@@ -27,18 +27,18 @@
#define NFD_DAEMON_FW_BEST_ROUTE_STRATEGY2_HPP
#include "strategy.hpp"
-#include "retx-suppression-fixed.hpp"
+#include "retx-suppression-exponential.hpp"
namespace nfd {
namespace fw {
-/** \brief Best Route strategy version 2
+/** \brief Best Route strategy version 3
*
* This strategy forwards a new Interest to the lowest-cost nexthop (except downstream).
- * After that, it recognizes consumer retransmission:
- * if a similar Interest arrives from any downstream after MIN_RETRANSMISSION_INTERVAL,
- * the strategy forwards the Interest again to the lowest-cost nexthop (except downstream)
- * that is not previously used. If all nexthops have been used, the strategy starts over.
+ * After that, if consumer retransmits the Interest (and is not suppressed according to
+ * exponential backoff algorithm), the strategy forwards the Interest again to
+ * the lowest-cost nexthop (except downstream) that is not previously used.
+ * If all nexthops have been used, the strategy starts over.
*/
class BestRouteStrategy2 : public Strategy
{
@@ -55,7 +55,7 @@
static const Name STRATEGY_NAME;
private:
- RetxSuppressionFixed m_retxSuppression;
+ RetxSuppressionExponential m_retxSuppression;
};
} // namespace fw