Sponsor: VoiceMeUp - Corporate & Wholesale VoIP Services

VoIP Mailing List Archives
Mailing list archives for the VoIP community
 SearchSearch 

[Freeswitch-users] Socket outbound: How to bridge two calls?

Goto page Previous  1, 2
 
Post new topic   Reply to topic    VoIP Mailing List Archives Forum Index -> freeSWITCH Users
View previous topic :: View next topic  
Author Message
odermann at googlemail...
Guest





PostPosted: Sun Nov 09, 2008 8:48 am    Post subject: [Freeswitch-users] Socket outbound: How to bridge two calls? Reply with quote

sorry for my late answer, i had to fly to a different place...

we are quite sure, that we have a problem with our php script. we
stripped down the code to the absolute minimum, to remove most
possible error sources, but it still does not work. the code can be
found under http://pastebin.freeswitch.org/6059.

we have a very strange behavior:
we get an inbound call over the socket to our script, we send an
answer and then we make an originate - nothing more.
the full fs debug can be found under http://pastebin.freeswitch.org/6060.

then we change to the cli, make show channels and then uuid_bridge
both uuid's. the result is "State RESET going to sleep".
but, as soon as we kill the process of the script, the uuid_bridge is done.

i have no idea where what the reason for the problem could be. as i
said, everything else works, but to make an uuid_bridge, we have to
kill the php process!?


thanks
dennis


2008/11/7 Anthony Minessale <anthony.minessale@gmail.com>:
Quote:
Can you capture the whole log from the instant you get the inbound call
until you give up on the uuid bridge?
I don't see any of the log about your outbound call.

are you doing

api originate sofia/internal/user@host &park()

For the outbound call like the cli example?

The socket application *is* park. You do not need to tell it to park.

as soon as you get the new inbound connection from calling socket app
all you need to do is answer it.

In your code when you fork are you closing the socket in the parent side so
it's not
in use by both processes?

_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
Back to top
anthony.minessale at g...
Guest





PostPosted: Mon Nov 10, 2008 10:11 am    Post subject: [Freeswitch-users] Socket outbound: How to bridge two calls? Reply with quote

The way your script is parsing appears too simple.
The event socket has a specific protocol.

Every command has a reply and you must read it and take into account the content len etc.

all replies, events etc have a content-type and content-len.




On Sun, Nov 9, 2008 at 7:44 AM, Dennis <odermann@googlemail.com (odermann@googlemail.com)> wrote:
Quote:
sorry for my late answer, i had to fly to a different place...

we are quite sure, that we have a problem with our php script. we
stripped down the code to the absolute minimum, to remove most
possible error sources, but it still does not work. the code can be
found under http://pastebin.freeswitch.org/6059.

we have a very strange behavior:
we get an inbound call over the socket to our script, we send an
answer and then we make an originate - nothing more.
the full fs debug can be found under http://pastebin.freeswitch.org/6060.

then we change to the cli, make show channels and then uuid_bridge
both uuid's. the result is "State RESET going to sleep".
but, as soon as we kill the process of the script, the uuid_bridge is done.

i have no idea where what the reason for the problem could be. as i
said, everything else works, but to make an uuid_bridge, we have to
kill the php process!?


thanks
dennis


2008/11/7 Anthony Minessale <anthony.minessale@gmail.com (anthony.minessale@gmail.com)>:
Quote:
Can you capture the whole log from the instant you get the inbound call
until you give up on the uuid bridge?
I don't see any of the log about your outbound call.

are you doing

api originate sofia/internal/user@host &park()

For the outbound call like the cli example?

The socket application *is* park. You do not need to tell it to park.

as soon as you get the new inbound connection from calling socket app
all you need to do is answer it.

In your code when you fork are you closing the socket in the parent side so
it's not
in use by both processes?



_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org





--
Anthony Minessale II

FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/

AIM: anthm
MSN:anthony_minessale@hotmail.com ([email]MSN%3Aanthony_minessale@hotmail.com[/email])
GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com ([email]PAYPAL%3Aanthony.minessale@gmail.com[/email])
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:888@conference.freeswitch.org ([email]sip%3A888@conference.freeswitch.org[/email])
iax:guest@conference.freeswitch.org/888
googletalk:conf+888@conference.freeswitch.org ([email]googletalk%3Aconf%2B888@conference.freeswitch.org[/email])
pstn:213-799-1400
Back to top
odermann at googlemail...
Guest





PostPosted: Mon Nov 10, 2008 10:48 am    Post subject: [Freeswitch-users] Socket outbound: How to bridge two calls? Reply with quote

you are right, the shown script is very simple. we shortened it a lot
just to show the problem.

in these tests we do not need any events, because we just answer and
originate - for these actions we do not need any events, filters and
so on.
the rest we do in the cli. in the cli we do show channels and
uuid_bridge. but the uuid_bridge is only done, when we kill the
process of the socket script.
there must be a problem, how we handle the inbound or something like this.

every alse we want to do with any call and uuid works, so i can't
imagine, that our php script does everything so wrong.
what makes uuid_bridge or intercept so different to other api commands?

isn't it possible to see something in the logfiles? perhaps, that the
inbound is in a wrong state or stuck somewhere in the socket?




2008/11/10 Anthony Minessale <anthony.minessale@gmail.com>:
Quote:
The way your script is parsing appears too simple.
The event socket has a specific protocol.

Every command has a reply and you must read it and take into account the
content len etc.

all replies, events etc have a content-type and content-len.

_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
Back to top
anthony.minessale at g...
Guest





PostPosted: Mon Nov 10, 2008 12:53 pm    Post subject: [Freeswitch-users] Socket outbound: How to bridge two calls? Reply with quote

you must read the reply to the commands when you send them or you will block the tcp socket.


On Mon, Nov 10, 2008 at 9:48 AM, Dennis <odermann@googlemail.com (odermann@googlemail.com)> wrote:
Quote:
you are right, the shown script is very simple. we shortened it a lot
just to show the problem.

in these tests we do not need any events, because we just answer and
originate - for these actions we do not need any events, filters and
so on.
the rest we do in the cli. in the cli we do show channels and
uuid_bridge. but the uuid_bridge is only done, when we kill the
process of the socket script.
there must be a problem, how we handle the inbound or something like this.

every alse we want to do with any call and uuid works, so i can't
imagine, that our php script does everything so wrong.
what makes uuid_bridge or intercept so different to other api commands?

isn't it possible to see something in the logfiles? perhaps, that the
inbound is in a wrong state or stuck somewhere in the socket?




2008/11/10 Anthony Minessale <anthony.minessale@gmail.com (anthony.minessale@gmail.com)>:
Quote:
The way your script is parsing appears too simple.
The event socket has a specific protocol.

Every command has a reply and you must read it and take into account the
content len etc.

all replies, events etc have a content-type and content-len.



_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org





--
Anthony Minessale II

FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/

AIM: anthm
MSN:anthony_minessale@hotmail.com ([email]MSN%3Aanthony_minessale@hotmail.com[/email])
GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com ([email]PAYPAL%3Aanthony.minessale@gmail.com[/email])
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:888@conference.freeswitch.org ([email]sip%3A888@conference.freeswitch.org[/email])
iax:guest@conference.freeswitch.org/888
googletalk:conf+888@conference.freeswitch.org ([email]googletalk%3Aconf%2B888@conference.freeswitch.org[/email])
pstn:213-799-1400
Back to top
odermann at googlemail...
Guest





PostPosted: Tue Nov 11, 2008 9:12 am    Post subject: [Freeswitch-users] Socket outbound: How to bridge two calls? Reply with quote

we read every single reply and we make socket_read with the legth
returned by Content-Length.

what we can do with fs, socket outbound and our php-script:

1.) we can answer the inbound, make a bridge to another phone and both
lines are connected and can talk to each other.

2.) we can make an inbound, then make two bgapi originates and
uuid_bridge both originated calls, so that they can talk to each
other.

3.) we made some thausend testcalls with sipp over the socket to our
script with 30cps and had not one failed call.


the only thing we can not do:

=> make an inbound call, then make an originate and uuid_bridge the
inbound and outbound.


i just can't imagine where the problem could be.

could we talk about some kind of consulting to take a little deeper
look into this problem?




2008/11/10 Anthony Minessale <anthony.minessale@gmail.com>:
Quote:
you must read the reply to the commands when you send them or you will block
the tcp socket.

_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
Back to top
anthony.minessale at g...
Guest





PostPosted: Tue Nov 11, 2008 9:30 am    Post subject: [Freeswitch-users] Socket outbound: How to bridge two calls? Reply with quote

yes hop on irc i'll be there in 30 min


On Tue, Nov 11, 2008 at 8:11 AM, Dennis <odermann@googlemail.com (odermann@googlemail.com)> wrote:
Quote:
we read every single reply and we make socket_read with the legth
returned by Content-Length.

what we can do with fs, socket outbound and our php-script:

1.) we can answer the inbound, make a bridge to another phone and both
lines are connected and can talk to each other.

2.) we can make an inbound, then make two bgapi originates and
uuid_bridge both originated calls, so that they can talk to each
other.

3.) we made some thausend testcalls with sipp over the socket to our
script with 30cps and had not one failed call.


the only thing we can not do:

=> make an inbound call, then make an originate and uuid_bridge the
inbound and outbound.


i just can't imagine where the problem could be.

could we talk about some kind of consulting to take a little deeper
look into this problem?




2008/11/10 Anthony Minessale <anthony.minessale@gmail.com (anthony.minessale@gmail.com)>:

Quote:
you must read the reply to the commands when you send them or you will block
the tcp socket.



_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org





--
Anthony Minessale II

FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/

AIM: anthm
MSN:anthony_minessale@hotmail.com ([email]MSN%3Aanthony_minessale@hotmail.com[/email])
GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com ([email]PAYPAL%3Aanthony.minessale@gmail.com[/email])
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:888@conference.freeswitch.org ([email]sip%3A888@conference.freeswitch.org[/email])
iax:guest@conference.freeswitch.org/888
googletalk:conf+888@conference.freeswitch.org ([email]googletalk%3Aconf%2B888@conference.freeswitch.org[/email])
pstn:213-799-1400
Back to top
Display posts from previous:   
Post new topic   Reply to topic    VoIP Mailing List Archives Forum Index -> freeSWITCH Users All times are GMT - 5 Hours
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group

VoiceMeUp - Corporate & Wholesale VoIP Services