[asterisk-dev] RTP Bridging optimization

Vadim Lebedev vadim at mbdsys.com
Sun May 13 15:40:48 MST 2007



Kevin P. Fleming wrote:

>Vadim Lebedev wrote:
>
>  
>
>>I beleive you are mistaken,  the pipe syscals creates 2 file
>>descirptors, one for reading other for writing....
>>so in worst case you need 2 pipes meaning 4 fds
>>so first you splice to a write side of first pipe from a socket, then
>>optioanlly in case of montiored stream
>>tee form read side of the first pipe to the write side of the second pipe,
>>then splice from write side of the first pipe to the target socket, then
>>read from the read side of the second pipe
>>to perfrom monitoring
>>    
>>
>
>You just validated my point. A single bridge connecting two sockets
>requires two pipes, one for each direction between the sockets. This
>turns the '2 fds required' for a bridge into _6_ fds.
>
>  
>
You're right but  only in  the case that when you have separtae briding 
threads for each direction.
I was thinkin about situation when there is ONE briging theard for two 
directions. The you can you the same pipe
for both direction.
BTW thinking abouti it some more we could have ONE therad executing 
MULTIPLE bridges....
In this case you cane use the same pipes for ALL bridges. This could be 
really BIG optimization.

>In addition, this only works in the cases where the media streams are
>completely compatible, including dynamic RTP format number assignments,
>frame lengths and other variables.
>  
>
Sure,  but it is no different frm are tech_specific bridges...  in order 
to use tech-specific bridging the stream format must be identical


Thanks
Vadim

>  
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-dev/attachments/20070513/7eb19b8e/attachment.htm


More information about the asterisk-dev mailing list