15/01/10 10:04:46 (12 years ago)

Add new introduction about Content Negotiation, remove section about transparent conneg, instead just mention RFC 2295 (see #81)

1 edited


  • draft-ietf-httpbis/latest/p3-payload.xml

    r741 r745  
    807807<section title="Content Negotiation" anchor="content.negotiation">
    809    Most HTTP responses include an entity which contains information for
    810    interpretation by a human user. Naturally, it is desirable to supply
    811    the user with the "best available" entity corresponding to the
    812    request. Unfortunately for servers and caches, not all users have the
    813    same preferences for what is "best," and not all user agents are
    814    equally capable of rendering all entity types. For that reason, HTTP
    815    has provisions for several mechanisms for "content negotiation" --
    816    the process of selecting the best representation for a given response
    817    when there are multiple representations available.
    818 </t>
    819 <x:note>
    820   <t>
    821     <x:h>Note:</x:h> This is not called "format negotiation" because the
    822     alternate representations may be of the same media type, but use
    823     different capabilities of that type, be in different languages,
    824     etc.
    825   </t>
    826 </x:note>
    827 <t>
    828    Any response containing an entity-body &MAY; be subject to negotiation,
    829    including error responses.
    830 </t>
    831 <t>
    832    There are two kinds of content negotiation which are possible in
    833    HTTP: server-driven and agent-driven negotiation. These two kinds of
    834    negotiation are orthogonal and thus may be used separately or in
    835    combination. One method of combination, referred to as transparent
    836    negotiation, occurs when a cache uses the agent-driven negotiation
    837    information provided by the origin server in order to provide
    838    server-driven negotiation for subsequent requests.
     809   HTTP responses include a representation which contains information for
     810   interpretation, whether by a human user or for further processing.
     811   Often, the server has different ways of representing the
     812   same information; for example, in different formats, languages,
     813   or using different character encodings.
     816   HTTP clients and their users might have different or variable
     817   capabilities, characteristics or preferences which would influence
     818   which representation, among those available from the server,
     819   would be best for the server to deliver. For this reason, HTTP
     820   provides mechanisms for "content negotiation" -- a process of
     821   allowing selection of a representation of a given resource,
     822   when more than one is available.
     825   This specification defines two patterns of content negotiation;
     826   "server-driven", where the server selects the representation based
     827   upon the client's stated preferences, and "agent-driven" negotiation,
     828   where the server provides a list of representations for the client to
     829   choose from, based upon their metadata. In addition,  there are
     830   other patterns: some applications use an "active content" pattern,
     831   where the server returns active content which runs on the client
     832   and, based on client available parameters, selects additional
     833   resources to invoke. "Transparent Content Negotiation" (<xref target="RFC2295"/>)
     834   has also been proposed.
     837   These patterns are all widely used, and have trade-offs in applicability
     838   and practicality. In particular, when the number of preferences or
     839   capabilities to be expressed by a client are large (such as when many
     840   different formats are supported by a user-agent), server-driven
     841   negotiation becomes unwieldy, and may not be appropriate. Conversely,
     842   when the number of representations to choose from is very large,
     843   agent-driven negotiation may not be appropriate.
     846   Note that in all cases, the supplier of representations has the
     847   responsibility for determining which representations might be
     848   considered to be the "same information".
    891901   capabilities and user preferences: Accept (<xref target="header.accept"/>), Accept-Charset
    892902   (<xref target="header.accept-charset"/>), Accept-Encoding (<xref target="header.accept-encoding"/>), Accept-Language
    893    (<xref target="header.accept-language"/>), and User-Agent (&header-user-agent;). However, an
    894    origin server is not limited to these dimensions and &MAY; vary the
    895    response based on any aspect of the request, including information
     903   (<xref target="header.accept-language"/>), and User-Agent (&header-user-agent;).
     904   However, an origin server is not limited to these dimensions and &MAY; vary
     905   the response based on any aspect of the request, including information
    896906   outside the request-header fields or within extension header fields
    897907   not defined by this specification.
     910  <t>
     911    <x:h>Note:</x:h> In practice, User-Agent based negotiation is fragile,
     912    because new clients might not be recognized.
     913  </t>
    900916   The Vary header field (&header-vary;) can be used to express the parameters the
    935    HTTP/1.1 defines the 300 (Multiple Choices) and 406 (Not Acceptable)
     951   This specification defines the 300 (Multiple Choices) and 406 (Not Acceptable)
    936952   status codes for enabling agent-driven negotiation when the server is
    937953   unwilling or unable to provide a varying response using server-driven
    938954   negotiation.
    939 </t>
    940 </section>
    942 <section title="Transparent Negotiation" anchor="transparent.negotiation">
    943 <t>
    944    Transparent negotiation is a combination of both server-driven and
    945    agent-driven negotiation. When a cache is supplied with a form of the
    946    list of available representations of the response (as in agent-driven
    947    negotiation) and the dimensions of variance are completely understood
    948    by the cache, then the cache becomes capable of performing server-driven
    949    negotiation on behalf of the origin server for subsequent
    950    requests on that resource.
    951 </t>
    952 <t>
    953    Transparent negotiation has the advantage of distributing the
    954    negotiation work that would otherwise be required of the origin
    955    server and also removing the second request delay of agent-driven
    956    negotiation when the cache is able to correctly guess the right
    957    response.
    958 </t>
    959 <t>
    960    This specification does not define any mechanism for transparent
    961    negotiation, though it also does not prevent any such mechanism from
    962    being developed as an extension that could be used within HTTP/1.1.
     2277<reference anchor='RFC2295'>
     2278  <front>
     2279    <title abbrev='HTTP Content Negotiation'>Transparent Content Negotiation in HTTP</title>
     2280    <author initials='K.' surname='Holtman' fullname='Koen Holtman'>
     2281      <organization>Technische Universiteit Eindhoven</organization>
     2282      <address>
     2283        <email>koen@win.tue.nl</email>
     2284      </address>
     2285    </author>
     2286    <author initials='A.H.' surname='Mutz' fullname='Andrew H. Mutz'>
     2287      <organization>Hewlett-Packard Company</organization>
     2288      <address>
     2289        <email>mutz@hpl.hp.com</email>
     2290      </address>
     2291    </author>
     2292    <date year='1998' month='March'/>
     2293  </front>
     2294  <seriesInfo name='RFC' value='2295'/>
    22852297<reference anchor="RFC2388">
    22862298  <front>
    30793091  <list style="symbols">
    30803092    <t>
     3093      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/81"/>:
     3094      "Content Negotiation for media types"
     3095    </t>
     3096    <t>
    30813097      <eref target="http://tools.ietf.org/wg/httpbis/trac/ticket/181"/>:
    30823098      "Accept-Language: which RFC4647 filtering?"
Note: See TracChangeset for help on using the changeset viewer.