Re: can GET do for QUERY?

On 2015-04-29 07:04, Willy Tarreau wrote:
> On Tue, Apr 28, 2015 at 11:59:18PM +0200, henry.story@bblfish.net wrote:
>> I tried it and it works on my server FWIW

The rational for not using GET definitively should be explained in the 
SEARCH spec.

For once: 
<http://greenbytes.de/tech/webdav/rfc7231.html#rfc.section.4.3.1.p.4>

>> -----------
>> $ telnet bblfish.net 80
>> Trying 208.64.60.175...
>> Connected to bblfish.net.
>> Escape character is '^]'.
>> GET / HTTP/1.1
>> Host: bblfish.net
>> Content-Type: text/query
>> Accept: text/csv
>> Content-Length: 42
>>
>> select surname, givenname, email limit 10
>
> Why not use POST then ? Passing a body in GET could confuse caches and
> result in wrong data being retrieved. There are reasons why POST is a
> different method.

That rational also needs to be in the spec (for instance: SEARCH is 
safe, POST is not).

Best regards, Julian

Received on Wednesday, 29 April 2015 06:36:37 UTC