-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add "profile" HTTP preference #92
Comments
there is a possible alternative approach, which is using dedicated profile negotiation header fields: https://github.com/ProfileNegotiation/I-D-Accept--Schema (by @larsgsvensson and @RubenVerborgh) |
still waiting for feedback from @jasnell, but for now assuming that a |
Sorry @dret ! Just spotted this again! Yeah, I think that's fine |
On 2018-03-17 13:05, James M Snell wrote:
Sorry @dret <https://github.com/dret> ! Just spotted this again! Yeah, I
think that's fine
that's good to hear, and thanks for your response!
|
If the client states a preference for a profile using the |
@larsgsvensson: that would be the same as what happens if the server simply does not understand or ignore the
|
OK, thanks. But then there is no way the client would know which profile the data conforms to, as opposed to e. g. media types where client can say |
On 2018-03-23 11:44, Lars G. Svensson wrote:
OK, thanks. But then there is no way the client would know which profile
the data conforms to, as opposed to e. g. media types where client can
say |Accept: application/ld+json| and the server can answer
'Content-Type: text/html|.
there are several ways for the profile to be discoverable, the server
can signal profiles in the usual way: it may add a profile link in the
Link header field, it may use the profile parameter on the media type
(if the media type supports that), or it may use in-band signals in the
content itself (if the media type supports that).
Even if the client cannot handle that, at
least it knows it has received somethin it cannot handle an can act
accordingly instead of having to try out different profiles and
eventually throw an|UnknownProfileException`.
profiles are nothing but hints. clients always have to make sure they
can handle what they received. that's a general rule of web architecture
beyond just profiles.
one principle of profiles is that clients can *always* safely fall back
to media type semantics, if they don't support the profile (a podcast
*is a feed*, so clients can always safely treat it as such). clients
only working with a specific profile and having no idea what to do
otherwise would be bad clients.
|
as a way to negotiate and signal profiles in HTTP that is independent of a
profile
parameter supported by the media type, aprofile
HTTP preference (based on https://tools.ietf.org/html/rfc7240) would allow profiles to be better supported one the HTTP level.maybe @jasnell has comments on how appropriate that usage of RFC 7240 would be?
The text was updated successfully, but these errors were encountered: