diff --git a/daemon/face/face.hpp b/daemon/face/face.hpp
index 1bb474e..8228885 100644
--- a/daemon/face/face.hpp
+++ b/daemon/face/face.hpp
@@ -75,20 +75,20 @@
   close();
 
 public: // upper interface connected to forwarding
-  /** \brief send Interest to \p endpointId
+  /** \brief send Interest
    */
   void
-  sendInterest(const Interest& interest, const EndpointId& endpointId);
+  sendInterest(const Interest& interest);
 
-  /** \brief send Data to \p endpointId
+  /** \brief send Data
    */
   void
-  sendData(const Data& data, const EndpointId& endpointId);
+  sendData(const Data& data);
 
-  /** \brief send Nack to \p endpointId
+  /** \brief send Nack
    */
   void
-  sendNack(const lp::Nack& nack, const EndpointId& endpointId);
+  sendNack(const lp::Nack& nack);
 
   /** \brief signals on Interest received
    */
@@ -218,21 +218,21 @@
 }
 
 inline void
-Face::sendInterest(const Interest& interest, const EndpointId& endpointId)
+Face::sendInterest(const Interest& interest)
 {
-  m_service->sendInterest(interest, endpointId);
+  m_service->sendInterest(interest);
 }
 
 inline void
-Face::sendData(const Data& data, const EndpointId& endpointId)
+Face::sendData(const Data& data)
 {
-  m_service->sendData(data, endpointId);
+  m_service->sendData(data);
 }
 
 inline void
-Face::sendNack(const lp::Nack& nack, const EndpointId& endpointId)
+Face::sendNack(const lp::Nack& nack)
 {
-  m_service->sendNack(nack, endpointId);
+  m_service->sendNack(nack);
 }
 
 inline FaceId
diff --git a/daemon/face/generic-link-service.cpp b/daemon/face/generic-link-service.cpp
index af03ffd..819a91a 100644
--- a/daemon/face/generic-link-service.cpp
+++ b/daemon/face/generic-link-service.cpp
@@ -82,16 +82,16 @@
 }
 
 void
-GenericLinkService::requestIdlePacket(const EndpointId& endpointId)
+GenericLinkService::requestIdlePacket()
 {
   // No need to request Acks to attach to this packet from LpReliability, as they are already
   // attached in sendLpPacket
   NFD_LOG_FACE_TRACE("IDLE packet requested");
-  this->sendLpPacket({}, endpointId);
+  this->sendLpPacket({});
 }
 
 void
-GenericLinkService::sendLpPacket(lp::Packet&& pkt, const EndpointId& endpointId)
+GenericLinkService::sendLpPacket(lp::Packet&& pkt)
 {
   const ssize_t mtu = getEffectiveMtu();
 
@@ -109,38 +109,38 @@
     NFD_LOG_FACE_WARN("attempted to send packet over MTU limit");
     return;
   }
-  this->sendPacket(block, endpointId);
+  this->sendPacket(block);
 }
 
 void
-GenericLinkService::doSendInterest(const Interest& interest, const EndpointId& endpointId)
+GenericLinkService::doSendInterest(const Interest& interest)
 {
   lp::Packet lpPacket(interest.wireEncode());
 
   encodeLpFields(interest, lpPacket);
 
-  this->sendNetPacket(std::move(lpPacket), endpointId, true);
+  this->sendNetPacket(std::move(lpPacket), true);
 }
 
 void
-GenericLinkService::doSendData(const Data& data, const EndpointId& endpointId)
+GenericLinkService::doSendData(const Data& data)
 {
   lp::Packet lpPacket(data.wireEncode());
 
   encodeLpFields(data, lpPacket);
 
-  this->sendNetPacket(std::move(lpPacket), endpointId, false);
+  this->sendNetPacket(std::move(lpPacket), false);
 }
 
 void
-GenericLinkService::doSendNack(const lp::Nack& nack, const EndpointId& endpointId)
+GenericLinkService::doSendNack(const lp::Nack& nack)
 {
   lp::Packet lpPacket(nack.getInterest().wireEncode());
   lpPacket.add<lp::NackField>(nack.getHeader());
 
   encodeLpFields(nack, lpPacket);
 
-  this->sendNetPacket(std::move(lpPacket), endpointId, false);
+  this->sendNetPacket(std::move(lpPacket), false);
 }
 
 void
@@ -185,7 +185,7 @@
 }
 
 void
-GenericLinkService::sendNetPacket(lp::Packet&& pkt, const EndpointId& endpointId, bool isInterest)
+GenericLinkService::sendNetPacket(lp::Packet&& pkt, bool isInterest)
 {
   std::vector<lp::Packet> frags;
   ssize_t mtu = getEffectiveMtu();
@@ -238,7 +238,7 @@
   }
 
   for (lp::Packet& frag : frags) {
-    this->sendLpPacket(std::move(frag), endpointId);
+    this->sendLpPacket(std::move(frag));
   }
 }
 
diff --git a/daemon/face/generic-link-service.hpp b/daemon/face/generic-link-service.hpp
index 38473f5..7a1dd4f 100644
--- a/daemon/face/generic-link-service.hpp
+++ b/daemon/face/generic-link-service.hpp
@@ -200,27 +200,21 @@
   /** \brief request an IDLE packet to transmit pending service fields
    */
   void
-  requestIdlePacket(const EndpointId& endpointId);
+  requestIdlePacket();
 
-  /** \brief send an LpPacket to \p endpointId
+  /** \brief send an LpPacket
    */
   void
-  sendLpPacket(lp::Packet&& pkt, const EndpointId& endpointId);
+  sendLpPacket(lp::Packet&& pkt);
 
-  /** \brief send Interest
-   */
   void
-  doSendInterest(const Interest& interest, const EndpointId& endpointId) OVERRIDE_WITH_TESTS_ELSE_FINAL;
+  doSendInterest(const Interest& interest) OVERRIDE_WITH_TESTS_ELSE_FINAL;
 
-  /** \brief send Data
-   */
   void
-  doSendData(const Data& data, const EndpointId& endpointId) OVERRIDE_WITH_TESTS_ELSE_FINAL;
+  doSendData(const Data& data) OVERRIDE_WITH_TESTS_ELSE_FINAL;
 
-  /** \brief send Nack
-   */
   void
-  doSendNack(const ndn::lp::Nack& nack, const EndpointId& endpointId) OVERRIDE_WITH_TESTS_ELSE_FINAL;
+  doSendNack(const ndn::lp::Nack& nack) OVERRIDE_WITH_TESTS_ELSE_FINAL;
 
   /** \brief assign consecutive sequence numbers to LpPackets
    */
@@ -237,11 +231,10 @@
 
   /** \brief send a complete network layer packet
    *  \param pkt LpPacket containing a complete network layer packet
-   *  \param endpointId destination endpoint to which LpPacket will be sent
    *  \param isInterest whether the network layer packet is an Interest
    */
   void
-  sendNetPacket(lp::Packet&& pkt, const EndpointId& endpointId, bool isInterest);
+  sendNetPacket(lp::Packet&& pkt, bool isInterest);
 
   /** \brief if the send queue is found to be congested, add a congestion mark to the packet
    *         according to CoDel
@@ -251,8 +244,6 @@
   checkCongestionLevel(lp::Packet& pkt);
 
 private: // receive path
-  /** \brief receive Packet from Transport
-   */
   void
   doReceivePacket(const Block& packet, const EndpointId& endpoint) OVERRIDE_WITH_TESTS_ELSE_FINAL;
 
diff --git a/daemon/face/link-service.cpp b/daemon/face/link-service.cpp
index df0fe9c..6527dbd 100644
--- a/daemon/face/link-service.cpp
+++ b/daemon/face/link-service.cpp
@@ -52,36 +52,36 @@
 }
 
 void
-LinkService::sendInterest(const Interest& interest, const EndpointId& endpoint)
+LinkService::sendInterest(const Interest& interest)
 {
   BOOST_ASSERT(m_transport != nullptr);
   NFD_LOG_FACE_TRACE(__func__);
 
   ++this->nOutInterests;
 
-  doSendInterest(interest, endpoint);
+  doSendInterest(interest);
 }
 
 void
-LinkService::sendData(const Data& data, const EndpointId& endpoint)
+LinkService::sendData(const Data& data)
 {
   BOOST_ASSERT(m_transport != nullptr);
   NFD_LOG_FACE_TRACE(__func__);
 
   ++this->nOutData;
 
-  doSendData(data, endpoint);
+  doSendData(data);
 }
 
 void
-LinkService::sendNack(const ndn::lp::Nack& nack, const EndpointId& endpoint)
+LinkService::sendNack(const ndn::lp::Nack& nack)
 {
   BOOST_ASSERT(m_transport != nullptr);
   NFD_LOG_FACE_TRACE(__func__);
 
   ++this->nOutNacks;
 
-  doSendNack(nack, endpoint);
+  doSendNack(nack);
 }
 
 void
diff --git a/daemon/face/link-service.hpp b/daemon/face/link-service.hpp
index c239cf2..c623622 100644
--- a/daemon/face/link-service.hpp
+++ b/daemon/face/link-service.hpp
@@ -113,23 +113,23 @@
   getEffectiveMtu() const;
 
 public: // upper interface to be used by forwarding
-  /** \brief Send Interest to \p endpoint
+  /** \brief Send Interest
    *  \pre setTransport has been called
    */
   void
-  sendInterest(const Interest& interest, const EndpointId& endpoint);
+  sendInterest(const Interest& interest);
 
-  /** \brief Send Data to \p endpoint
+  /** \brief Send Data
    *  \pre setTransport has been called
    */
   void
-  sendData(const Data& data, const EndpointId& endpoint);
+  sendData(const Data& data);
 
-  /** \brief Send Nack to \p endpoint
+  /** \brief Send Nack
    *  \pre setTransport has been called
    */
   void
-  sendNack(const ndn::lp::Nack& nack, const EndpointId& endpoint);
+  sendNack(const ndn::lp::Nack& nack);
 
   /** \brief signals on Interest received
    */
@@ -170,30 +170,30 @@
   receiveNack(const lp::Nack& nack, const EndpointId& endpoint);
 
 protected: // lower interface to be invoked in subclass (send path termination)
-  /** \brief send a lower-layer packet via Transport to \p endpoint
+  /** \brief send a lower-layer packet via Transport
    */
   void
-  sendPacket(const Block& packet, const EndpointId& endpoint);
+  sendPacket(const Block& packet);
 
 protected:
   void
   notifyDroppedInterest(const Interest& packet);
 
 private: // upper interface to be overridden in subclass (send path entrypoint)
-  /** \brief performs LinkService specific operations to send an Interest to \p endpoint
+  /** \brief performs LinkService specific operations to send an Interest
    */
   virtual void
-  doSendInterest(const Interest& interest, const EndpointId& endpoint) = 0;
+  doSendInterest(const Interest& interest) = 0;
 
-  /** \brief performs LinkService specific operations to send a Data to \p endpoint
+  /** \brief performs LinkService specific operations to send a Data
    */
   virtual void
-  doSendData(const Data& data, const EndpointId& endpoint) = 0;
+  doSendData(const Data& data) = 0;
 
-  /** \brief performs LinkService specific operations to send a Nack to \p endpoint
+  /** \brief performs LinkService specific operations to send a Nack
    */
   virtual void
-  doSendNack(const lp::Nack& nack, const EndpointId& endpoint) = 0;
+  doSendNack(const lp::Nack& nack) = 0;
 
 private: // lower interface to be overridden in subclass
   virtual void
@@ -241,9 +241,9 @@
 }
 
 inline void
-LinkService::sendPacket(const Block& packet, const EndpointId& endpoint)
+LinkService::sendPacket(const Block& packet)
 {
-  m_transport->send(packet, endpoint);
+  m_transport->send(packet);
 }
 
 std::ostream&
diff --git a/daemon/face/lp-reliability.cpp b/daemon/face/lp-reliability.cpp
index 21189be..f387add 100644
--- a/daemon/face/lp-reliability.cpp
+++ b/daemon/face/lp-reliability.cpp
@@ -242,7 +242,7 @@
 
   m_idleAckTimer = getScheduler().schedule(m_options.idleAckTimerPeriod, [this] {
     while (!m_ackQueue.empty()) {
-      m_linkService->requestIdlePacket(0);
+      m_linkService->requestIdlePacket();
     }
   });
 }
@@ -346,7 +346,7 @@
     deleteUnackedFrag(txSeqIt);
 
     // Retransmit fragment
-    m_linkService->sendLpPacket(lp::Packet(newTxFrag.pkt), 0);
+    m_linkService->sendLpPacket(lp::Packet(newTxFrag.pkt));
 
     auto rto = m_rttEst.getEstimatedRto();
     NFD_LOG_FACE_TRACE("retransmitting seq=" << seq << ", txseq=" << newTxSeq << ", retx=" <<
diff --git a/daemon/face/null-link-service.hpp b/daemon/face/null-link-service.hpp
index 3823d9a..2ae26ab 100644
--- a/daemon/face/null-link-service.hpp
+++ b/daemon/face/null-link-service.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2019,  Regents of the University of California,
+ * Copyright (c) 2014-2020,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -37,17 +37,17 @@
 {
 private:
   void
-  doSendInterest(const Interest&, const EndpointId&) final
+  doSendInterest(const Interest&) final
   {
   }
 
   void
-  doSendData(const Data&, const EndpointId&) final
+  doSendData(const Data&) final
   {
   }
 
   void
-  doSendNack(const lp::Nack&, const EndpointId&) final
+  doSendNack(const lp::Nack&) final
   {
   }
 
diff --git a/daemon/fw/forwarder.cpp b/daemon/fw/forwarder.cpp
index adfa3e1..1bc0acc 100644
--- a/daemon/fw/forwarder.cpp
+++ b/daemon/fw/forwarder.cpp
@@ -175,7 +175,7 @@
   // note: Don't enter outgoing Nack pipeline because it needs an in-record.
   lp::Nack nack(interest);
   nack.setReason(lp::NackReason::DUPLICATE);
-  ingress.face.sendNack(nack, ingress.endpoint);
+  ingress.face.sendNack(nack);
 }
 
 void
@@ -258,7 +258,7 @@
   pitEntry->insertOrUpdateOutRecord(egress.face, interest);
 
   // send Interest
-  egress.face.sendInterest(interest, egress.endpoint);
+  egress.face.sendInterest(interest);
   ++m_counters.nOutInterests;
 }
 
@@ -417,7 +417,7 @@
   // TODO traffic manager
 
   // send Data
-  egress.face.sendData(data, egress.endpoint);
+  egress.face.sendData(data);
   ++m_counters.nOutData;
 }
 
@@ -519,7 +519,7 @@
   pitEntry->deleteInRecord(egress.face);
 
   // send Nack on face
-  egress.face.sendNack(nackPkt, egress.endpoint);
+  egress.face.sendNack(nackPkt);
   ++m_counters.nOutNacks;
 }
 
diff --git a/tests/daemon/face/dummy-link-service.cpp b/tests/daemon/face/dummy-link-service.cpp
index ce006cb..820d05b 100644
--- a/tests/daemon/face/dummy-link-service.cpp
+++ b/tests/daemon/face/dummy-link-service.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2019,  Regents of the University of California,
+ * Copyright (c) 2014-2020,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -30,7 +30,7 @@
 namespace tests {
 
 void
-DummyLinkService::doSendInterest(const Interest& interest, const EndpointId&)
+DummyLinkService::doSendInterest(const Interest& interest)
 {
   if (m_loggingFlags & LogSentInterests)
     sentInterests.push_back(interest);
@@ -39,7 +39,7 @@
 }
 
 void
-DummyLinkService::doSendData(const Data& data, const EndpointId&)
+DummyLinkService::doSendData(const Data& data)
 {
   if (m_loggingFlags & LogSentData)
     sentData.push_back(data);
@@ -48,7 +48,7 @@
 }
 
 void
-DummyLinkService::doSendNack(const lp::Nack& nack, const EndpointId&)
+DummyLinkService::doSendNack(const lp::Nack& nack)
 {
   if (m_loggingFlags & LogSentNacks)
     sentNacks.push_back(nack);
diff --git a/tests/daemon/face/dummy-link-service.hpp b/tests/daemon/face/dummy-link-service.hpp
index 44ed991..3d77968 100644
--- a/tests/daemon/face/dummy-link-service.hpp
+++ b/tests/daemon/face/dummy-link-service.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2019,  Regents of the University of California,
+ * Copyright (c) 2014-2020,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -73,13 +73,13 @@
 
 private:
   void
-  doSendInterest(const Interest& interest, const EndpointId& endpoint) final;
+  doSendInterest(const Interest& interest) final;
 
   void
-  doSendData(const Data& data, const EndpointId& endpoint) final;
+  doSendData(const Data& data) final;
 
   void
-  doSendNack(const lp::Nack& nack, const EndpointId& endpoint) final;
+  doSendNack(const lp::Nack& nack) final;
 
   void
   doReceivePacket(const Block& packet, const EndpointId& endpoint) final;
diff --git a/tests/daemon/face/face.t.cpp b/tests/daemon/face/face.t.cpp
index 346f609..b592a24 100644
--- a/tests/daemon/face/face.t.cpp
+++ b/tests/daemon/face/face.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2019,  Regents of the University of California,
+ * Copyright (c) 2014-2020,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -119,16 +119,16 @@
   }
 
   for (size_t i = 0; i < nOutInterests; ++i) {
-    face1->sendInterest(*makeInterest("/XyUAFYQDmd"), 0);
+    face1->sendInterest(*makeInterest("/XyUAFYQDmd"));
   }
 
   for (size_t i = 0; i < nOutData; ++i) {
-    face1->sendData(*makeData("/GigPEtPH6"), 0);
+    face1->sendData(*makeData("/GigPEtPH6"));
   }
 
   for (size_t i = 0; i < nOutNacks; ++i) {
     face1->sendNack(makeNack(*makeInterest("/9xK6FbwIBM", false, nullopt, 365),
-                             lp::NackReason::CONGESTION), 0);
+                             lp::NackReason::CONGESTION));
   }
 
   BOOST_CHECK_EQUAL(face1->getCounters().nInInterests, nInInterests);
diff --git a/tests/daemon/face/generic-link-service.t.cpp b/tests/daemon/face/generic-link-service.t.cpp
index 130c85e..b78ada6 100644
--- a/tests/daemon/face/generic-link-service.t.cpp
+++ b/tests/daemon/face/generic-link-service.t.cpp
@@ -106,7 +106,7 @@
   initialize(options);
 
   auto interest1 = makeInterest("/localhost/test");
-  face->sendInterest(*interest1, 0);
+  face->sendInterest(*interest1);
 
   BOOST_CHECK_EQUAL(service->getCounters().nOutInterests, 1);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
@@ -123,7 +123,7 @@
   initialize(options);
 
   auto data1 = makeData("/localhost/test");
-  face->sendData(*data1, 0);
+  face->sendData(*data1);
 
   BOOST_CHECK_EQUAL(service->getCounters().nOutData, 1);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
@@ -167,7 +167,7 @@
   // Send Data with less than MIN_MTU octets
   auto data1 = makeData("/localhost");
   BOOST_CHECK_LE(data1->wireEncode().size(), MIN_MTU);
-  face->sendData(*data1, 0);
+  face->sendData(*data1);
 
   BOOST_CHECK_EQUAL(service->getCounters().nOutData, 1);
   BOOST_CHECK_EQUAL(service->getCounters().nOutOverMtu, 0);
@@ -175,7 +175,7 @@
   // Send Data with more than MIN_MTU octets
   auto data2 = makeData("/localhost/test/1234567890/1234567890/1234567890/1234567890");
   BOOST_CHECK_GT(data2->wireEncode().size(), MIN_MTU);
-  face->sendData(*data2, 0);
+  face->sendData(*data2);
 
   BOOST_CHECK_EQUAL(service->getCounters().nOutData, 2);
   BOOST_CHECK_EQUAL(service->getCounters().nOutOverMtu, 1);
@@ -196,7 +196,7 @@
 
   auto nack1 = makeNack(*makeInterest("/localhost/test", false, nullopt, 323),
                         lp::NackReason::NO_ROUTE);
-  face->sendNack(nack1, 0);
+  face->sendNack(nack1);
 
   BOOST_CHECK_EQUAL(service->getCounters().nOutNacks, 1);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
@@ -331,7 +331,7 @@
   transport->setMtu(55);
 
   auto data = makeData("/test/data/123456789/987654321/123456789");
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_CHECK_EQUAL(transport->sentPackets.size(), 0);
   BOOST_CHECK_EQUAL(service->getCounters().nOutOverMtu, 1);
@@ -349,7 +349,7 @@
   transport->setMtu(0);
 
   auto data = makeData("/test/data/123456789/987654321/123456789");
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_CHECK_EQUAL(transport->sentPackets.size(), 0);
   BOOST_CHECK_EQUAL(service->getCounters().nOutOverMtu, 1);
@@ -365,7 +365,7 @@
   transport->setMtu(MTU_UNLIMITED);
 
   auto data = makeData("/test/data/123456789/987654321/123456789");
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_CHECK_EQUAL(transport->sentPackets.size(), 1);
 }
@@ -380,7 +380,7 @@
   transport->setMtu(105);
 
   auto data = makeData("/test/data/123456789/987654321/123456789");
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_CHECK_EQUAL(transport->sentPackets.size(), 1);
 }
@@ -395,7 +395,7 @@
   transport->setMtu(60);
 
   auto data = makeData("/test/data/123456789/987654321/123456789");
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_CHECK_GT(transport->sentPackets.size(), 1);
 }
@@ -412,7 +412,7 @@
   transport->setMtu(0);
 
   auto data = makeData("/test/data/123456789/987654321/123456789");
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_CHECK_EQUAL(transport->sentPackets.size(), 0);
   BOOST_CHECK_EQUAL(service->getCounters().nFragmentationErrors, 1);
@@ -504,7 +504,7 @@
   initialize(options);
 
   auto interest1 = makeInterest("/localhost/test");
-  face->sendInterest(*interest1, 0);
+  face->sendInterest(*interest1);
 
   BOOST_CHECK_EQUAL(service->getCounters().nOutInterests, 1);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
@@ -522,7 +522,7 @@
   initialize(options);
 
   auto data1 = makeData("/localhost/test");
-  face->sendData(*data1, 0);
+  face->sendData(*data1);
 
   BOOST_CHECK_EQUAL(service->getCounters().nOutData, 1);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
@@ -541,7 +541,7 @@
 
   auto nack1 = makeNack(*makeInterest("/localhost/test", false, nullopt, 323),
                         lp::NackReason::NO_ROUTE);
-  face->sendNack(nack1, 0);
+  face->sendNack(nack1);
 
   BOOST_CHECK_EQUAL(service->getCounters().nOutNacks, 1);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
@@ -599,7 +599,7 @@
 
   // no congestion
   transport->setSendQueueLength(0);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet pkt1(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt1.count<lp::CongestionMarkField>(), 0);
@@ -609,7 +609,7 @@
 
   // no congestion
   transport->setSendQueueLength(32768);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 2);
   lp::Packet pkt2(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt2.count<lp::CongestionMarkField>(), 0);
@@ -632,7 +632,7 @@
 
   // first congested packet, will not be marked
   transport->setSendQueueLength(65537);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet pkt0(transport->sentPackets.back().packet);
   BOOST_REQUIRE_EQUAL(pkt0.count<lp::CongestionMarkField>(), 0);
@@ -644,7 +644,7 @@
                                             std::sqrt(service->m_nMarkedSinceInMarkingState + 1)));
 
   advanceClocks(markingInterval + 1_ms);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   lp::Packet pkt1(transport->sentPackets.back().packet);
 
   // First congestion mark appears after one interval (100 ms)
@@ -658,7 +658,7 @@
 
   // second congested packet, but within marking interval, will not be marked
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 3);
   lp::Packet pkt2(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt2.count<lp::CongestionMarkField>(), 0);
@@ -677,7 +677,7 @@
 
   // first congested packet after waiting marking interval, will be marked
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 4);
   lp::Packet pkt3(transport->sentPackets.back().packet);
   BOOST_REQUIRE_EQUAL(pkt3.count<lp::CongestionMarkField>(), 1);
@@ -695,7 +695,7 @@
 
   // still congested, but within marking interval cycle
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 5);
   lp::Packet pkt4(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt4.count<lp::CongestionMarkField>(), 0);
@@ -708,7 +708,7 @@
 
   // still congested, after marking interval cycle
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 6);
   lp::Packet pkt5(transport->sentPackets.back().packet);
   BOOST_REQUIRE_EQUAL(pkt5.count<lp::CongestionMarkField>(), 1);
@@ -725,7 +725,7 @@
 
   // still congested, but within marking interval cycle
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 7);
   lp::Packet pkt6(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt6.count<lp::CongestionMarkField>(), 0);
@@ -737,7 +737,7 @@
 
   // still congested, after marking interval cycle
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 8);
   lp::Packet pkt7(transport->sentPackets.back().packet);
   BOOST_REQUIRE_EQUAL(pkt7.count<lp::CongestionMarkField>(), 1);
@@ -752,7 +752,7 @@
 
   // no more congestion
   transport->setSendQueueLength(30000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 9);
   lp::Packet pkt8(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt8.count<lp::CongestionMarkField>(), 0);
@@ -764,7 +764,7 @@
 
   // send queue congested again, but can't mark packet because within one full interval of last mark
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 10);
   lp::Packet pkt9(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt9.count<lp::CongestionMarkField>(), 0);
@@ -782,7 +782,7 @@
   BOOST_CHECK_GT(time::steady_clock::now(), nextMarkTime);
 
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 11);
   lp::Packet pkt10(transport->sentPackets.back().packet);
   BOOST_REQUIRE_EQUAL(pkt10.count<lp::CongestionMarkField>(), 1);
@@ -800,7 +800,7 @@
 
   // not marked since within 100ms window before can mark again
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 12);
   lp::Packet pkt11(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt11.count<lp::CongestionMarkField>(), 0);
@@ -813,7 +813,7 @@
 
   // markable packet, queue length still above threshold
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 13);
   lp::Packet pkt12(transport->sentPackets.back().packet);
   BOOST_REQUIRE_EQUAL(pkt12.count<lp::CongestionMarkField>(), 1);
@@ -828,7 +828,7 @@
 
   // no more congestion
   transport->setSendQueueLength(10000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 14);
   lp::Packet pkt13(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt13.count<lp::CongestionMarkField>(), 0);
@@ -841,7 +841,7 @@
 
   // start congestion again
   transport->setSendQueueLength(66000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 15);
   lp::Packet pkt14(transport->sentPackets.back().packet);
   BOOST_REQUIRE_EQUAL(pkt14.count<lp::CongestionMarkField>(), 0);
@@ -852,7 +852,7 @@
 
   // no more congestion, cancel marking interval
   transport->setSendQueueLength(5000);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 16);
   lp::Packet pkt15(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt15.count<lp::CongestionMarkField>(), 0);
@@ -878,7 +878,7 @@
 
   // no congestion
   transport->setSendQueueLength(0);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet pkt1(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt1.count<lp::CongestionMarkField>(), 0);
@@ -888,7 +888,7 @@
 
   // no congestion
   transport->setSendQueueLength(65536);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 2);
   lp::Packet pkt2(transport->sentPackets.back().packet);
   BOOST_CHECK_EQUAL(pkt2.count<lp::CongestionMarkField>(), 0);
@@ -898,7 +898,7 @@
 
   // first congested (not marked yet) packet
   transport->setSendQueueLength(65537);
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 3);
   lp::Packet pkt3(transport->sentPackets.back().packet);
   BOOST_REQUIRE_EQUAL(pkt3.count<lp::CongestionMarkField>(), 0);
@@ -1056,7 +1056,7 @@
   auto interest = makeInterest("/12345678");
   interest->setTag(make_shared<lp::IncomingFaceIdTag>(1000));
 
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
@@ -1074,7 +1074,7 @@
   auto interest = makeInterest("/12345678");
   interest->setTag(make_shared<lp::IncomingFaceIdTag>(1000));
 
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
@@ -1142,7 +1142,7 @@
   auto interest = makeInterest("/12345678");
   interest->setTag(make_shared<lp::CongestionMarkTag>(1));
 
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
@@ -1155,7 +1155,7 @@
   auto data = makeData("/12345678");
   data->setTag(make_shared<lp::CongestionMarkTag>(0));
 
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
@@ -1169,7 +1169,7 @@
                            lp::NackReason::NO_ROUTE);
   nack.setTag(make_shared<lp::CongestionMarkTag>(std::numeric_limits<uint64_t>::max()));
 
-  face->sendNack(nack, 0);
+  face->sendNack(nack);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
@@ -1232,7 +1232,7 @@
   auto interest = makeInterest("/12345678");
   interest->setTag(make_shared<lp::NonDiscoveryTag>(lp::EmptyValue{}));
 
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
@@ -1248,7 +1248,7 @@
   auto interest = makeInterest("/12345678");
   interest->setTag(make_shared<lp::NonDiscoveryTag>(lp::EmptyValue{}));
 
-  face->sendInterest(*interest, 0);
+  face->sendInterest(*interest);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
@@ -1336,7 +1336,7 @@
   auto pah = makePrefixAnnHeader("/local/ndn/prefix");
   data->setTag(make_shared<lp::PrefixAnnouncementTag>(pah));
 
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
@@ -1353,7 +1353,7 @@
   auto pah = makePrefixAnnHeader("/local/ndn/prefix");
   data->setTag(make_shared<lp::PrefixAnnouncementTag>(pah));
 
-  face->sendData(*data, 0);
+  face->sendData(*data);
 
   BOOST_REQUIRE_EQUAL(transport->sentPackets.size(), 1);
   lp::Packet sent(transport->sentPackets.back().packet);
diff --git a/tests/daemon/face/internal-face.t.cpp b/tests/daemon/face/internal-face.t.cpp
index bab5ea5..db72bcc 100644
--- a/tests/daemon/face/internal-face.t.cpp
+++ b/tests/daemon/face/internal-face.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2019,  Regents of the University of California,
+ * Copyright (c) 2014-2020,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -117,7 +117,7 @@
   BOOST_REQUIRE_EQUAL(receivedInterests.size(), 1);
   BOOST_CHECK_EQUAL(receivedInterests.back().getName(), "/PQstEJGdL");
 
-  forwarderFace->sendData(*makeData("/PQstEJGdL/aI7oCrDXNX"), 0);
+  forwarderFace->sendData(*makeData("/PQstEJGdL/aI7oCrDXNX"));
   this->advanceClocks(1_ms, 10);
 
   BOOST_CHECK(hasReceivedData);
@@ -140,7 +140,7 @@
   BOOST_REQUIRE_EQUAL(receivedInterests.size(), 1);
   BOOST_CHECK_EQUAL(receivedInterests.back().getName(), "/1HrsRM1X");
 
-  forwarderFace->sendNack(makeNack(*interest, lp::NackReason::NO_ROUTE), 0);
+  forwarderFace->sendNack(makeNack(*interest, lp::NackReason::NO_ROUTE));
   this->advanceClocks(1_ms, 10);
 
   BOOST_CHECK(hasReceivedNack);
@@ -157,7 +157,7 @@
       clientFace->put(*makeData("/Wpc8TnEeoF/f6SzV8hD/3uytUJCuIi"));
     });
 
-  forwarderFace->sendInterest(*makeInterest("/Wpc8TnEeoF/f6SzV8hD", true), 0);
+  forwarderFace->sendInterest(*makeInterest("/Wpc8TnEeoF/f6SzV8hD", true));
   this->advanceClocks(1_ms, 10);
 
   BOOST_CHECK(hasDeliveredInterest);
@@ -177,7 +177,7 @@
       clientFace->put(makeNack(interest, lp::NackReason::NO_ROUTE));
     });
 
-  forwarderFace->sendInterest(*interest, 0);
+  forwarderFace->sendInterest(*interest);
   this->advanceClocks(1_ms, 10);
 
   BOOST_CHECK(hasDeliveredInterest);
@@ -211,7 +211,7 @@
   g_io.poll(); // #3248 workaround
   clientFace.reset();
 
-  forwarderFace->sendInterest(*makeInterest("/aau42XQqb"), 0);
+  forwarderFace->sendInterest(*makeInterest("/aau42XQqb"));
   BOOST_CHECK_NO_THROW(this->advanceClocks(1_ms, 10));
 }
 
diff --git a/tests/daemon/face/lp-reliability.t.cpp b/tests/daemon/face/lp-reliability.t.cpp
index 525ab97..b45ae98 100644
--- a/tests/daemon/face/lp-reliability.t.cpp
+++ b/tests/daemon/face/lp-reliability.t.cpp
@@ -62,25 +62,25 @@
     }
 
     for (auto frag : frags) {
-      this->sendLpPacket(std::move(frag), 0);
+      this->sendLpPacket(std::move(frag));
     }
   }
 
 private:
   void
-  doSendInterest(const Interest&, const EndpointId&) final
+  doSendInterest(const Interest&) final
   {
     BOOST_FAIL("unexpected doSendInterest");
   }
 
   void
-  doSendData(const Data&, const EndpointId&) final
+  doSendData(const Data&) final
   {
     BOOST_FAIL("unexpected doSendData");
   }
 
   void
-  doSendNack(const lp::Nack&, const EndpointId&) final
+  doSendNack(const lp::Nack&) final
   {
     BOOST_FAIL("unexpected doSendNack");
   }
diff --git a/tests/daemon/face/null-face.t.cpp b/tests/daemon/face/null-face.t.cpp
index de343e0..4a5f539 100644
--- a/tests/daemon/face/null-face.t.cpp
+++ b/tests/daemon/face/null-face.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2019,  Regents of the University of California,
+ * Copyright (c) 2014-2020,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -74,10 +74,10 @@
   auto face = makeNullFace();
   BOOST_CHECK_EQUAL(face->getState(), FaceState::UP);
 
-  face->sendInterest(*makeInterest("/A"), 0);
+  face->sendInterest(*makeInterest("/A"));
   BOOST_CHECK_EQUAL(face->getState(), FaceState::UP);
 
-  face->sendData(*makeData("/B"), 0);
+  face->sendData(*makeData("/B"));
   BOOST_CHECK_EQUAL(face->getState(), FaceState::UP);
 }
 
diff --git a/tests/daemon/fw/topology-tester.cpp b/tests/daemon/fw/topology-tester.cpp
index 92495d4..73f9999 100644
--- a/tests/daemon/fw/topology-tester.cpp
+++ b/tests/daemon/fw/topology-tester.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2019,  Regents of the University of California,
+ * Copyright (c) 2014-2020,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -169,27 +169,27 @@
   ///\todo #3941 call GenericLinkServiceCounters constructor in TopologyPcapLinkService constructor
 
   void
-  doSendInterest(const Interest& interest, const EndpointId& endpointId) override
+  doSendInterest(const Interest& interest) override
   {
     this->sentInterests.push_back(interest);
     this->sentInterests.back().setTag(std::make_shared<TopologyPcapTimestamp>(time::steady_clock::now()));
-    this->GenericLinkService::doSendInterest(interest, endpointId);
+    this->GenericLinkService::doSendInterest(interest);
   }
 
   void
-  doSendData(const Data& data, const EndpointId& endpointId) override
+  doSendData(const Data& data) override
   {
     this->sentData.push_back(data);
     this->sentData.back().setTag(std::make_shared<TopologyPcapTimestamp>(time::steady_clock::now()));
-    this->GenericLinkService::doSendData(data, endpointId);
+    this->GenericLinkService::doSendData(data);
   }
 
   void
-  doSendNack(const lp::Nack& nack, const EndpointId& endpointId) override
+  doSendNack(const lp::Nack& nack) override
   {
     this->sentNacks.push_back(nack);
     this->sentNacks.back().setTag(std::make_shared<TopologyPcapTimestamp>(time::steady_clock::now()));
-    this->GenericLinkService::doSendNack(nack, endpointId);
+    this->GenericLinkService::doSendNack(nack);
   }
 };
 
diff --git a/tests/daemon/mgmt/face-manager-update-face.t.cpp b/tests/daemon/mgmt/face-manager-update-face.t.cpp
index c2f0131..b380419 100644
--- a/tests/daemon/mgmt/face-manager-update-face.t.cpp
+++ b/tests/daemon/mgmt/face-manager-update-face.t.cpp
@@ -110,7 +110,7 @@
         if (isForOnDemandFace) {
           auto face = target.faceTable.get(static_cast<FaceId>(this->faceId));
           // to force creation of on-demand face
-          face->sendInterest(*make_shared<Interest>("/hello/world"), 0);
+          face->sendInterest(*make_shared<Interest>("/hello/world"));
         }
       });
 
diff --git a/tests/other/face-benchmark.cpp b/tests/other/face-benchmark.cpp
index 5c7703f..3bf5a14 100644
--- a/tests/other/face-benchmark.cpp
+++ b/tests/other/face-benchmark.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2019,  Regents of the University of California,
+ * Copyright (c) 2014-2020,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -149,13 +149,13 @@
   tieFaces(const shared_ptr<Face>& face1, const shared_ptr<Face>& face2)
   {
     face1->afterReceiveInterest.connect([face2] (const Interest& interest, const EndpointId&) {
-      face2->sendInterest(interest, 0);
+      face2->sendInterest(interest);
     });
     face1->afterReceiveData.connect([face2] (const Data& data, const EndpointId&) {
-      face2->sendData(data, 0);
+      face2->sendData(data);
     });
     face1->afterReceiveNack.connect([face2] (const ndn::lp::Nack& nack, const EndpointId&) {
-      face2->sendNack(nack, 0);
+      face2->sendNack(nack);
     });
   }
 
