W3C home > Mailing lists > Public > public-rdf-dawg-comments@w3.org > September 2010

SPARQL 1.1 Protocol: HTTP status code for QueryRequestRefused

From: Richard Cyganiak <richard@cyganiak.de>
Date: Wed, 29 Sep 2010 13:23:08 +0100
Message-Id: <F552AC1B-64D8-48FB-9778-68036E1D4C3A@cyganiak.de>
To: public-rdf-dawg-comments@w3.org
This is a comment on the latest SPARQL 1.1 Protocol draft [1]. It  
concerns an issue that was already present in the SPARQL 1.0 version  
of the Protocol.

I cannot quite work out what HTTP response code to use in the case of  
a QueryRequestRefused fault. The obvious place to look for this in the  
specification would be here:

Section 2.2.1, “HTTP Bindings for SPARQL Query”:

> In each of these bindings, the two faults described in  
> SparqlProtocol interface, MalformedQuery and QueryRequestRefused,  
> are bound to HTTP status codes 400 Bad Request and 500 Internal  
> Server Error, respectively [HTTP].

The WSDL snippet in this section says the same thing. But elsewhere I  
find:

Section 2.1.1.3.2, “QueryRequestRefused”:

> The QueryRequestRefusedfault [does not] constrain a conformant  
> SPARQL service from returning other HTTP status codes or HTTP  
> headers as appropriate given the semantics of [HTTP].

The problem in my eyes is:

1. The two quotes contradict each other.

2. Any language about HTTP status codes should be in the HTTP Bindings  
section, not in the abstract interface definition section.

Hence I propose to remove that sentence from 2.1.1.3.2, and reduce the  
last sentence of the section to just:

“The QueryRequestRefusedfault message does not indicate whether the  
server may or may not process a subsequent, identical request or  
requests.”

Furthermore, I propose to add the following sentence after the  
sentence starting “In each of these bindings ...” in 2.2.1:

“Despite the use of the 500 status code for QueryRequestRefused in  
this binding, a conformant SPARQL service MAY return other HTTP status  
codes or HTTP headers as appropriate given the semantics of [HTTP].”

Best,
Richard

[1] http://www.w3.org/TR/2010/WD-sparql11-protocol-20100126/
Received on Wednesday, 29 September 2010 12:23:48 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 29 September 2010 12:23:48 GMT