[Freeswitch-dev] ESL and the directory
I have been thinking about what would be the best direction to FSGui and I am leaning towards something like Asterisk Flash Operator ( http://www.asternic.org) and HUD (http://pbxtra.fonality.com/products/hud/). Since ESL has no comparison to Asterisk Manager whatsoever, it won't be too hard to get the application controlling all the extensions and doing all the cool CTI things such as record on demand, voicemail control and conference stuff, etc... Anyway, I was looking on how to achieve this goal and the first thing I would need is the domain list as well its users and groups. The ideal here would be having the directory section itself so I can parse it on my own and even add a few more variables to it so FSGui can control permissions and stuff like that. This would eliminate for good the need of a FSGui server to control this kinda of thing (that's what HUD does). I would like to open a discussion on how to achieve this since it will most definitely require some hacking on mod_commands since xml_locate is not able to provide it all as of now. So, here are the questions: 1. Using ESL for that is the best approach? If not, what would be? (I foresee the need of SSL on libesl soon ...) 2. Should I fetch root with xml_locate on ESL and parse whatever I am interested on FsGUI or should I add switch_xml_list_domains as well its API and whatever other methods are needed on xml retrieval? 1. switch_xml_locate_domain needs the domain name and at this point, I don't have it yet. 3. Do any of you see a problem with having additional vars on xml directory to control FsGUI permissions and options? If yes, what is the alternative solution? Anyway, I throwing this at the table so I can get input before making a decision. Hope this does not give you all too much trouble. Later, jmesquita
we spoke a bit in irc on this.... 2009/7/22 João Mesquita <jmesquita@gmail.com>
1. Using ESL for that is the best approach? If not, what would be? (I foresee the need of SSL on libesl soon ...)
ya
1. 2. Should I fetch root with xml_locate on ESL and parse whatever I am interested on FsGUI or should I add switch_xml_list_domains as well its API and whatever other methods are needed on xml retrieval? 1. switch_xml_locate_domain needs the domain name and at this point, I don't have it yet.
I'd personally prefer to see the xml api made richer. so adding a method
to enumerate the domains would be a good start. You can then suck down the domain in one shot. We talked about enumerating groups and users, but perhaps in your use case just working off the domain is enough.
1. 1. Do any of you see a problem with having additional vars on xml directory to control FsGUI permissions and options? If yes, what is the alternative solution?
I don't see a problem, but would suggest prefixing your parameters with
fsgui or something so that it is obvious what is for FS and what is FsGUI.
Anyway, I throwing this at the table so I can get input before making a decision. Hope this does not give you all too much trouble.
Later,
jmesquita
-- -Rupa
On Jul 22, 2009, at 1:03 AM, João Mesquita wrote:
Using ESL for that is the best approach? If not, what would be? (I foresee the need of SSL on libesl soon ...) Someone would need to add SSL support to mod_event_socket, Also while they are at it.. ipv6 support to event socket would be kewl too! :) Should I fetch root with xml_locate on ESL and parse whatever I am interested on FsGUI or should I add switch_xml_list_domains as well its API and whatever other methods are needed on xml retrieval? switch_xml_locate_domain needs the domain name and at this point, I don't have it yet.
You can xml_locate any section of the config directly... by name.
Do any of you see a problem with having additional vars on xml directory to control FsGUI permissions and options? If yes, what is the alternative solution? Not sure, can you give an example use case?
Anyway, I throwing this at the table so I can get input before making a decision. Hope this does not give you all too much trouble.
Later,
jmesquita
On Wed, Jul 22, 2009 at 7:29 AM, Brian West <brian@freeswitch.org> wrote:
On Jul 22, 2009, at 1:03 AM, João Mesquita wrote:
1. Using ESL for that is the best approach? If not, what would be? (I foresee the need of SSL on libesl soon ...)
Someone would need to add SSL support to mod_event_socket, Also while they are at it.. ipv6 support to event socket would be kewl too! :)
I have never thought of putting it anywhere else...
1. Should I fetch root with xml_locate on ESL and parse whatever I am interested on FsGUI or should I add switch_xml_list_domains as well its API and whatever other methods are needed on xml retrieval? 1. switch_xml_locate_domain needs the domain name and at this point, I don't have it yet.
You can xml_locate any section of the config directly... by name.
The current API exposed on esl does not support it. Quoting the wiki: xml_locate Find some XML. Usage: xml_locate [root | <section> <tag> <tag_attr_name> <tag_attr_val>] Looked at the code and it verifies.... So the question would be defined as: Should I patch this and enable it to return the whole section (awfully easy) or make the xml API richer by adding specific methods as suggested by Rupa?
1. Do any of you see a problem with having additional vars on xml directory to control FsGUI permissions and options? If yes, what is the alternative solution?
Not sure, can you give an example use case?
<param name="fsgui_allow_hold" value="true" /> <param name="fsgui_visible_group" value="default, sales" />
Anyway, I throwing this at the table so I can get input before making a decision. Hope this does not give you all too much trouble.
Later,
jmesquita
_______________________________________________ FreeSWITCH-dev mailing list FreeSWITCH-dev@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev http://www.freeswitch.org
if you are going to make a gui you would probably want to make a database schema to go with it and make higher level abstractions and then use xml_curl or the new xml_oddbc to generate the xml back to FS rather than try to use the static configs. you can still generate some of the configs static that do not change often but for things like directory and dialplan you should be doing an xml hook so your app and FS both use the same database schema to get/set the data. ask Swk on irc he has one in his contrib. 2009/7/22 João Mesquita <jmesquita@gmail.com>
On Wed, Jul 22, 2009 at 7:29 AM, Brian West <brian@freeswitch.org> wrote:
On Jul 22, 2009, at 1:03 AM, João Mesquita wrote:
1. Using ESL for that is the best approach? If not, what would be? (I foresee the need of SSL on libesl soon ...)
Someone would need to add SSL support to mod_event_socket, Also while they are at it.. ipv6 support to event socket would be kewl too! :)
I have never thought of putting it anywhere else...
1. Should I fetch root with xml_locate on ESL and parse whatever I am interested on FsGUI or should I add switch_xml_list_domains as well its API and whatever other methods are needed on xml retrieval? 1. switch_xml_locate_domain needs the domain name and at this point, I don't have it yet.
You can xml_locate any section of the config directly... by name.
The current API exposed on esl does not support it. Quoting the wiki: xml_locate
Find some XML.
Usage: xml_locate [root | <section> <tag> <tag_attr_name> <tag_attr_val>]
Looked at the code and it verifies.... So the question would be defined as: Should I patch this and enable it to return the whole section (awfully easy) or make the xml API richer by adding specific methods as suggested by Rupa?
1. Do any of you see a problem with having additional vars on xml directory to control FsGUI permissions and options? If yes, what is the alternative solution?
Not sure, can you give an example use case?
<param name="fsgui_allow_hold" value="true" /> <param name="fsgui_visible_group" value="default, sales" />
Anyway, I throwing this at the table so I can get input before making a decision. Hope this does not give you all too much trouble.
Later,
jmesquita
_______________________________________________ FreeSWITCH-dev mailing list FreeSWITCH-dev@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev http://www.freeswitch.org
_______________________________________________ FreeSWITCH-dev mailing list FreeSWITCH-dev@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev http://www.freeswitch.org
-- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire 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
Tony, I am sorry but I think you missed the point here. The idea is that FSGui will not _SET_ no XML on the directory from its GUI but yes be able to _GET_ its configs from the user directory that can be set anywhere and with any method supported since the core does not care (cos of xml hooks such as curl and odbc). In this case, FSGui will only fetch XML from the directory, read it and work with it, being totally passive. Take a look at HUD and you will get the point. Hooking it to the xml events on ESL, it will be able to play along to simply any web gui without a problem and FSGui could be used by all other projects that are setting and manipulating the XMLs. Of course, FSGui would have an overhead of "asking" for the user directory from time to time since we do not receive any events on esl if the directory has changed using curl. But I don't see that too much of a problem right now. jmesquita On Wed, Jul 22, 2009 at 11:59 AM, Anthony Minessale < anthony.minessale@gmail.com> wrote:
if you are going to make a gui you would probably want to make a database schema to go with it and make higher level abstractions and then use xml_curl or the new xml_oddbc to generate the xml back to FS rather than try to use the static configs.
you can still generate some of the configs static that do not change often but for things like directory and dialplan you should be doing an xml hook so your app and FS both use the same database schema to get/set the data.
ask Swk on irc he has one in his contrib.
2009/7/22 João Mesquita <jmesquita@gmail.com>
On Wed, Jul 22, 2009 at 7:29 AM, Brian West <brian@freeswitch.org> wrote:
On Jul 22, 2009, at 1:03 AM, João Mesquita wrote:
1. Using ESL for that is the best approach? If not, what would be? (I foresee the need of SSL on libesl soon ...)
Someone would need to add SSL support to mod_event_socket, Also while they are at it.. ipv6 support to event socket would be kewl too! :)
I have never thought of putting it anywhere else...
1. Should I fetch root with xml_locate on ESL and parse whatever I am interested on FsGUI or should I add switch_xml_list_domains as well its API and whatever other methods are needed on xml retrieval? 1. switch_xml_locate_domain needs the domain name and at this point, I don't have it yet.
You can xml_locate any section of the config directly... by name.
The current API exposed on esl does not support it. Quoting the wiki: xml_locate
Find some XML.
Usage: xml_locate [root | <section> <tag> <tag_attr_name> <tag_attr_val>]
Looked at the code and it verifies.... So the question would be defined as: Should I patch this and enable it to return the whole section (awfully easy) or make the xml API richer by adding specific methods as suggested by Rupa?
1. Do any of you see a problem with having additional vars on xml directory to control FsGUI permissions and options? If yes, what is the alternative solution?
Not sure, can you give an example use case?
<param name="fsgui_allow_hold" value="true" /> <param name="fsgui_visible_group" value="default, sales" />
Anyway, I throwing this at the table so I can get input before making a decision. Hope this does not give you all too much trouble.
Later,
jmesquita
_______________________________________________ FreeSWITCH-dev mailing list FreeSWITCH-dev@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev http://www.freeswitch.org
_______________________________________________ FreeSWITCH-dev mailing list FreeSWITCH-dev@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev http://www.freeswitch.org
-- Anthony Minessale II
FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire
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
_______________________________________________ FreeSWITCH-dev mailing list FreeSWITCH-dev@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev http://www.freeswitch.org
participants (4)
-
Anthony Minessale
-
Brian West
-
João Mesquita
-
Rupa Schomaker