SPARQL Protocol Implementation Report

Introduction

This report by the RDF Data Access Working Group (DAWG) is in support of a transition to Proposed Recommendation for the SPARQL Protocol for RDF specification. In particular, it fulfills the following Candidate Recommendation exit criteria set forth in the 6 Apr 2006 CR publication of the specification:

Each identified SPARQL feature has at least two implementations.

Features

The SPARQL Protocol for RDF defines a WSDL 2.0 interface, SparqlQuery, as well as bindings of that interface for HTTP and SOAP. The SparqlQuery interface consists of one operation with one required in parameter, query and two optional, repeating parameters, default-graph-uri and named-graph-uri. The protocol also interacts with the SPARQL Query Language for RDF in several ways, including the definition of a query's dataset and the form (MIME type) of a query's results.

Based on the components of the SPARQL Protocol and its interactions with the other SPARQL specifications, the Working Group has identified the following features to be tested for interoperabilility:

In addition, the Working Group tested for the following features that are implementation-defined or are not required of conformant protocol implementations:

Testing Procedure

Because of the relatively lightweight nature of the SPARQL Protocol and because of time constraints that saw most DAWG testing effort go to the more complex SPARQL Query Language for RDF test suite and implementation report, protocol interoperability testing was performed to satisfy CR exit criteria, rather than to solicit information on all known SPARQL Protocol implementations. Most SPARQL Protocol implementations implement the HTTP bindings only, and so most tests were performed against the HTTP bindings. SOAP testing was performed to demonstrate interoperability of two known SOAP implementations of the SPARQL Protocol.

Tests were derived from the examples in sections 2.2.1 (HTTP) and 2.3.1 (SOAP) of the specification. For the HTTP tests, a python client issues test queries against designated endpoints, checking that both the response HTTP status code and the contents of the response are correct.

Because the QueryRequestRefused fault is an optional behavior under implementation-defined conditions, we have solicited information from implementors that make use of the fault.

Test Results

HTTP Bindings

Three implementations of the HTTP bindings for the SPARQL Protocol for RDF were tested:

The following table summarizes the results of testing. Green cells indicate that an implementation passed the test for a particular feature; yellow cells indicate that an implementation passed the test with caveats explained below; and red cells indicate that an implementation did not pass a particular test. The text in each cell is the HTTP status code received for the test, and the link is to the output received from the test.

Required tests for conformant implementations of the SPARQL Protocol HTTP Bindings
Joseki Algae AllegroGraph
Simple dataset 200 200 200
Complex dataset 200 200 200
Query dataset 200 200 200
Ambiguous dataset 200 200 200
ASK results 200 200 200
CONSTRUCT results 200 200 200
Malformed query 400 400 400

Implementation-defined or optional-behavior tests of the SPARQL Protocol HTTP bindings
Joseki Algae AllegroGraph
No dataset [1] 200 [1] 200 [1]
DESCRIBE results [2] 200 200 200

[1] Requires deployed endpoint specifically configured with test dataset.
[2] The DESCRIBE test assumes endpoints that return all the triples for which a given resource is the subject. Some common DESCRIBE approaches, such as returning a resource's Concise Bounded Description, satisfy this assumption, which is why the DESCRIBE interoperability test succeeded

SOAP Binding

Two implementations of the SOAP bindings for the SPARQL Protocol for RDF were tested:

Tests were limited to SOAP 1.1 and WSDL 1.1, using Virtuoso as the server and a prototype Joseki SOAP client.

Queries returned results in the SPARQL XML Results Set Format embedded in a valid SOAP reply. Both SELECT and CONSTRUCT query forms were tried successfully.

Further, the WSDL 2.0 service description has been compiled with Axis2 v1.3 to produce a valid skeleton for implementation.

Detailed HTTP Results

Joseki
Simple dataset

<?xml version="1.0"?>

<sparql

    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

    xmlns:xs="http://www.w3.org/2001/XMLSchema#"

    xmlns="http://www.w3.org/2005/sparql-results#" >

  <head>

    <variable name="book"/>

    <variable name="who"/>

  </head>

  <results>

    <result>

      <binding name="book">

        <uri>http://www.example/book/book3</uri>

      </binding>

      <binding name="who">

        <bnode>b0</bnode>

      </binding>

    </result>

    <result>

      <binding name="book">

        <uri>http://www.example/book/book2</uri>

      </binding>

      <binding name="who">

        <bnode>b0</bnode>

      </binding>

    </result>

    <result>

      <binding name="book">

        <uri>http://www.example/book/book1</uri>

      </binding>

      <binding name="who">

        <literal>J.K. Rowling</literal>

      </binding>

    </result>

  </results>

</sparql>

  
Complex dataset

<?xml version="1.0"?>

<sparql

    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

    xmlns:xs="http://www.w3.org/2001/XMLSchema#"

    xmlns="http://www.w3.org/2005/sparql-results#" >

  <head>

    <variable name="who"/>

    <variable name="g"/>

    <variable name="mbox"/>

  </head>

  <results>

    <result>

      <binding name="who">

        <literal>John</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-john.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:john@home.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>Susan</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-susan.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:susan@work.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>Bob</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-bob.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:bob@work.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>Alice</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-alice.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:alice@example.org</uri>

      </binding>

    </result>

  </results>

</sparql>

  
Query dataset

<?xml version="1.0"?>

<sparql

    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

    xmlns:xs="http://www.w3.org/2001/XMLSchema#"

    xmlns="http://www.w3.org/2005/sparql-results#" >

  <head>

    <variable name="who"/>

    <variable name="g"/>

    <variable name="mbox"/>

  </head>

  <results>

    <result>

      <binding name="who">

        <literal>Bob Hacker</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/queryonly-foaf-bob.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:bob@oldcorp.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>Alice Hacker</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/queryonly-foaf-alice.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:alice@work.example</uri>

      </binding>

    </result>

  </results>

</sparql>

  
Ambiguous dataset

<?xml version="1.0"?>

<sparql

    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

    xmlns:xs="http://www.w3.org/2001/XMLSchema#"

    xmlns="http://www.w3.org/2005/sparql-results#" >

  <head>

    <variable name="who"/>

    <variable name="g"/>

    <variable name="mbox"/>

  </head>

  <results>

    <result>

      <binding name="who">

        <literal>John Hacker</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/ambiguous-foaf-john.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:john@oldcorp.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>Susan Hacker</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/ambiguous-foaf-susan.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:susan@oldcorp.example</uri>

      </binding>

    </result>

  </results>

</sparql>

  
ASK results

<?xml version="1.0"?>

<sparql xmlns="http://www.w3.org/2005/sparql-results#">

  <head>

  </head>

  <boolean>true</boolean>

</sparql>

  
CONSTRUCT results

<?xml version="1.0"?>

<rdf:RDF

    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

    xmlns:foaf="http://xmlns.com/foaf/0.1/"

    xmlns:log="http://www.w3.org/2000/10/swap/log#"

    xmlns:myfoaf="http://www.example/jose/foaf.rdf#">

  <foaf:Person rdf:about="http://www.example/jose/foaf.rdf#juan">

    <foaf:mbox rdf:resource="mailto:juan@mail.example"/>

  </foaf:Person>

  <foaf:Person rdf:about="http://www.example/jose/foaf.rdf#jose">

    <foaf:knows rdf:resource="http://www.example/jose/foaf.rdf#juan"/>

    <foaf:nick>Jo</foaf:nick>

    <foaf:name>Jose Jime?z</foaf:name>

    <foaf:depiction rdf:resource="http://www.example/jose/jose.jpg"/>

    <foaf:schoolHomepage rdf:resource="http://www.edu.example/"/>

    <foaf:homepage rdf:resource="http://www.example/jose/"/>

    <foaf:workplaceHomepage rdf:resource="http://www.corp.example/"/>

  </foaf:Person>

</rdf:RDF>

  
Malformed query

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>

<title>Error 400 </title>

</head>

<body><h2>HTTP ERROR: 400</h2><pre>Parse error: 

PREFIX foaf: <http://xmlns.com/foaf/0.1/>

SELECT ?name

WHERE { ?x foaf:name ?name

ORDER BY ?name }





Encountered "ORDER" at line 4, column 1.

Was expecting one of:

    "graph" ...

    "optional" ...

    "service" ...

    "filter" ...

    "{" ...

    "}" ...

    ";" ...

    "," ...

    "." ...

    </pre>

<p>RequestURI=/sparql</p><p><i><small><a href="http://jetty.mortbay.org/">Powered by Jetty://</a></small></i></p><br/>                                                

<br/>                                                

<br/>                                                



<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                

<br/>                                                





</body>

</html>

  
DESCRIBE results

<?xml version="1.0"?>

<rdf:RDF

    xmlns:books="http://www.example/book/"

    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

    xmlns:vcard="http://www.w3.org/2001/vcard-rdf/3.0#"

    xmlns:dc="http://purl.org/dc/elements/1.1/"

    xmlns:ns="http://example.org/ns#"

    xmlns="http://example.org/book/">

  <rdf:Description rdf:about="http://www.example/book/book6">

    <dc:title>Example Book #6</dc:title>

  </rdf:Description>

</rdf:RDF>

  
Algae
Simple dataset

<sparql

 xmlns="http://www.w3.org/2005/sparql-results#">

   <head>

      <variable

       name="book" />

      <variable

       name="who" />

   </head>

   <results>

      <result>

         <binding

          name="book">

            <uri>http://www.example/book/book1</uri>

         </binding>

         <binding

          name="who">

            <literal>J.K. Rowling</literal>

         </binding>

      </result>

      <result>

         <binding

          name="book">

            <uri>http://www.example/book/book3</uri>

         </binding>

         <binding

          name="who">

            <bnode

             nodeId="r2" />

         </binding>

      </result>

      <result>

         <binding

          name="book">

            <uri>http://www.example/book/book2</uri>

         </binding>

         <binding

          name="who">

            <bnode

             nodeId="r2" />

         </binding>

      </result>

   </results>

</sparql>

  
Complex dataset

<sparql

 xmlns="http://www.w3.org/2005/sparql-results#">

   <head>

      <variable

       name="who" />

      <variable

       name="g" />

      <variable

       name="mbox" />

   </head>

   <results>

      <result>

         <binding

          name="who">

            <literal>John</literal>

         </binding>

         <binding

          name="g">

            <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-john.ttl</uri>

         </binding>

         <binding

          name="mbox">

            <uri>mailto:john@home.example</uri>

         </binding>

      </result>

      <result>

         <binding

          name="who">

            <literal>Susan</literal>

         </binding>

         <binding

          name="g">

            <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-susan.ttl</uri>

         </binding>

         <binding

          name="mbox">

            <uri>mailto:susan@work.example</uri>

         </binding>

      </result>

      <result>

         <binding

          name="who">

            <literal>Alice</literal>

         </binding>

         <binding

          name="g">

            <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-alice.ttl</uri>

         </binding>

         <binding

          name="mbox">

            <uri>mailto:alice@example.org</uri>

         </binding>

      </result>

      <result>

         <binding

          name="who">

            <literal>Bob</literal>

         </binding>

         <binding

          name="g">

            <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-bob.ttl</uri>

         </binding>

         <binding

          name="mbox">

            <uri>mailto:bob@work.example</uri>

         </binding>

      </result>

   </results>

</sparql>

  
Query dataset

<sparql

 xmlns="http://www.w3.org/2005/sparql-results#">

   <head>

      <variable

       name="who" />

      <variable

       name="g" />

      <variable

       name="mbox" />

   </head>

   <results>

      <result>

         <binding

          name="who">

            <literal>Bob Hacker</literal>

         </binding>

         <binding

          name="g">

            <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/queryonly-foaf-bob.ttl</uri>

         </binding>

         <binding

          name="mbox">

            <uri>mailto:bob@oldcorp.example</uri>

         </binding>

      </result>

      <result>

         <binding

          name="who">

            <literal>Alice Hacker</literal>

         </binding>

         <binding

          name="g">

            <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/queryonly-foaf-alice.ttl</uri>

         </binding>

         <binding

          name="mbox">

            <uri>mailto:alice@work.example</uri>

         </binding>

      </result>

   </results>

</sparql>

  
Ambiguous dataset

<sparql

 xmlns="http://www.w3.org/2005/sparql-results#">

   <head>

      <variable

       name="who" />

      <variable

       name="g" />

      <variable

       name="mbox" />

   </head>

   <results>

      <result>

         <binding

          name="who">

            <literal>John Hacker</literal>

         </binding>

         <binding

          name="g">

            <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/ambiguous-foaf-john.ttl</uri>

         </binding>

         <binding

          name="mbox">

            <uri>mailto:john@oldcorp.example</uri>

         </binding>

      </result>

      <result>

         <binding

          name="who">

            <literal>Susan Hacker</literal>

         </binding>

         <binding

          name="g">

            <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/ambiguous-foaf-susan.ttl</uri>

         </binding>

         <binding

          name="mbox">

            <uri>mailto:susan@oldcorp.example</uri>

         </binding>

      </result>

   </results>

</sparql>

  
ASK results

<sparql

 xmlns="http://www.w3.org/2005/sparql-results#">

   <head />

   <boolean>TRUE</boolean>

</sparql>  

  
CONSTRUCT results

<r:RDF

 xmlns:r="http://www.w3.org/1999/02/22-rdf-syntax-ns#">

   <foaf:Person

    xmlns:foaf="http://xmlns.com/foaf/0.1/"

    foaf:name="Jose Jime?z"

    foaf:nick="Jo"

    r:about="http://www.example/jose/foaf.rdf#jose">

      <foaf:depiction

       r:resource="http://www.example/jose/jose.jpg" />

      <foaf:homepage

       r:resource="http://www.example/jose/" />

      <foaf:knows>

         <foaf:Person

          r:about="http://www.example/jose/foaf.rdf#juan">

            <foaf:mbox

             r:resource="mailto:juan@mail.example" />

         </foaf:Person>

      </foaf:knows>

      <foaf:schoolHomepage

       r:resource="http://www.edu.example/" />

      <foaf:workplaceHomepage

       r:resource="http://www.corp.example/" />

   </foaf:Person>

</r:RDF>  

  
Malformed query

W3C::Util::DieException string context:

file:/home/.aristotle/figtree/dawg/proto-tests/data/select/refused-protein-db.n3:3:1(83)

ORDER BY ?name }

^expected "GT_LCURLEY | GT_RCURLEY | IT_FILTER | IT_GRAPH | IT_OPTIONAL", got (IT_ORDER, ORDER) from "ORDER" at offset 82.



W3C::Util::DieException thrown at ../../../W3C/Util/Exception.pm:113

W3C::Util::Exception::DieHandler(...) at SparqlParser.yp:1816

W3C::Rdf::_SparqlParser::_Error(...) at ../../../W3C/Util/YappDriver.pm:597

W3C::Util::YappDriver::__ANON__(...) at ../../../W3C/Util/YappDriver.pm:507

Parse::Yapp::Driver::_Parse(...) at ../../../W3C/Util/YappDriver.pm:180

Parse::Yapp::Driver::YYParse(...) at ../../../W3C/Util/YappDriver.pm:598

(eval) at ../../../W3C/Util/YappDriver.pm:596

W3C::Util::YappDriver::parse(...) at SparqlParser.yp:1910

W3C::Rdf::_SparqlParser::parse(...) at ../../../W3C/Rdf/Algae2.pm:149

W3C::Rdf::Algae2::interpret(...) at ./algae:640

algaeScript::_executeQuery(...) at ./algae:494

(eval) at ./algae:479

algaeScript::httpServer(...) at ./algae:398

algaeScript::execute(...) at ./algae:94

(eval) at ./algae:92  

  
DESCRIBE results

<r:RDF

 xmlns:r="http://www.w3.org/1999/02/22-rdf-syntax-ns#">

   <r:Description

    xmlns:dc="http://purl.org/dc/elements/1.1/"

    dc:title="Example Book #6"

    r:about="http://www.example/book/book6" />

</r:RDF>  

  
No dataset

  
AllegroGraph
Simple dataset

<?xml version="1.0"?>

<sparql xmlns="http://www.w3.org/2005/sparql-results#">

  <head>

    <variable name="book"/>

    <variable name="who"/>

  </head>

  <results>

    <result>

      <binding name="book">

        <uri>http://www.example/book/book1</uri>

      </binding>

      <binding name="who">

        <literal>J.K. Rowling</literal>

      </binding>

    </result>

    <result>

      <binding name="book">

        <uri>http://www.example/book/book3</uri>

      </binding>

      <binding name="who">

        <bnode>262</bnode>

      </binding>

    </result>

    <result>

      <binding name="book">

        <uri>http://www.example/book/book2</uri>

      </binding>

      <binding name="who">

        <bnode>262</bnode>

      </binding>

    </result>

  </results>

</sparql>

  
Complex dataset

<?xml version="1.0"?>

<sparql xmlns="http://www.w3.org/2005/sparql-results#">

  <head>

    <variable name="who"/>

    <variable name="g"/>

    <variable name="mbox"/>

  </head>

  <results>

    <result>

      <binding name="who">

        <literal>Alice</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-alice.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:alice@example.org</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>Bob</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-bob.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:bob@work.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>John</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-john.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:john@home.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>Susan</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/complex-foaf-susan.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:susan@work.example</uri>

      </binding>

    </result>

  </results>

</sparql>

  
Query dataset

<?xml version="1.0"?>

<sparql xmlns="http://www.w3.org/2005/sparql-results#">

  <head>

    <variable name="who"/>

    <variable name="g"/>

    <variable name="mbox"/>

  </head>

  <results>

    <result>

      <binding name="who">

        <literal>Alice Hacker</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/queryonly-foaf-alice.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:alice@work.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>Bob Hacker</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/queryonly-foaf-bob.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:bob@oldcorp.example</uri>

      </binding>

    </result>

  </results>

</sparql>

  
Ambiguous dataset

<?xml version="1.0"?>

<sparql xmlns="http://www.w3.org/2005/sparql-results#">

  <head>

    <variable name="who"/>

    <variable name="g"/>

    <variable name="mbox"/>

  </head>

  <results>

    <result>

      <binding name="who">

        <literal>Susan Hacker</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/ambiguous-foaf-susan.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:susan@oldcorp.example</uri>

      </binding>

    </result>

    <result>

      <binding name="who">

        <literal>John Hacker</literal>

      </binding>

      <binding name="g">

        <uri>http://www.w3.org/2001/sw/DataAccess/proto-tests/data/select/ambiguous-foaf-john.ttl</uri>

      </binding>

      <binding name="mbox">

        <uri>mailto:john@oldcorp.example</uri>

      </binding>

    </result>

  </results>

</sparql>

  
ASK results

<?xml version="1.0"?>

<sparql xmlns="http://www.w3.org/2005/sparql-results#">

  <head/>

  <boolean>true</boolean>

</sparql>

  
CONSTRUCT results

<?xml version="1.0"?>

<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

     xmlns:owl="http://www.w3.org/2002/07/owl#"

     xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"

     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

     xmlns:ns1="http://xmlns.com/foaf/0.1/"

     xmlns:err="http://www.w3.org/2005/xqt-errors#"

     xmlns:fn="http://www.w3.org/2005/xpath-functions#"

     xmlns:xs="http://www.w3.org/2001/XMLSchema#">

  <Description rdf:about="http://www.example/jose/foaf.rdf#juan">

    <ns1:mbox rdf:resource="mailto:juan@mail.example"/>

    <rdf:type rdf:resource="http://xmlns.com/foaf/0.1/Person"/>

  </Description>

  <Description rdf:about="http://www.example/jose/foaf.rdf#jose">

    <ns1:workplaceHomepage rdf:resource="http://www.corp.example/"/>

    <ns1:nick>Jo</ns1:nick>

    <ns1:name>Jose Jime?z</ns1:name>

    <ns1:knows rdf:resource="http://www.example/jose/foaf.rdf#juan"/>

    <ns1:homepage rdf:resource="http://www.example/jose/"/>

    <rdf:type rdf:resource="http://xmlns.com/foaf/0.1/Person"/>

    <ns1:schoolHomepage rdf:resource="http://www.edu.example/"/>

    <ns1:depiction rdf:resource="http://www.example/jose/jose.jpg"/>

  </Description>

</RDF>

  
Malformed query

Malformed query/bad request: Parse error: unexpected terminal order (value: :order).

Expected terminals:

(blank_node_label q_iri_ref a varname [] [ qname qname_ns , ; filter . graph optional { } integer-negative string_literal2 double-positive ( double-negative integer-positive

 decimal-positive double ) integer false true decimal decimal-negative string_literal_long1 nil-symbol string_literal1 string_literal_long2 ]).

  
DESCRIBE results

<?xml version="1.0"?>

<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

     xmlns:owl="http://www.w3.org/2002/07/owl#"

     xmlns:ns1="http://purl.org/dc/elements/1.1/"

     xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"

     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"

     xmlns:err="http://www.w3.org/2005/xqt-errors#"

     xmlns:fn="http://www.w3.org/2005/xpath-functions#"

     xmlns:xs="http://www.w3.org/2001/XMLSchema#">

  <Description rdf:about="http://www.example/book/book6">

    <ns1:title>Example Book #6</ns1:title>

  </Description>

</RDF>

  
No dataset

<?xml version="1.0"?>

<sparql xmlns="http://www.w3.org/2005/sparql-results#">

  <head>

    <variable name="book"/>

    <variable name="who"/>

  </head>

  <results>

    <result>

      <binding name="book">

        <uri>http://www.example/book/book5</uri>

      </binding>

      <binding name="who">

        <bnode>272</bnode>

      </binding>

    </result>

    <result>

      <binding name="book">

        <uri>http://www.example/book/book6</uri>

      </binding>

      <binding name="who">

        <bnode>274</bnode>

      </binding>

    </result>

  </results>

</sparql>

  

QueryRequestRefused fault

Both Joseki and AllegroGraph make use of the QueryRequestRefused fault. Joseki will refuse queries for a myriad of reasons, including refusal to access a graph on the local filesystem. AllegroGraph makes use of the fault to reflect the fact that the underlying triple store is not in a state to answer a particular query. Further uses of the QueryRequestRefused fault are expected, as AllegroGraph implementor Richard Newman commented:

There is a whole space of query (e.g., queries with inference that include ?s ?p ?o) that an endpoint should be allowed to refuse without asserting that the query is invalid.