<div dir="ltr">Hi,<div><br></div><div class="gmail_extra"><div class="gmail_quote">On Wed, Sep 7, 2016 at 4:14 PM, Agalya RAMACHANDRAN <span dir="ltr"><<a href="mailto:agalya.job@gmail.com" target="_blank">agalya.job@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi team,<div><br></div><div>I am Agalya and I work for Comcast. We are trying to use kamailio as proxy server for our project. </div><div>I have a query regarding the same. We are trying to use REST API calls asynchronously from the config file. </div><div>I see that there is a module "http_async_client" which is used to handle REST services asynchronously. </div><div><br></div><div>Found that libcurl is used to perform these operations. </div><div>My question is:</div><div><br></div><div>1) How much time kamailio is taking to send the HTTP request out after TCP port is opened? </div><div>    Is there any time dependency we need to wait on libcurl to send HTTP request out?</div><div>    B'coz in opensips I see a delay time and  libcurl is used in-turn. </div><div>    I found kamailio doing similar to opensips and hence am posting this question.</div><div><br></div></div></blockquote><div> </div><div>The HTTP request is sent right after opening the socket. I've never noticed a delay between the TCP handshake and the query being sent. Then the connection is cached and can be reused by subsequent queries to the same server. Did you observe a different behavior?</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div></div><div>2) We can also use PUT service by using <span style="color:rgb(51,51,51);font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;white-space:pre-wrap">http_set_method(PUT)? </span></div><div><span style="color:rgb(51,51,51);font-family:consolas,"liberation mono",menlo,courier,monospace;font-size:12px;line-height:20px;white-space:pre-wrap">  </span><span style="color:rgb(51,51,51);font-size:12px;line-height:20px;white-space:pre-wrap"><font face="arial, helvetica, sans-serif">Should we add code to support PUT service? </font></span></div><div><span style="color:rgb(51,51,51);font-size:12px;line-height:20px;white-space:pre-wrap"><font face="arial, helvetica, sans-serif"><br></font></span></div></div></blockquote><div>PUT method is supported. To set the query's method you can also use the $http_req pseudovariable (<a href="http://www.kamailio.org/docs/modules/devel/modules/http_async_client.html#idp23451668">http://www.kamailio.org/docs/modules/devel/modules/http_async_client.html#idp23451668</a>) in this way:</div><div><br></div><div>$http_req(method) = "PUT";</div><div><br></div><div>Regards,</div><div><br></div><div>Federico</div></div></div></div>