← Back to team overview

p2psp team mailing list archive

Re: NAT Traversal Set of rules implementation

 

Hi Vicente,

>>> In the congestion avoiding mechanism implemented in the peers we have
>>> used the chunk cadence like a clock. The idea is to send a message
>>> only if a previous message has been received. The splitter receives
>>> chunks from the source and this could be our clock. It is also true
>>> that a new thread in the splitter increases its complexity, but if
>>> you put this code (basically, a counter that it is incremented each
>>> time a new chunk is received from the source and the sendto(message))
>>> in a thread, the main thread could be as clean as it is now.
>> Ok, this sounds good. Or to reduce complexity the thread could also
>> enqueue the messages to be sent, and then send them one after another
>> with a defined time (e.g. 1ms) in between, so there has to be no
>> synchronization between receiving chunks and sending packets. I can
>> try to implement this today in a simple way.
> Now I implemented a simple suggestion in an extra branch [1]. It can be
> easily extended by an event that is set each time a chunk is received,
> to implement the mechanism described by you.
The waiting for a received chunk is now implemented in the branch, too.

As this evening is the hard 'pencils down' deadline when we students are
obliged to stop coding on our project, and I'm not at home this evening,
this is my last coding for this GSoC project. I hope that the project is
complete from your point of view as well. :)

Thanks,
Max


[1] https://github.com/jellysheep/p2psp/compare/51aae05...message_queue



References