[asterisk-users] asterisk is not sip proxy

Alex Balashov abalashov at evaristesys.com
Sun Jul 8 04:19:13 CDT 2007


Edgar,

On Sat, 7 Jul 2007, Edgar Guadamuz wrote:

> I know that Asterisk acts as a useragent endpoint, but my doubt is why 
> exactly Asterisk could overload the call flow if the RTP voice stream 
> goes from the caller to the called party.

   Asterisk is used commonly enough in carrier/transit applications 
precisely in this manner, and it is not necessarily untenable to do so. 
The distinction between a back-to-back user agent and a proxy is a rather 
formal one;  the reason a B2BUA is not a proxy is more to do with the fact 
that even with re-INVITEs enabled, on the signaling level Asterisk builds 
out two distinct call legs with distinct GUIDs ("Call-IDs") and 
cross-connects them, and intermediates the capability negotiation (codecs, 
packetisation delay, etc.) and establishment (media ports, etc.) heavily
by virtue of that.  A proxy, by contrast, is simply a SIP message router;
it forwards SIP messages along a signaling path with whose fundamental
protocol-level continuity it does not interfere.

   The practical reason to use something like [Open]SER over Asterisk for
call placement has to do with the tasks for which it is intended to scale.
A SIP proxy is specially optimised for handling large-scale call routing
and its feature set and design pattern is largely built around that
imperative.  In the case of SER, it also has a number of advanced features
that revolve around call routing and SIP header filtering / rewriting and
other things one might typically expect from an element that plays a 
gateway role, and which are only partially present in Asterisk and not to
the same degree.

   Both Asterisk and SER keep state information about SIP sessions and
transactions, but Asterisk as an endpoint is likely to allocate far more
memory and devote more programmatic hooks to each call leg on the premise
that it is used as an endpoint or a feature server and not as a simple
router.  I am not an Asterisk developer, of course, so at best this is
really a reasoned conjecture, and some people's mileage may vary.  But if
we take what I said as fact, SER comes out looking as a much more "lean"
solution from the vantage point of pure message passing and routing.

   On the other hand, Asterisk has far more advanced and developed 
capabilities to interface with other applications and/or provide more 
high-level call management capabilities.  A SIP proxy is really just
about proxying, and not much else.  That's why many VoIP 
billing/settlement/clearing platforms actually bounce calls off Asterisk,
in order to take advantage of its CDR engine, etc.

   If you do not find those methodological considerations persuasive or 
they do not present at an issue at your volume and scale, however, they
may ultimately be inconsequential to your application.  And indeed, if you
talk to many VoIP termination / origination providers, you will find that
many of them use Asterisk in transit applications in some shape or form.

-- Alex

--
Alex Balashov
Evariste Systems
Web    : http://www.evaristesys.com/
Tel    : +1-678-954-0670
Direct : +1-678-954-0671



More information about the asterisk-users mailing list