[ndnSIM] about interest lifetime

Alex Afanasyev alexander.afanasyev at ucla.edu
Thu Nov 21 19:53:24 PST 2013

Hi Marcia,

First of all, thanks for using ndnSIM :)

On Nov 19, 2013, at 2:19 AM, Marica Amadeo <marica.amadeo at gmail.com> wrote:

> Dear Alex and all,
> I have been working with the ndnSIM simulator for a few months.
> My topic is about wireless scenarios. I'm developing a NDN ad hoc network that uses the LIsten First Broadcast Later Protocol or a simple Controlled Flooding scheme, while consumers employ an extended version of the Consumer Window Application.
> Working in this field, I recently noticed a suspect behavior when I tried to set the Interest Lifetime to a value minor than 1s.
> Consider, for instance, that I want an Interest Lifetime equal to 0.1s.
> So the lifetime of the correspondent PIT entry in every forwarding node should be set to 0.1s.
> However, first, I noticed that the lifetime of every PIT entry was set to the default value.
> Then, by looking at the code, I noticed that the Serialize function in ndnsim.cc assumes: 
> start.WriteU16 (static_cast<uint16_t> (m_interest->GetInterestLifetime ().ToInteger (Time::S)));
> As a consequence, the value 0.1s is approximated to zero (A thing that I really do not want). And, as a further consequence, the PIT entry lifetime is set to the default value, (because it cannot be zero).
> I'm looking for the best solution to support Interest Lifetimes with duration <1s, without complicating the system.

Thanks for catching this issue.  As a quick hack you can replace Time::S to Time:MS (line 134) here and on line 169 replace

  m_interest->SetInterestLifetime (Seconds (i.ReadU16 ()));


  m_interest->SetInterestLifetime (MilliSeconds (i.ReadU16 ()));

These two changes should alter the semantics of what is the lifetime.

Currently, we are working on implementing a new NDN packet format that uses milliseconds as a time unit.  But this will take some time to finalize and then to implement.

Btw.  I'm really curious of your intention to use such a short interest lifetime?


> Thanks in advance.
> Marica.
> -- 
> Eng. Marica Amadeo
> University "Mediterranea" of Reggio Calabria
> DIIES Department, ARTS Lab
> Via Graziella Feo di Vito I - 89100 Reggio Calabria (RC), Italy
> ------------------------------
> Email: marica.amadeo at gmail.com, marica.amadeo at unirc.it
> _______________________________________________
> ndnSIM mailing list
> ndnSIM at lists.cs.ucla.edu
> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20131121/5a186033/attachment.html>

More information about the ndnSIM mailing list