examples: Do not use /localhost prefix in examples
This change is to avoid a common problem of running examples on separate
machines. The use of /localhost prefix, due to name-based scoping,
restricts the example programs to run on a single machine.
Change-Id: Id9f753fb7d097411b77b6227c6518679849d4411
diff --git a/examples/consumer-with-timer.cpp b/examples/consumer-with-timer.cpp
index 713e203..7897b41 100644
--- a/examples/consumer-with-timer.cpp
+++ b/examples/consumer-with-timer.cpp
@@ -52,7 +52,7 @@
{
std::cout << "One more Interest, delayed by the scheduler" << std::endl;
- Interest i(Name("/localhost/testApp/randomData"));
+ Interest i(Name("/example/testApp/randomData"));
i.setScope(1);
i.setInterestLifetime(time::milliseconds(1000));
i.setMustBeFresh(true);
@@ -69,7 +69,7 @@
// Explicitly create io_service object, which can be shared between Face and Scheduler
boost::asio::io_service ioService;
- Interest i(Name("/localhost/testApp/randomData"));
+ Interest i(Name("/example/testApp/randomData"));
i.setScope(1);
i.setInterestLifetime(time::seconds(1));
i.setMustBeFresh(true);