Compilation fixes after upgrade to NFD 0.6.6 and removal of old-style CS
Change-Id: I5472ae71675d8419d8d6c70990182ef028803087
diff --git a/examples/ndn-load-balancer/random-load-balancer-strategy.cpp b/examples/ndn-load-balancer/random-load-balancer-strategy.cpp
index 4f61162..27756cd 100644
--- a/examples/ndn-load-balancer/random-load-balancer-strategy.cpp
+++ b/examples/ndn-load-balancer/random-load-balancer-strategy.cpp
@@ -1,12 +1,12 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2014, Regents of the University of California,
- * Arizona Board of Regents,
- * Colorado State University,
- * University Pierre & Marie Curie, Sorbonne University,
- * Washington University in St. Louis,
- * Beijing Institute of Technology,
- * The University of Memphis
+/*
+ * Copyright (c) 2014-2019, Regents of the University of California,
+ * Arizona Board of Regents,
+ * Colorado State University,
+ * University Pierre & Marie Curie, Sorbonne University,
+ * Washington University in St. Louis,
+ * Beijing Institute of Technology,
+ * The University of Memphis
*
* This file is part of NFD (Named Data Networking Forwarding Daemon).
* See AUTHORS.md for complete list of NFD authors and contributors.
@@ -29,7 +29,7 @@
#include <ndn-cxx/util/random.hpp>
-#include "core/logger.hpp"
+#include "daemon/common/logger.hpp"
NFD_LOG_INIT("RandomLoadBalancerStrategy");
@@ -61,7 +61,7 @@
}
void
-RandomLoadBalancerStrategy::afterReceiveInterest(const Face& inFace, const Interest& interest,
+RandomLoadBalancerStrategy::afterReceiveInterest(const FaceEndpoint& ingress, const Interest& interest,
const shared_ptr<pit::Entry>& pitEntry)
{
NFD_LOG_TRACE("afterReceiveInterest");
@@ -75,7 +75,7 @@
const fib::NextHopList& nexthops = fibEntry.getNextHops();
// Ensure there is at least 1 Face is available for forwarding
- if (!hasFaceForForwarding(inFace, nexthops, pitEntry)) {
+ if (!hasFaceForForwarding(ingress.face, nexthops, pitEntry)) {
this->rejectPendingInterest(pitEntry);
return;
}
@@ -90,9 +90,9 @@
for (selected = nexthops.begin(); selected != nexthops.end() && currentIndex != randomIndex;
++selected, ++currentIndex) {
}
- } while (!canForwardToNextHop(inFace, pitEntry, *selected));
+ } while (!canForwardToNextHop(ingress.face, pitEntry, *selected));
- this->sendInterest(pitEntry, selected->getFace(), interest);
+ this->sendInterest(pitEntry, FaceEndpoint(selected->getFace(), 0), interest);
}
const Name&
diff --git a/examples/ndn-load-balancer/random-load-balancer-strategy.hpp b/examples/ndn-load-balancer/random-load-balancer-strategy.hpp
index ef11ae8..1a2e2c0 100644
--- a/examples/ndn-load-balancer/random-load-balancer-strategy.hpp
+++ b/examples/ndn-load-balancer/random-load-balancer-strategy.hpp
@@ -38,10 +38,11 @@
public:
RandomLoadBalancerStrategy(Forwarder& forwarder, const Name& name = getStrategyName());
- virtual ~RandomLoadBalancerStrategy() override;
+ virtual
+ ~RandomLoadBalancerStrategy() override;
- virtual void
- afterReceiveInterest(const Face& inFace, const Interest& interest,
+ void
+ afterReceiveInterest(const FaceEndpoint& ingress, const Interest& interest,
const shared_ptr<pit::Entry>& pitEntry) override;
static const Name&