Re: SPARQL Protocol Spec Examples

Kendall Clark wrote:

>> Secondly, I think it would be useful if the fault examples
>> demonstrated the use of the malformed-query and
>> query-request-refused. The first example returns plain-text,
>> the second an HTML document.
> 
> 
> I'm not sure what you mean here.
> 
>> For consistency, i.e. always returning XML, I think it would be
>> nicer if faults MUST return one of those elements and SHOULD include
>> a human-readable error message.
> 
> 
> I'm not sure what you mean here, either. Can you explain, or better,  
> show me an HTTP response that looks like what you're suggesting?

OK. Section 2.1.4 query Fault Messages includes some XSD that defines
two elements: malformed-query and query-request-refused.

Which lead me to expect this kind of HTTP response for a
request with an incorrect query (adapted from 2.2.1.9):

HTTP/1.1 400 Bad Request
Date: Wed, 03 Aug 2005 12:48:25 GMT
Server: Apache/1.3.29 (Unix) PHP/4.3.4 DAV/1.0.3
Connection: close
Content-Type: application/xml

<malformed-query xmlns="http://www.w3.org/2005/09/sparql-protocol-types/#">
4:syntax error, unexpected ORDER, expecting '}'
</malformed-query>

Received on Thursday, 3 November 2005 22:18:46 UTC