o Robert Szokovacs on 02/16/2012 02:01 PM:
Hi,
While tuning our SEMS-based application, we noticed that receiving RTP
significantly lowers the number of concurrent sessions with acceptable audio
quality (we achieved around 1800 concurrent sessions on a 4-core machine).
that seems to be pretty few. Are all cores then fully loaded, or do
you experience higher jitter or delay already earlier (i.e. lock
contention; CPU still at low usage, but queues filling up etc).
what codec are you using? how many media processing threads?
You may also check out the multi RTP receiver threads introduced more
recently, and there were more performance related changes more
recently (your patch looks like to some 1.4 version).
We don't need the incoming RTP-media, but we need the rfc2833 DTMFs. So I'm
thinking about doing something like this:
Index: AmRtpStream.cpp
===================================================================
--- AmRtpStream.cpp (revision 14928)
+++ AmRtpStream.cpp (working copy)
@@ -592,6 +594,14 @@
memcpy(&last_recv_time,&p->recv_time, sizeof(struct timeval));
if (!receiving&& !passive) {
+ if (receive_dtmf&& telephone_event_pt.get()&& p->payload ==
telephone_event_pt->payload_type)
+ {
+ dtmf_payload_t* dpl = (dtmf_payload_t*)p->getData();
+
+ DBG("DTMF: event=%i; e=%i; r=%i; volume=%i; duration=%i; ts=%u\n",
+ dpl->event,dpl->e,dpl->r,dpl->volume,ntohs(dpl->duration),p->timestamp);
+ session->postDtmfEvent(new AmRtpDtmfEvent(dpl, getTelephoneEventRate(),
p->timestamp));
+ }
mem.freePacket(p);
return;
}
Is there any drawbacks to this approach?
I don't see any, if you don't need the audio, or in-band DTMF. The
DTMF event queue of the session is protected by its mutex, so it's
safe to post events there from the RTP receiver threads the same way
as the media processing thread. You have your sessions in the
MediaProcessor, I guess, so DTMF should be processed and passed to the
applicaiton.
Stefan
_______________________________________________
Semsdev mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/semsdev