- From: James M Snell <jasnell@gmail.com>
- Date: Mon, 19 Aug 2013 11:58:57 -0700
- To: Martin Thomson <martin.thomson@gmail.com>
- Cc: Mark Nottingham <mnot@mnot.net>, HTTP Working Group <ietf-http-wg@w3.org>
The main reason Prefer exists is to give a reliably ignorable container for simple things that (a) can be safely ignored and (b) deal with optional behaviors the server is being asked to do. Truthfully, It's no really no different than the similar groups of things we have in headers like Cache-Control... which is also made up of a bunch of individual directives that could exist as independent headers. FWIW, I was just pointing out that you could have used Prefer and that what you've described fits within Prefer's original purpose. If you'd like using a separate header better, then by all means do so, but IMHO it would be a purely stylistic choice as I see no technical advantages to using a brand new dedicated header field (except perhaps saving a handful of octets the first time you send it in an http/2 compressed header block). And yes, there are clear rules for when you would use Prefer vs. not use it: Prefer is used by the client to ask the server to apply optional behaviors when processing a request; Expressing those within Prefer means that the server can safely ignore the client's request to apply those behaviors if the server chooses. In my opinion, that makes it fairly clear what kinds of things you'd put into it. Things like "Link" and "HTTP2-Settings" obviously do not fit because those do not deal with an "optional behavior that is safe to ignore". With "nice", the client is asking the server to treat the request as unimportant.. that's clearly an "optional behavior that is safe to ignore". I'm honestly not sure how much clearer it could be ;-) - James On Mon, Aug 19, 2013 at 11:33 AM, Martin Thomson <martin.thomson@gmail.com> wrote: > On 18 August 2013 17:36, Mark Nottingham <mnot@mnot.net> wrote: >> FWIW, in your use case, Martin, the intermediary is acting as the origin server -- it's a gateway, not a proxy. > > Right you are. I'm still struggling with the Prefer thing though. It > makes sense in a way, but it triggers antibodies. > > Maybe it's just Prefer isn't a real header in its own right. It's a > header that contains other headers. There's nothing special about > what Prefer carries that a regular header couldn't already carry. > There isn't a clear set of rules that help me decide when X belongs in > Prefer and when it doesn't.
Received on Monday, 19 August 2013 18:59:47 UTC