This is a static archive of the previous Open Grid Forum GridForge content management system saved from host forge.ogf.org file /sf/wiki/do/viewPage/projects.occi-wg/wiki/HTTPHeaderRendering at Fri, 04 Nov 2022 20:05:05 GMT SourceForge : View Wiki Page: HTTPHeaderRendering

Project Home

Tracker

Documents

Tasks

Source Code

Discussions

File Releases

Wiki

Project Admin

Web Site
Search Wiki Pages Project: occi-wg     Wiki > HTTPHeaderRendering > View Wiki Page
wiki2438: HTTPHeaderRendering

WARNING: THIS SITE IS NOW CLOSED: ONGOING WRITEUPS CAN BE FOUND IN THE SVN REPOSITORY USING LaTEX

1 HTTP Rendering

1.1 Overview

TBD: Explain CRUD/REST here....

1.2 Versioning

1.3 Content-type and Accept headers

TBD: describe stuff here.... Impl should react on Accept and Content-type stuff...

1.4 Render OCCI model in the HTTP Header

Note: This is the default rendering mode for OCCI - It is the fallback. In some use cases (Collections, Query Interface) it needs to render stuff using specific Content-types like 'text/uri-list' or 'text/plain'

The HTTP header fields MUST follow the specification in RFC 2616. A header field consists of a name followed by a colon (":") and the field value. The format of the field value is specified separately for each of the three header fields, see below.

HTTP header fields MAY appear multiple times in a HTTP request or response. In order to be OCCI compliant the specification of multiple message-header fields according to RFC 2616 (section 4.2) MUST be fully supported. In essence there are two valid representation of multiple HTTP header field values. A header field might either appear several times or as a single header field with a comma-separated list of field values. Due to implementation issues in many web frameworks and client libraries it is RECOMMENDED to use the comma-separated list format for best interoperability.

HTTP header field values which contain separator characters MUST be properly quoted according to RFC 2616.

1.4.1 HTTP Header Fields

Three different HTTP header fields are used to render the OCCI model. Each header field value has a different format.

1.4.1.1 Category Header

The Category header is defined by the Web Categories specification, http://tools.ietf.org/html/draft-johnston-http-category-header-01. The semantics of the Category header in the OCCI context is described in the OCCI Core & Models document.

1.4.1.2 Link Header

The Link header is defined by the Web Linking specification, http://tools.ietf.org/html/draft-nottingham-http-link-header-10. The semantics of the Link header in the OCCI context is described in the OCCI Core & Models document.

1.4.1.3 Attribute Header

The Attribute header is used to render the attributes associated with a OCCI Resource. A simple key-value format is used. The field value consist of an attribute name followed by an equal sign ("=") and the attribute value. The attribute value must be quoted if it includes a separator character, see RFC 2616 (page 16).

Valid attribute names for OCCI Resources are specified in Extension documents.

The following handling MUST be implemented:

Operation Header fields in request Header fields in response
Creation of a Kind Required: Category
Optional: Link, Attribute
Required: Location
Retrieval of a Kind Required: Category
Optional: Link, Attribute
Required: Category
Optional: Link*, Attribute
Listing of Kinds Optional: Category Required: Location
Deletion of Kind Required: Category Return code
Update of Kind Required: Category
Optional: Link, Attribute
return Code
Query request (GET on /-/) Required: Category
  • Links also contain currently active Actions!

Note: to be HTTP compliant the body can contain an empty string

1.4.2 Examples

Description Howto Render Used when
Rendering of a Category Category:<term>;scheme="<scheme>";rel=+>;title=;attributes=}} Client uses Query interface
Rendering of a Kind Should contain at least a Category and optional Link and Attribute Headers:
Category: see above
Attribute:<list of comma separated key value pairs (joined by '=')>
Link: see below
Client request a Kind
Rendering of an Action Category: see above
Link:<<url>+ ';action=' <action name>>]
Client performs an action
Rendering of a Link Category: see above
Link: ???
List of Resource Location:<comma separated list of URIs> Listing of (sub)resources
List of Categories Category:<comma separated list of Category Renderings> Query interface

Note: there is no order for the optional parts.

Note: Whenevera request or response is generate there should be an Category rendering!

1.5 Render OCCI model in the HTTP Body

Note: In case that the Header Attributes become overfull, or collections are used the OCCI model MUST be rendered in the HTTP-Body. This MUST also be done when the Client requests 'text/plain'.

1.5.1 Examples

See above just that Category, Link and Attribute are now in the body... And ':' becomes '='

1.6 Render OCCI model via URL Listings

Note: This rendering cannot render Kinds of Categories directly but just Links to them. For concrete rendering of Kinds and Categories the Content-types '*/*', 'text/plain' must be used.

1.6.1 Examples

Description Howto Render Used when
Rendering of a Category Not supported Client uses Query interface
Rendering of a Kind Not supported Client request a Kind
Rendering of an Action Not supported Client performs an action
Rendering of a Link ???
List of Resource <list of URIs> Listing of (sub)resources
List of Categories <list of <scheme>+<term> URLs> Query interface

Contributors

  • Editors: Andy Edmonds, Thijs Metsch
  • Contributors: Ralf Nyrén, Sam Johnston
 



Versions Associations Attachments Back Links  
Version Version Comment Created By
Version 30 Thijs Metsch - 10/06/2010
Version 29 Thijs Metsch - 10/06/2010
Version 28 Thijs Metsch - 10/06/2010
Version 27 Thijs Metsch - 10/06/2010
Version 26 Thijs Metsch - 10/06/2010
Version 25 Thijs Metsch - 10/06/2010
Version 24 Thijs Metsch - 10/06/2010
Version 23 Thijs Metsch - 10/06/2010
Version 22 Thijs Metsch - 09/22/2010
Version 21 Thijs Metsch - 09/21/2010
Version 20 Andy Edmonds - 09/17/2010
Version 19 Thijs Metsch - 08/25/2010
Version 18 Andy Edmonds - 08/18/2010
Version 17 Andy Edmonds - 08/18/2010
Version 16 Andy Edmonds - 08/18/2010
Version 15 added note on max. http header line size Andy Edmonds - 08/18/2010
Version 14 Ralf Nyrén - 08/17/2010
Version 13 add location in RFC2616 to a list of specified separators Andy Edmonds - 08/16/2010
Version 12 comments on separator characters Andy Edmonds - 08/16/2010
Version 11 Re-introduced the Attribute header. More detailed specification of header formats. Ralf Nyrén - 08/16/2010
Version 10 Thijs Metsch - 08/16/2010
Version 9 Thijs Metsch - 07/28/2010
Version 8 Thijs Metsch - 07/28/2010
Version 7 Thijs Metsch - 07/28/2010
Version 6 Thijs Metsch - 07/28/2010
Version 5 Thijs Metsch - 07/28/2010
Version 4 Thijs Metsch - 07/07/2010
Version 3 Andy Edmonds - 07/07/2010
Version 2 Andy Edmonds - 07/07/2010
Version 1 Thijs Metsch - 07/06/2010



The Open Grid Forum Contact Webmaster | Report a problem | GridForge Help
This is a static archive of the previous Open Grid Forum GridForge content management system saved from host forge.ogf.org file /sf/wiki/do/viewPage/projects.occi-wg/wiki/HTTPHeaderRendering at Fri, 04 Nov 2022 20:05:17 GMT