[ndnSIM] boost includes

Alex Afanasyev alexander.afanasyev at ucla.edu
Sun Jul 14 16:18:28 PDT 2013

Hi again,

These are actually the errors that I was hinting to.  Even though you could "compile" without errors, there you couldn't link.

In any case, I have suspicion that counting can be easily done in a class that simply derives from Queue and then implements custom queuing.  

At the same time, if you just want to count enqueue/dequeue/drop, then you can easily implement this without even touching Queue implementation, using TraceSources, in similar manner L2RateTracer is implemented (ulits/tracers/l2-tracer.h|cc, utils/tracers/l2-rate-tracer.h|cc).  So, you basically need to create a class that will do counting and "attach" to Enqueue, Dequeue, and Drop traces (http://www.nsnam.org/doxygen-release/classns3_1_1_queue.html#details).   And this implementation should be either inside ndnSIM module, in a separate module that depends on ndnSIM module, or in an separate project that depends on NS-3 and ndnSIM module (like in these example: https://github.com/cawka/ndnSIM-ddos-interest-flooding).


On Jul 13, 2013, at 5:05 PM, Natalya Rozhnova <natalya.rozhnova at lip6.fr> wrote:

> Oh, I don't have my own derivative queue. My implementation has completely changed since we talked about.
> I actually need to count the number of data packets in the queue per flow. Where flow is defined by prefix name. So, the first idea was to create a std::map <ndn::Name, uint32_t> and dynamically keep the queue lengths per prefix name and then access to the map whenever I need it. (I need to access it in Forwarding Strategy)
> But I got an error: Undefined symbols for architecture x86_64 ...etc...
> btw, it's still an open question... Do you have any idea how to implement this ?
> Natalya
> 14.07.2013, 06:47, "Alex Afanasyev" <alexander.afanasyev at ucla.edu>:
>> Btw. I'm not sure that adding ndn-name.h to queue.h is the right way to go.  It basically introduces some circular module dependencies (ndnSIM depends on network and now network module depends on ndnSIM...).  Just wonder why adding this include to a derivative queue (type that you're working on) is not enough?
>> The reason you're getting the error is that network module is not configured with boost libraries support.  Even though you got rid of the error right now, you may have bigger problems later (at the linking stage).   If you really want to keep the include, I would add boost dependencies into network module as well (similar how it is done in src/ndnSIM/wscript).
>> ---
>> Alex
>> On Jul 13, 2013, at 3:36 PM, Natalya Rozhnova <natalya.rozhnova at lip6.fr> wrote:
>>> Hi Alex,
>>> My boost library has been installed to "/opt/local/include/boost" by default. I just created a symbolic link between /usr/include and /opt/local/include/boost. May be this is not a very good solution but it avoids to reinstall boost...
>>> Natalya
>>> 14.07.2013, 05:27, "Alex Afanasyev" <alexander.afanasyev at ucla.edu>:
>>>> Hi Natalya,
>>>> Just curious, what did you do to solve the problem?
>>>> ---
>>>> Alex
>>>> On Jul 13, 2013, at 6:00 AM, Natalya Rozhnova <natalya.rozhnova at lip6.fr> wrote:
>>>>> Hi again,
>>>>> Problem is resolved. :)
>>>>> 13.07.2013, 19:46, "Natalya Rozhnova" <natalya.rozhnova at lip6.fr>:
>>>>>> Hi Alex,
>>>>>> I have a question about boost library. I'm using boost version 1.53 on mac os. Everything works fine until I include the file ndn-name.h to basic class queue.h of network module. I added ndnSIM module as a dependency in wscript of network module. But I get a following error:
>>>>>> ./ns3/ndn-name.h:35:25: error: boost/ref.hpp: No such file or directory
>>>>>> I don't understand why it doesn't compile when I include ndn-name.h in Network module and compile otherwise... 
>>>>>> Thanks,
>>>>>> Natalya
>>>>> -------- End of forwarded message --------
>>>>> -- 
>>>>> Cordialement,
>>>>> Natalya Rozhnova
>>>>> PhD Student
>>>>> Université Pierre et Marie Curie - Sorbonne Universités - www.upmc.fr
>>>>> Laboratoire d'informatique de Paris 6 (LIP6) - Network and Performance Analysis Group (NPA) - www.lip6.fr
>>>>> Le Centre National de la Recherche Scientifique (CNRS) - www.cnrs.fr
>>>>> Content-Centric Networking - ccnx.org
>>>>> ANR CONNECT project - anr-connect.org
>>>>> _______________________________________________
>>>>> ndnSIM mailing list
>>>>> ndnSIM at lists.cs.ucla.edu
>>>>> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim
> _______________________________________________
> 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/20130714/b6deda45/attachment.html>

More information about the ndnSIM mailing list