[erlang-questions] Does Inets HTTP client and PATCH method?

John Duffy jb_duffy@REDACTED
Mon Jan 19 18:06:15 CET 2015


Thank you Jesper

I will look into the libraries you mention.

Kind regards

John

Sent from my iPhone

> On 19 Jan 2015, at 13:46, Jesper Louis Andersen <jesper.louis.andersen@REDACTED> wrote:
> 
> 
>> On Sat, Jan 17, 2015 at 12:24 PM, John Duffy <jb_duffy@REDACTED> wrote:
>> My Foreign Exchange broker provides a HTTP REST API for automated trading, and uses the HTTP PATCH method for updating outstanding trade orders. I can't find a reference to the PATCH method in the httpc client documentation. Is this HTTP method supported?
> 
> No, it is not.
> 
> Only the basic ones listed in RFC 7231,
> 
> https://tools.ietf.org/html/rfc7231#section-4
> 
> are supported[0]. The registered method extensions listed in the HTTP method registry:
> 
> http://www.iana.org/assignments/http-methods/http-methods.xhtml
> 
> seems to be without support. It should be fairly easy to add missing methods however.
> 
> An alternative route would be to employ one of the many http client libraries out there. I'm partial to 'hackney' by Benoît Chesnau, but there are numerous others. On top of my head: lhttpc (Two branches: Fred Hebert, and one by Erlang Solutions Ltd.), gun (Loïc Hoguin), ibrowse (Chandrashekhar Mullaparthi), fusco (Diana Corbacho) and probably a couple I've forgotten. Different implementations enjoy different properties, so picking the one for your project may be something that takes a little time.
> 
> I well known problem with the built-in httpc is that it has problems when experiencing high load. But I've used it successfully for a low-traffic site for years (only GET requests though).
> 
> [0] though I have my doubts about CONNECT.
> 
> -- 
> J.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20150119/52ed247c/attachment.htm>


More information about the erlang-questions mailing list