[Freeswitch-users] [curl_sendfile][unable to get response]
Bilal Abbasi
bilaln018 at gmail.com
Wed Oct 11 12:46:19 UTC 2017
Thanks for your reply, yes issue got fix.
On Sun, Oct 8, 2017 at 12:25 AM, Yuriy Gorlichenko <ovoshlook at gmail.com>
wrote:
> You installed lib for lua 5.1 but Freeswitch requires lua 5.2
> you soulh it to install via luarocks for 5.2
>
>
> 2017-10-07 21:05 GMT+03:00 Bilal Abbasi <bilaln018 at gmail.com>:
>
>> Hi,
>> I build the lua script and used the cURL module for that(
>> https://github.com/Lua-cURL/Lua-cURLv3)
>> I am successfully place the POST request using that module, but when i
>> use that with in freeswitch using application lua it raise the ERR
>>
>> 2017-10-07 17:46:47.592484 [ERR] mod_lua.cpp:203 error loading module
>> 'lcurl' from file '/usr/local/lib/lua/5.1/lcurl.so':
>>
>> /usr/local/lib/lua/5.1/lcurl.so: undefined symbol: lua_tointeger
>>
>>
>> I am not sure why its raising this error while loading, its not raising
>> this when i run the script directly fromt the shell.
>>
>> Can you please help me in this regard.
>>
>>
>> Regards
>>
>> Abbasi
>>
>> On Fri, Oct 6, 2017 at 8:01 PM, Bilal Abbasi <bilaln018 at gmail.com> wrote:
>>
>>> Thanks i will try that way. Highly appreciated your response.
>>>
>>> Regards
>>> Abbasi
>>>
>>> On Fri, Oct 6, 2017 at 7:20 PM, Yuriy Gorlichenko <ovoshlook at gmail.com>
>>> wrote:
>>>
>>>> i think in your case will be better to use bg_api command and run
>>>> handler there.
>>>> Regarding native or not. Here is a good question - what will be faster
>>>> and i not sure that native will be faster way than lua binding
>>>>
>>>> On Oct 6, 2017 17:05, "Bilal Abbasi" <bilaln018 at gmail.com> wrote:
>>>>
>>>>> Hi,
>>>>> Thanks for the answer,
>>>>> 1) Yes i am aware of that, in fact we need to inform the user that
>>>>> file is uploaded successfully or not, so it's normal to have few seconds
>>>>> delay.
>>>>> 2)Yes i tried that way, and i did able to do that using lua cURL
>>>>> library, but i am only interested to know that may be the native function
>>>>> can provide me this, I mean if somebody has build this module there
>>>>> should/must be a way to get the status.
>>>>>
>>>>> Regards
>>>>> Abbasi
>>>>>
>>>>> On Fri, Oct 6, 2017 at 12:55 PM, Yuriy Gorlichenko <
>>>>> ovoshlook at gmail.com> wrote:
>>>>>
>>>>>> First of all - be carefull with file uploading from the dialplan,
>>>>>> because it can block call handling while you did not get response.
>>>>>>
>>>>>> Secondly - you also can use some external lua httpclient binding via
>>>>>> require and use it to get response statuses that you need.
>>>>>>
>>>>>> On Oct 6, 2017 10:00, "Bilal Abbasi" <bilaln018 at gmail.com> wrote:
>>>>>>
>>>>>>> Anybody here that can please help me out?
>>>>>>>
>>>>>>> Regards
>>>>>>> Abbasi
>>>>>>>
>>>>>>> On Wed, Oct 4, 2017 at 3:38 PM, Bilal Abbasi <bilaln018 at gmail.com>
>>>>>>> wrote:
>>>>>>>
>>>>>>>> Hi Users,
>>>>>>>> I am using lua script to actually call the curl_sendfile, i am able
>>>>>>>> to successfully POST the file on URL, but i am only curious to know the
>>>>>>>> response variables to get the status.
>>>>>>>> Like i used curl previously and there are two variables that are
>>>>>>>> auto set curl_response_data and curl_response_code, i am looking same in
>>>>>>>> the curl_sendfile.
>>>>>>>> CAn anybody help me in this?
>>>>>>>>
>>>>>>>> P.S: i did tried to send file using curl, but i am not aware that
>>>>>>>> how to do that using the curl -F(--form) option, i can upload a file using
>>>>>>>> commandline linux curl command , but could not mapp the option -F in the
>>>>>>>> freeswitch.
>>>>>>>>
>>>>>>>> Regards
>>>>>>>> Abbasi
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ____________________________________________________________
>>>>>>> _____________
>>>>>>> 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/free
>>>>>>> switch-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/free
>>>>>> switch-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/free
>>>>> switch-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/free
>>>> switch-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/20171011/88071deb/attachment.html>
More information about the FreeSWITCH-users
mailing list