[Freeswitch-users] Inbound or Outbound Socket connection?
David Villasmil
david.villasmil.work at gmail.com
Thu Oct 13 18:27:34 MSD 2016
Hello,
Why not connect to fs via perl esl and filter the events? (Inbound) you
remove the overhead of creating a new connection everytime a call is
executed...
you'd connect to fs from perl and keep the connection open.
David
On Thu, Oct 13, 2016 at 4:21 PM Anis Bedhiafi <anis.bedhiafi at e-volut.io>
wrote:
> Thank you very much.
>
> I am digging me too.
>
> Thank you again.
>
> Best Regards.
>
> On 13 Oct 2016 3:19 pm, "Valter Nogueira" <valter at fastway.com.br> wrote:
>
> I understood now, when invoking socket with async, it should start a new
> thread and continue to next step bridging the call.
>
> Well, I have never tried such thing before, I will do some testing and
> when I get any result I return to you.
>
> Regards,
>
> Valter
>
> 2016-10-13 11:06 GMT-03:00 Anis Bedhiafi <anis.bedhiafi at e-volut.io>:
>
> Dear Valtar,
>
> Thank you for your answer.
>
> Yes I am using ESL bind for perl.
>
> On 13 Oct 2016 2:59 pm, "Valter Nogueira" <valter at fastway.com.br> wrote:
>
> When you are using <action application="socket" data="127.0.0.1:8084
> async"/> it means you are in outbound mode (from the perspective of FS)
>
> Are you using ESL bind for perl or have you written your own
> implementation?
>
> After accepting a connection on 8084 port, you should issue a
> "connect\n\n" back to FS
>
> Valter
>
>
> 2016-10-12 7:08 GMT-03:00 Anis Bedhiafi <anis.bedhiafi at e-volut.io>:
>
> Hi Guys,
>
> I guess I have a little confusion here between inbound esl and outbound
> esl.
>
> *My Goal:* What I am trying to do is detect if the call is being
> transferred and notify the caller about it.
>
> *My Scenario:*
>
> 1- I have an application based on SIP.js client that makes outbound calls
> via a registered SIP trunk on my Freeswitch box. I upload a list of phone
> numbers to call and hit Launch button.
>
> 2- Some calls can be transferred by the callee endpoint. I want to detect
> this fact.
>
> 3- According to my research, I can do this using Event Socket library.
> 4- To detect if there is a transfer, I can control the channel variable
> RDNIS or TRANSFER_TIME. If there is a transfer these variables are not
> empty.
> 5- Once I detect there is a transfer I want to send a NOTIFY packet to the
> client.
>
> *My confusion is the following:*
>
> I don't know whether to use an Outbound socket connection or an Inbound
> Connection.
>
> I tried to do this with outbound connection as follows:
>
> <condition field="destination_number" expression="^1703$">
> <action application="set" data="socket_resume=true"/>
> <action application="socket" data="127.0.0.1:8084 async"/>
> <action application="bridge" data="sofia/gateway/mygateway/$1"/>
> </condition>
>
> I have a perl server listening on port 8084/tcp.
> In this perl script I subscribe for CHANNEL_ANSWER Events and I filter by
> the call uuid.
>
> The problem is when I call the socket connection, the bridge application
> never executes.
>
> How am I supposed to listen for a specific event and make a bridge call?
>
> Is what I am doing wrong. Please correct me.
>
> Thank you for your support.
>
> Kind regards.
>
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://confluence.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://confluence.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://confluence.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://confluence.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://confluence.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20161013/b9682f2a/attachment.html
Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users
mailing list