[Freeswitch-users] xml_curl: initiator type

Cal Leeming [Simplicity Media Ltd] cal.leeming at simplicitymedialtd.co.uk
Tue Nov 19 14:57:31 MSK 2013


Throw the raw XML from multiple requests into your favorite diff
software (if you're using windows, then check out Beyond Compare),
that will allow you to see which fields are different between
requests.

As mentioned before, this is not a quick/simple thing to undertake. If
you do this properly you'll need to analyse multiple use cases to
determine if your approach is correct.

Ask yourself what it is you are trying to achieve, and determine if
mod_xml_curl is the best way to do that. As much as I love
mod_xml_curl, sometimes it's not the right tool for the job depending
on what you are trying to do (sometimes there are easier ways).

Cal

On Tue, Nov 19, 2013 at 9:55 AM, vad fabi <vaad.fabi at gmail.com> wrote:
> Performed some tests for registered\unregistered user and gateway, and in
> all cases dialplan request was almost same :(
> I found that for registered user POST varibale
> FreeSWITCH-IPv4=variable_sip_from_host always and for gateways
> variable_sip_from_host = "IP of gateway". I don't know is it enough for
> strong identifying such request belongs registered user, but it only one
> mark.
> Also i don't know how to identify dialplan request of registered and
> unregistered users, it still big mystery for me ...
>
>
>
> On Tue, Nov 19, 2013 at 1:14 AM, Cal Leeming [Simplicity Media Ltd]
> <cal.leeming at simplicitymedialtd.co.uk> wrote:
>>
>> Converting the values from mod_xml_curl into application logic is not
>> straight forward, sometimes you have to compare multiple values in the
>> request to determine what is happening. For example, the mod_xml_curl
>> request for a registered gateway will be very different from that of
>> an unregistered gateway. Same goes for registered/unregistered users.
>> And it gets even more complicated when you throw multi tenant into the
>> picture, as well as blind and attended transfers.
>>
>> At the moment there is no external library that performs this logic
>> conversion for you - although I am working on one for Python as we
>> speak.
>>
>> The best advice I can give is to keep trying, but don't expect this to
>> be a one day job (at least, not if you do it properly).
>>
>> Cal
>>
>>
>> On Mon, Nov 18, 2013 at 9:53 PM, vad fabi <vaad.fabi at gmail.com> wrote:
>> > Hi all,
>> >
>> > How to indentify call initiator type (gateway or locally registered
>> > user)
>> > then freeswitch sends xml_curl dialplan request ?
>> > As i see all post variables almost same for both types.
>> >
>> >
>> > _________________________________________________________________________
>> > Professional FreeSWITCH Consulting Services:
>> > consulting at freeswitch.org
>> > http://www.freeswitchsolutions.com
>> >
>> > 
>> > 
>> >
>> > Official FreeSWITCH Sites
>> > http://www.freeswitch.org
>> > http://wiki.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://wiki.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
>
>



Join us at ClueCon 2013 Aug 6-8, 2013
More information about the FreeSWITCH-users mailing list