[Freeswitch-users] Loopback and bypass_media

Michael Collins msc at freeswitch.org
Tue Aug 11 11:07:23 PDT 2009

On Tue, Aug 11, 2009 at 11:08 AM, Phillip Jones <pjintheusa at gmail.com>wrote:

> Can you use this method to make simultaneous calls though while
> preserving carrier order? i.e. each call must try carrier 1 first then
> carrier 2 (because each carrier terminates a different subset of
> numbers)
> So - if I did NOT want to support failover I would use:
> session:execute("bridge",
> "sofia/gateway/broadvox/6095553828,sofia/gateway/broadvox/7325553828");
>  << call 6095553828 and 7325553828 at the same time
> If I were to use failover and not need multiple destinations then I would
> use:
> session:execute("bridge",
> "sofia/gateway/broadvox/6095553828|sofia/gateway/quest/6095553828");
> << call using broadvox first and quest it that fails
> I need to combine:
> Call 6095553828  and 7325553828 simultaneously and each trying
> broadvox then on fail quest.
> session:execute("bridge",
> "(sofia/gateway/broadvox/6095553828|sofia/gateway/quest/6095553828),(sofia/gateway/broadvox/7325553828,sofia/gateway/quest/7325553828)");
> But of course that syntax does not work.
> I can not see another syntax that would achieve this?

Just to make sure I'm reading you correctly I want to clarify...

You are trying to maintain carrier order and also trying to dial
simultaneously. If I understand what you mean, you have two separate
dialstrings that you want to dial simultaneously and if BOTH fail, THEN you
want to dial the third dialstring?

If the above is correct then this dialplan snippet SHOULD work:

<action application="set" data="continue_on_fail=true"/>
<action application="bridge"
<!-- if either of the above dialstrings is successful then this next line
won't execute... -->
<action application="bridge" data="sofia/gateway/quest/7325553828"/>

I also noticed that you're using js in your example... I hope you will
consider using the dialplan instead. The DP is quick and clean. At the very
least, if you really need js for some logic then let the js do the logic and
then transfer back out to the dialplan. That way you will use fewer system
resources and your project can scale more easily.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20090811/1fdb2da1/attachment-0002.html 

More information about the FreeSWITCH-users mailing list