VDS has a query type called query-by-definition. Basically, it is a search by string matching. For instance, VDS supports to find a transformation that contains a certain string. The VDS transformation will be transformed to a WSDL description, and then be published into Grimoires. Therefore, the above query is equivalent to a Grimoires query operation of finding a WSDL description that contains a certain string. This operation is not supported in Grimoires currently.
UDDI does not support to find an entity by its description, or to find an entity that contains some keywords inside its description.
We introduce an RDF API in Grimoires, which allows users to query for triples directly by using a RDF query langauge. Currently only RDQL is supported. Since all the published information in Grimoires is represented in the form of RDF triples, the RDF API provides a flexible inquiry mechanism that fully exposes the expressiveness of RDF.
The WSDL description of the RDF API is as follows:
<?xml version="1.0" encoding="UTF-8"?> <wsdl:definitions name="rdf" targetNamespace="http://www.grimoires.org/rdf" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://www.grimoires.org/rdf" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <wsdl:types> <xsd:schema targetNamespace="http://www.grimoires.org/rdf" xmlns:tns="http://www.grimoires.org/rdf"> <xsd:element name="inquireRequest" type="tns:inquireRequest" /> <xsd:complexType name="inquireRequest"> <xsd:sequence> <xsd:element name="language" type="xsd:string" /> <xsd:element name="clause" type="xsd:string" /> </xsd:sequence> </xsd:complexType> <xsd:element name="inquireResponse" type="tns:inquireResponse" /> <xsd:complexType name="inquireResponse"> <xsd:sequence> <xsd:element name="header" type="tns:record"/> <xsd:element name="record" type="tns:record" minOccurs="0" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> <xsd:complexType name="record"> <xsd:sequence> <xsd:element name="field" type="xsd:string" minOccurs="1" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:schema> </wsdl:types> <wsdl:message name="inquireResponse"> <wsdl:part element="tns:inquireResponse" name="inquireResponse" /> </wsdl:message> <wsdl:message name="inquireRequest"> <wsdl:part element="tns:inquireRequest" name="inquireRequest" /> </wsdl:message> <wsdl:portType name="RDF"> <wsdl:operation name="inquire"> <wsdl:input message="tns:inquireRequest" /> <wsdl:output message="tns:inquireResponse" /> </wsdl:operation> </wsdl:portType> </wsdl:definition>
In the input message of the inquire operation, the "language" has a pre-defined value "RDQL", and the "clause" is the RDF query clause in RDQL. In the output message of the inquire operation, the "header" is a string array that contains all the selected variables in the RDQL clause, and the "record" is a sequence of all matched bindings.
For instance, the following example inquires for the name and key of all published businesses. The request message is:
<?xml version="1.0" encoding="UTF-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <soapenv:Body> <inquireRequest xmlns="http://www.grimoires.org/rdf"> <language>RDQL</language> <clause>SELECT ?businessName ?businessKey WHERE (?business <rdf:type> <uddi:BusinessEntity>) (?business <uddi:hasBusinessKey> ?businessKey) (?business <uddi:hasName> ?nameBag) (?nameBag <rdf:_1> ?businessName) USING rdf FOR <http://www.w3.org/1999/02/22-rdf-syntax-ns#>, uddi FOR <http://www.mygrid.ecs.soton.ac.uk/uddiv2.rdfs#>, metadata FOR <http://www.mygrid.ecs.soton.ac.uk/metadata.rdfs#>, wsdl FOR <http://www.mygrid.ecs.soton.ac.uk/wsdl.rdfs#>
</clause> </inquireRequest> </soapenv:Body> </soapenv:Envelope>The response message is:
<?xml version="1.0" encoding="utf-8"?> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <soapenv:Body> <inquireResponse xmlns="http://www.grimoires.org/rdf"> <header> <field>businessName</field> <field>businessKey</field> </header> <record> <field>Quality Quidditch Supplies</field> <field>d6ff1e8a-0eee-4e68-913a-74fa14951090</field> </record> <record> <field>Quality Quidditch Supplies</field> <field>e67d836f-d8fc-41a5-ac9d-96ca5ef9bbb5</field> </record> </inquireResponse> </soapenv:Body> </soapenv:Envelope>
The RDF API is intended to be used by Grimoires developer instead of Grimoires users. To compose the RDF query clause, the knowledge on the RDF schema used in Grimoires is required. Users are not required to have such knowledge. However, by exposing the RDF API, the Grimoires developer has the flexibility to implement free form queries that can not be addressed by current query templates through writing client side utilities of the RDF API. For instance, the two use cases mentioned above can be addressed by writing some client side utilities of the RDF API.