diff --git a/daemon/rib/readvertise/readvertise.cpp b/daemon/rib/readvertise/readvertise.cpp
index 454ab20..49c3400 100644
--- a/daemon/rib/readvertise/readvertise.cpp
+++ b/daemon/rib/readvertise/readvertise.cpp
@@ -44,7 +44,7 @@
   return std::max(newTime, 0_ms);
 }
 
-Readvertise::Readvertise(Rib& rib, ndn::util::Scheduler& scheduler,
+Readvertise::Readvertise(Rib& rib, Scheduler& scheduler,
                          unique_ptr<ReadvertisePolicy> policy,
                          unique_ptr<ReadvertiseDestination> destination)
   : m_scheduler(scheduler)
@@ -162,14 +162,14 @@
     [=] {
       NFD_LOG_DEBUG("advertise " << rrIt->prefix << " success");
       rrIt->retryDelay = RETRY_DELAY_MIN;
-      rrIt->retryEvt = m_scheduler.scheduleEvent(randomizeTimer(m_policy->getRefreshInterval()),
-                                                 [=] { advertise(rrIt); });
+      rrIt->retryEvt = m_scheduler.schedule(randomizeTimer(m_policy->getRefreshInterval()),
+                                            [=] { advertise(rrIt); });
     },
     [=] (const std::string& msg) {
       NFD_LOG_DEBUG("advertise " << rrIt->prefix << " failure " << msg);
       rrIt->retryDelay = std::min(RETRY_DELAY_MAX, rrIt->retryDelay * 2);
-      rrIt->retryEvt = m_scheduler.scheduleEvent(randomizeTimer(rrIt->retryDelay),
-                                                 [=] { advertise(rrIt); });
+      rrIt->retryEvt = m_scheduler.schedule(randomizeTimer(rrIt->retryDelay),
+                                            [=] { advertise(rrIt); });
     });
 }
 
@@ -192,8 +192,8 @@
     [=] (const std::string& msg) {
       NFD_LOG_DEBUG("withdraw " << rrIt->prefix << " failure " << msg);
       rrIt->retryDelay = std::min(RETRY_DELAY_MAX, rrIt->retryDelay * 2);
-      rrIt->retryEvt = m_scheduler.scheduleEvent(randomizeTimer(rrIt->retryDelay),
-                                                 [=] { withdraw(rrIt); });
+      rrIt->retryEvt = m_scheduler.schedule(randomizeTimer(rrIt->retryDelay),
+                                            [=] { withdraw(rrIt); });
     });
 }
 
diff --git a/daemon/rib/readvertise/readvertise.hpp b/daemon/rib/readvertise/readvertise.hpp
index 80dbbc7..a14d438 100644
--- a/daemon/rib/readvertise/readvertise.hpp
+++ b/daemon/rib/readvertise/readvertise.hpp
@@ -45,8 +45,7 @@
 {
 
 public:
-  Readvertise(Rib& rib,
-              ndn::util::Scheduler& scheduler,
+  Readvertise(Rib& rib, Scheduler& scheduler,
               unique_ptr<ReadvertisePolicy> policy,
               unique_ptr<ReadvertiseDestination> destination);
 
@@ -77,7 +76,7 @@
   static const time::milliseconds RETRY_DELAY_MIN;
   static const time::milliseconds RETRY_DELAY_MAX;
 
-  ndn::util::Scheduler& m_scheduler;
+  Scheduler& m_scheduler;
   unique_ptr<ReadvertisePolicy> m_policy;
   unique_ptr<ReadvertiseDestination> m_destination;
 
diff --git a/daemon/rib/readvertise/readvertised-route.hpp b/daemon/rib/readvertise/readvertised-route.hpp
index 7dc02ae..3749336 100644
--- a/daemon/rib/readvertise/readvertised-route.hpp
+++ b/daemon/rib/readvertise/readvertised-route.hpp
@@ -52,7 +52,7 @@
   mutable ndn::security::SigningInfo signer; ///< signer for commands
   mutable size_t nRibRoutes; ///< number of RIB routes that cause the readvertisement
   mutable time::milliseconds retryDelay; ///< retry interval (not used for refresh)
-  mutable ndn::util::scheduler::ScopedEventId retryEvt; ///< retry or refresh event
+  mutable scheduler::ScopedEventId retryEvt; ///< retry or refresh event
 };
 
 inline bool
diff --git a/daemon/rib/route.hpp b/daemon/rib/route.hpp
index f38fbab..92df470 100644
--- a/daemon/rib/route.hpp
+++ b/daemon/rib/route.hpp
@@ -53,14 +53,14 @@
    */
   Route(const ndn::PrefixAnnouncement& ann, uint64_t faceId);
 
-  const ndn::util::scheduler::EventId&
+  const scheduler::EventId&
   getExpirationEvent() const
   {
     return m_expirationEvent;
   }
 
   void
-  setExpirationEvent(const ndn::util::scheduler::EventId& eid)
+  setExpirationEvent(const scheduler::EventId& eid)
   {
     m_expirationEvent = eid;
   }
@@ -101,7 +101,7 @@
   time::steady_clock::TimePoint annExpires;
 
 private:
-  ndn::util::scheduler::EventId m_expirationEvent;
+  scheduler::EventId m_expirationEvent;
 };
 
 bool
diff --git a/daemon/rib/service.cpp b/daemon/rib/service.cpp
index 35c092d..8405c8e 100644
--- a/daemon/rib/service.cpp
+++ b/daemon/rib/service.cpp
@@ -31,8 +31,8 @@
 #include "readvertise/nfd-rib-readvertise-destination.hpp"
 #include "readvertise/readvertise.hpp"
 
-#include "core/global-io.hpp"
 #include "core/logger.hpp"
+#include "daemon/global.hpp"
 
 #include <boost/property_tree/info_parser.hpp>
 #include <ndn-cxx/transport/tcp-transport.hpp>
diff --git a/daemon/rib/service.hpp b/daemon/rib/service.hpp
index fe9b110..1c07d7e 100644
--- a/daemon/rib/service.hpp
+++ b/daemon/rib/service.hpp
@@ -111,7 +111,7 @@
 
   ndn::KeyChain& m_keyChain;
   ndn::Face m_face;
-  ndn::util::Scheduler m_scheduler;
+  Scheduler m_scheduler;
   ndn::nfd::Controller m_nfdController;
 
   Rib m_rib;
