Hello, I have done a small change in my dialplan which works but since I am new with FreeSWITCH I was wondering if this solution goes with the philosophy of the software or if it is absurd and there is a solution more adapted . I try to reproduce the following functionality: "A and B are on a simple call and decide to add C and have a conference. Later on they decide also to invite D..." In the dialplan I have added (based on the default dialplan): <extension name="Local_Extension"> <condition field="destination_number" expression="^(10[01][0-9])$"> ................ <anti-action application="bind_meta_app" data="1 a o transfer:: transf_call_${caller_id_number}"/> <anti-action application="bind_meta_app" data="2 a s transfer::-both transf_call_${caller_id_number}"/> ....... </condition> </extension> <extension name="transf_call_to_conf"> <condition field="destination_number" expression="^transf_call_(.*)$"> <action application="answer"/> <action application="conference" data="conf$1@conf_dynamic"/> </condition> </extension> Here, if A calls B then A can bridge both legs into a conference named "confnumberofA" by dialing *2. Then, A can put this call on hold and call C. - If C answers and agrees then A can press *1 in order to bridge C into the same conference "confnumberofA". A will come back into the conference which is still on hold. - If C does not answer then A will still be able to come back into the conference it puts on hold. My main problem is the name of the conference. Since everybody should be able to convert a simple call into a conference, the conference's name has to be unique each time. I have chosen to make it dependent on the caller number which is not perfect because then he is the only one which can bridge the call and add member. However, I do not have any other idea, maybe I have missed another possibility. I would be glad to get any critics you have, it would help me to better understand the fundamental concepts. Thanks, Carole -- View this message in context: http://www.nabble.com/dynamic-conference-tp21053181p21053181.html Sent from the Freeswitch-users mailing list archive at Nabble.com.
On 12/17/2008 7:34 AM, Carole O. wrote:
My main problem is the name of the conference. Since everybody should be able to convert a simple call into a conference, the conference's name has to be unique each time. I have chosen to make it dependent on the caller number which is not perfect because then he is the only one which can bridge the call and add member. However, I do not have any other idea, maybe I have missed another possibility.
If the conf name has to be unique, why not ensure that by making the conference name based on the uuid of the a-leg?
Thanks, Carole
It would be unique you are right but I am not sure I can get its value if A puts the call on hold, calls C and wants to add it to the conference whose name dependent of the uuid of another session. I think if I use ${uuid} to add C I will have the uuid of the session between A and C and not A and B no? And I really have to configure this from the dialplan so statically. Am I wrong somewhere?? Carole Rupa Schomaker (lists)-2 wrote:
On 12/17/2008 7:34 AM, Carole O. wrote:
My main problem is the name of the conference. Since everybody should be able to convert a simple call into a conference, the conference's name has to be unique each time. I have chosen to make it dependent on the caller number which is not perfect because then he is the only one which can bridge the call and add member. However, I do not have any other idea, maybe I have missed another possibility.
If the conf name has to be unique, why not ensure that by making the conference name based on the uuid of the a-leg?
Thanks, Carole
_______________________________________________ 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
-- View this message in context: http://www.nabble.com/dynamic-conference-tp21053181p21054080.html Sent from the Freeswitch-users mailing list archive at Nabble.com.
you could make up a uuid just for the conference name in the original call <action application="export" data="my_conf_id=${create_uuid()}"/> Now this channel and any other channel created by this channel will inherit this var On Wed, Dec 17, 2008 at 8:24 AM, Carole O. <carole.olivier@enst.fr> wrote:
It would be unique you are right but I am not sure I can get its value if A puts the call on hold, calls C and wants to add it to the conference whose name dependent of the uuid of another session. I think if I use ${uuid} to add C I will have the uuid of the session between A and C and not A and B no? And I really have to configure this from the dialplan so statically.
Am I wrong somewhere??
Carole
Rupa Schomaker (lists)-2 wrote:
On 12/17/2008 7:34 AM, Carole O. wrote:
My main problem is the name of the conference. Since everybody should be able to convert a simple call into a conference, the conference's name has to be unique each time. I have chosen to make it dependent on the caller number which is not perfect because then he is the only one which can bridge the call and add member. However, I do not have any other idea, maybe I have missed another possibility.
If the conf name has to be unique, why not ensure that by making the conference name based on the uuid of the a-leg?
Thanks, Carole
_______________________________________________ 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
-- View this message in context: http://www.nabble.com/dynamic-conference-tp21053181p21054080.html Sent from the Freeswitch-users mailing list archive at Nabble.com.
_______________________________________________ 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
-- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ AIM: anthm MSN:anthony_minessale@hotmail.com <MSN%3Aanthony_minessale@hotmail.com> GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com<PAYPAL%3Aanthony.minessale@gmail.com> IRC: irc.freenode.net #freeswitch FreeSWITCH Developer Conference sip:888@conference.freeswitch.org <sip%3A888@conference.freeswitch.org> iax:guest@conference.freeswitch.org/888 googletalk:conf+888@conference.freeswitch.org<googletalk%3Aconf%2B888@conference.freeswitch.org> pstn:213-799-1400
On 12/17/2008 8:24 AM, Carole O. wrote:
It would be unique you are right but I am not sure I can get its value if A puts the call on hold, calls C and wants to add it to the conference whose name dependent of the uuid of another session. I think if I use ${uuid} to add C I will have the uuid of the session between A and C and not A and B no? And I really have to configure this from the dialplan so statically.
Am I wrong somewhere??
Carole
Ah, yeah. uuid would not be the same when initiating a new call that you then transfer to the conference call. You need something that is intrinsic to the endpoint. I did a quick info dump to an originated call. Depending on your use-case (are these calls originating from registered handsets, trunked from a sip provider, etc) you might want to rely on the variable "sip_contact_uri" which is a combination of registered user name and ip (and port if port isn't 5060). This should be unique per endpoint.
Hello, Thanks for your answers! Concerning the creation of a new variable for the conference the problem is that I do not create channels from the conference. I call separately a new member on a new channel and add it on the conference only if he agrees to enter it. So it was the same problem as for the uuid, I am not sure I can access the good variable from anywhere in case many conferences are running. So, I do the following if somebody is interested in: <extension name="Local_Extension"> ..................... <condition field="destination_number" expression="^${caller_id_number}$"> <anti-action application="bind_meta_app" data="1 a o transfer:: transf_opp_leg_${db(select/conference/${caller_id_number})}_${destination_number}"/> <anti-action application="bind_meta_app" data="2 ab s transfer::-both transf_both_${uuid}_${caller_id_number}_${destination_number}"/> .......... </extension> <extension name="transf_both_legs"> <condition field="destination_number" expression="^transf_both_(.*)_(.*)_(.*)$"> <action application="db" data="insert/conference/$2/conf_$1"/> <action application="db" data="insert/conference/$3/conf_$1"/> <action application="answer"/> <action application="conference" data="conf_$1@conf_dynamic"/> </condition> </extension> <extension name="transf_opposite_leg"> <condition field="destination_number" expression="^transf_opp_leg_(.*)_(.*)$"> <action application="db" data="insert/conference/$2/$1"/> <action application="answer"/> <action application="conference" data="$1@conf_dynamic"/> </condition> </extension> This is not perfect and I am not sure it is "cleanly" programmed but it works and it is flexible. All the members in the conference can invite new members thanks to the conference name they all have in the database. If you still have critics they are all welcome! Thanks for your help, Best regards, Carole Rupa Schomaker (lists)-2 wrote:
On 12/17/2008 8:24 AM, Carole O. wrote:
It would be unique you are right but I am not sure I can get its value if A puts the call on hold, calls C and wants to add it to the conference whose name dependent of the uuid of another session. I think if I use ${uuid} to add C I will have the uuid of the session between A and C and not A and B no? And I really have to configure this from the dialplan so statically.
Am I wrong somewhere??
Carole
Ah, yeah. uuid would not be the same when initiating a new call that you then transfer to the conference call. You need something that is intrinsic to the endpoint.
I did a quick info dump to an originated call. Depending on your use-case (are these calls originating from registered handsets, trunked from a sip provider, etc) you might want to rely on the variable "sip_contact_uri" which is a combination of registered user name and ip (and port if port isn't 5060). This should be unique per endpoint.
_______________________________________________ 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
-- View this message in context: http://www.nabble.com/dynamic-conference-tp21053181p21069519.html Sent from the Freeswitch-users mailing list archive at Nabble.com.
Hello, Carole, your conference-programm is what I looked for. It's great. I try it. But I get an Error, when I press *1 and I don't know what it mean... Have you an idea? [ERR] mod_conference.c:4849 conference_new() invalid Record! No name. [CRIT] mod_conference.c:4314 conference_function() Memory Error! Thanks! -----Ursprüngliche Nachricht----- Von: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] Im Auftrag von Carole O. Gesendet: Donnerstag, 18. Dezember 2008 10:38 An: freeswitch-users@lists.freeswitch.org Betreff: Re: [Freeswitch-users] dynamic conference Hello, Thanks for your answers! Concerning the creation of a new variable for the conference the problem is that I do not create channels from the conference. I call separately a new member on a new channel and add it on the conference only if he agrees to enter it. So it was the same problem as for the uuid, I am not sure I can access the good variable from anywhere in case many conferences are running. So, I do the following if somebody is interested in: <extension name="Local_Extension"> ..................... <condition field="destination_number" expression="^${caller_id_number}$"> <anti-action application="bind_meta_app" data="1 a o transfer:: transf_opp_leg_${db(select/conference/${caller_id_number})}_${destination_nu mber}"/> <anti-action application="bind_meta_app" data="2 ab s transfer::-both transf_both_${uuid}_${caller_id_number}_${destination_number}"/> .......... </extension> <extension name="transf_both_legs"> <condition field="destination_number" expression="^transf_both_(.*)_(.*)_(.*)$"> <action application="db" data="insert/conference/$2/conf_$1"/> <action application="db" data="insert/conference/$3/conf_$1"/> <action application="answer"/> <action application="conference" data="conf_$1@conf_dynamic"/> </condition> </extension> <extension name="transf_opposite_leg"> <condition field="destination_number" expression="^transf_opp_leg_(.*)_(.*)$"> <action application="db" data="insert/conference/$2/$1"/> <action application="answer"/> <action application="conference" data="$1@conf_dynamic"/> </condition> </extension> This is not perfect and I am not sure it is "cleanly" programmed but it works and it is flexible. All the members in the conference can invite new members thanks to the conference name they all have in the database. If you still have critics they are all welcome! Thanks for your help, Best regards, Carole Rupa Schomaker (lists)-2 wrote:
On 12/17/2008 8:24 AM, Carole O. wrote:
It would be unique you are right but I am not sure I can get its value if A puts the call on hold, calls C and wants to add it to the conference whose name dependent of the uuid of another session. I think if I use ${uuid} to add C I will have the uuid of the session between A and C and not A and B no? And I really have to configure this from the dialplan so statically.
Am I wrong somewhere??
Carole
Ah, yeah. uuid would not be the same when initiating a new call that you then transfer to the conference call. You need something that is intrinsic to the endpoint.
I did a quick info dump to an originated call. Depending on your use-case (are these calls originating from registered handsets, trunked from a sip provider, etc) you might want to rely on the variable "sip_contact_uri" which is a combination of registered user name and ip (and port if port isn't 5060). This should be unique per endpoint.
_______________________________________________ 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
-- View this message in context: http://www.nabble.com/dynamic-conference-tp21053181p21069519.html Sent from the Freeswitch-users mailing list archive at Nabble.com. _______________________________________________ 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
Carole O. wrote:
Hello,
Thanks for your answers! Concerning the creation of a new variable for the conference the problem is that I do not create channels from the conference. I call separately a new member on a new channel and add it on the conference only if he agrees to enter it. So it was the same problem as for the uuid, I am not sure I can access the good variable from anywhere in case many conferences are running.
you could use the db app to hold state across multiple calls... maybe use the ${caller_id_number} and the ${destination_number} as keys for the insert/select so that there's something constant to use in the select... and another extension or two may be needed... You could do the db lookup before you make the call so that you see if your caller is already a member of a conference.... if he is, then the transfer from *1 would work much the same as it does now except you'd use the result of the db lookup as the conference number... if he's not a member of an existing conference, then you could generate the uuid like Anthony said before, then do a db insert for ${caller_id_number} and ${destination_number} to insert that newly created uuid and use it as the conference number.... one caveat that i see here is that the destination_number would have to be exactly the same as if that user were callling and it was his caller_id_number, otherwise your query will fail. you'll also need to "clean" the db when you hangup, which should be able to be accomplished with an execute_on_hangup that does a delete of the conf data for each user -Ray
Hello, Ray, thanks for your detailed answer!! Fidibus83, when are you pressing *1 ? Because the last version of the program I gave is thought to be executed like the following: - A and B are on call - A and B decide to change their call into a conference in order to invite other people. So A or B press first *2. In this way, both legs are transferred to the extension named transf_both_legs. In this extension, the name of the conference will be created and added in the database so you can not skip it. - A and B are now in a conference - A (or B) puts B (or A) on hold. - A (or B) calls C. - if C answers and agrees then A (or B) press *1. This transfers the opposite leg, this means C, to the extension transf_opposite_leg. C will be here transferred to the conference whose name will also be added in the db as an entry for C. - A (or B) comes back to the conference it had put on hold. - A, B and C are now all in the conference. So I am not sure but maybe you press first *1 instead of *2 isn't? If this is not the case then you could press F8 to debug and find out what's wrong. I am sorry but I can not help you more, I am new with freeswitch and not very experienced. Thanks to all of you for your help, I am going to improve this small program, Best regards, Carole Raymond Chandler-2 wrote:
Carole O. wrote:
Hello,
Thanks for your answers! Concerning the creation of a new variable for the conference the problem is that I do not create channels from the conference. I call separately a new member on a new channel and add it on the conference only if he agrees to enter it. So it was the same problem as for the uuid, I am not sure I can access the good variable from anywhere in case many conferences are running.
you could use the db app to hold state across multiple calls... maybe use the ${caller_id_number} and the ${destination_number} as keys for the insert/select so that there's something constant to use in the select... and another extension or two may be needed...
You could do the db lookup before you make the call so that you see if your caller is already a member of a conference.... if he is, then the transfer from *1 would work much the same as it does now except you'd use the result of the db lookup as the conference number... if he's not a member of an existing conference, then you could generate the uuid like Anthony said before, then do a db insert for ${caller_id_number} and ${destination_number} to insert that newly created uuid and use it as the conference number.... one caveat that i see here is that the destination_number would have to be exactly the same as if that user were callling and it was his caller_id_number, otherwise your query will fail.
you'll also need to "clean" the db when you hangup, which should be able to be accomplished with an execute_on_hangup that does a delete of the conf data for each user
-Ray
_______________________________________________ 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
-- View this message in context: http://www.nabble.com/dynamic-conference-tp21053181p21123756.html Sent from the Freeswitch-users mailing list archive at Nabble.com.
*Hi, I have seen the above mail. In that all of you tried to created dynamic conference through diaplan itself using the database to insert the uuid, caller_id_number, destination_number, etc .Can one guide me set the dynamic conference and Schema for the dynamic conference. I have tried the above dialplan with my Freeswitch 1.0.2 server but i cant able to get it. Can any one guide me for the this process. -- Warm Regards, N.Baskar *
participants (6)
-
Anthony Minessale
-
Baskar
-
Carole O.
-
fidibus83
-
Raymond Chandler
-
Rupa Schomaker (lists)