[asterisk-dev] Defining a call under the new bridging architecture

Jonathan Rose jrose at digium.com
Fri Sep 5 17:50:02 CDT 2014


So a little bit of background before I jump into this...

In Asterisk 11, I worked on a feature known as call identifier logging.
https://wiki.asterisk.org/wiki/display/AST/Call+Identifier+Logging
It's a somewhat clingy concept where channels are tagged with a unique
identity (unique within a single system anyway) and then as things become
involved with that call, the ID gets spread around between multiple
channels and multiple threads and anything logged by a thread bound to a
call ID will display the value of that call ID in the log message
('[C-0000000a]' for instance).

For the most part this worked well in spite of complexities like transfers
and masquerades, but as of Asterisk 12 the new bridging model came into
play and some behaviors have changed a little and some have regressed. SIP
attended transfers for instance used to result in both the transferee and
the transfer target receiving a separate call ID from the original call
started by the transferer. Now the transfer target just gets moved into the
transferee's bridge and they both end up with disjoint call IDs.

Technically, the above behavior isn't necessarily wrong. In the above
example, the transferer did actually start a second call with the transfer
target and simply put the transfer target into the same bridge as the
transferee. Neither of them really started a new call from their
perspective, but clearly that isn't a satisfactory result because they are
in a call together. It stands to reason that they should be represented as
being involved in the same call at that point. But which call are they in?
The whole thing is a Ship of Theseus paradox and we need to decide what
happens as parts start falling off the ship.

https://wiki.asterisk.org/wiki/display/AST/Call+IDs+in+Asterisk+12+and+beyond

I've been drafting a wiki page to describe exactly what should constitute a
call within Asterisk. I've arrived at one fairly basic definition. A call
is a line of communication within Asterisk. This means that channels
independently communicating with Asterisk (such as through an IVR or a PBX
application like voicemail) are in their own calls. When two or more
channels become bridged together (in a way that they begin to communicate),
then those channels are now involved in the same call. In order to resolve
which call they should be considered involved with, we need a set of
propagation rules to determine which call IDs should win when new lines of
communication start. This wiki page is concerned with determining what
those rules should be and with exploring the potential edge cases that come
about when the picture becomes more complicated than just a simple
multiparty bridge.

If anyone has any suggestions about either the definition of a call or
about the rules for call ID propagation, please review this wiki article
and respond either in the wiki comments or to this mailing list post.

-- 
Jonathan R. Rose
Digium, Inc. | Software Engineer
445 Jan Davis Drive NW - Huntsville, AL 35806 - US
direct +1 256 428 6139

Check us out at: http://digium.com & http://asterisk.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20140905/6ffbbea5/attachment.html>


More information about the asterisk-dev mailing list