Upgrade the underlying NFD and ndn-cxx to version 0.6.0
Compilation is currently broken and is fixed in the following commit
Change-Id: Ic0dba06a9afd66a810172d4a512f35f6df6b25a2
Refs: #4306
diff --git a/examples/ndn-cxx-simple/real-app.hpp b/examples/ndn-cxx-simple/real-app.hpp
index 0aa2f38..b7b2a87 100644
--- a/examples/ndn-cxx-simple/real-app.hpp
+++ b/examples/ndn-cxx-simple/real-app.hpp
@@ -45,6 +45,7 @@
m_scheduler.scheduleEvent(ndn::time::seconds(2), [this] {
m_faceConsumer.expressInterest(ndn::Interest("/hello/world"),
std::bind([] { std::cout << "Hello!" << std::endl; }),
+ std::bind([] { std::cout << "NACK!" << std::endl; }),
std::bind([] { std::cout << "Bye!.." << std::endl; }));
});
}
diff --git a/examples/ndn-load-balancer/random-load-balancer-strategy.cpp b/examples/ndn-load-balancer/random-load-balancer-strategy.cpp
index ac4eff4..4f61162 100644
--- a/examples/ndn-load-balancer/random-load-balancer-strategy.cpp
+++ b/examples/ndn-load-balancer/random-load-balancer-strategy.cpp
@@ -36,12 +36,10 @@
namespace nfd {
namespace fw {
-const Name
- RandomLoadBalancerStrategy::STRATEGY_NAME("ndn:/localhost/nfd/strategy/random-load-balancer");
-
RandomLoadBalancerStrategy::RandomLoadBalancerStrategy(Forwarder& forwarder, const Name& name)
- : Strategy(forwarder, name)
+ : Strategy(forwarder)
{
+ this->setInstanceName(makeInstanceName(name, getStrategyName()));
}
RandomLoadBalancerStrategy::~RandomLoadBalancerStrategy()
@@ -97,5 +95,12 @@
this->sendInterest(pitEntry, selected->getFace(), interest);
}
+const Name&
+RandomLoadBalancerStrategy::getStrategyName()
+{
+ static Name strategyName("ndn:/localhost/nfd/strategy/random-load-balancer/%FD%01");
+ return strategyName;
+}
+
} // namespace fw
} // namespace nfd
diff --git a/examples/ndn-load-balancer/random-load-balancer-strategy.hpp b/examples/ndn-load-balancer/random-load-balancer-strategy.hpp
index 997bb56..ef11ae8 100644
--- a/examples/ndn-load-balancer/random-load-balancer-strategy.hpp
+++ b/examples/ndn-load-balancer/random-load-balancer-strategy.hpp
@@ -36,7 +36,7 @@
class RandomLoadBalancerStrategy : public Strategy {
public:
- RandomLoadBalancerStrategy(Forwarder& forwarder, const Name& name = STRATEGY_NAME);
+ RandomLoadBalancerStrategy(Forwarder& forwarder, const Name& name = getStrategyName());
virtual ~RandomLoadBalancerStrategy() override;
@@ -44,8 +44,8 @@
afterReceiveInterest(const Face& inFace, const Interest& interest,
const shared_ptr<pit::Entry>& pitEntry) override;
-public:
- static const Name STRATEGY_NAME;
+ static const Name&
+ getStrategyName();
protected:
boost::random::mt19937 m_randomGenerator;
diff --git a/examples/ndn-simple-for-nrt-helper/requester-app.cpp b/examples/ndn-simple-for-nrt-helper/requester-app.cpp
index 6eee63c..4a5d2ff 100644
--- a/examples/ndn-simple-for-nrt-helper/requester-app.cpp
+++ b/examples/ndn-simple-for-nrt-helper/requester-app.cpp
@@ -90,7 +90,7 @@
auto interest = make_shared<Interest>(m_name);
interest->setInterestLifetime(time::seconds(1));
if (m_delegation.size() > 0) {
- interest->setLink(m_link.wireEncode());
+ interest->setForwardingHint(m_link.getDelegationList());
}
NS_LOG_DEBUG("Sending an Interest for "<< *interest);