Web User Interface
Web Services
A default configuration for a standalone Mulgara server runs a set of web services, including the Web User Interface. Once Mulgara has been started, the standard configuration puts uses port 8080, so the web services can be seen by pointing a browser on the server running Mulgara to http://localhost:8080/. Of course, when talking to Mulgara running on a remote host computer, then use that computer's name or IP rather than localhost.
The list of services in the default configuration is:
- SPARQL HTTP Service
- User Interface
- Web Services
- TQL HTTP Service
- User Tutorial
Tutorial
The tutorial is a set of pre-defined queries that demonstrate how to use Mulgara using TQL commands (TQL pre-dates SPARQL, and includes commands for modifying data). In the default configuration it will be at: http://localhost:8080/tutorial/. It should appear as shown here:
To go through the tutorial, select from the list of Example Queries, and press Submit Query. The queries are in the following order:
- Create a graph.
- Load RSS data into the graph.
- List everything in the graph.
- List the news articles.
- Create a standalone RDF schema graph.
- Load in the referenced schemas.
- List this RSS properties using both graphs.
- Drop the graphs.
While it is possible to select these out of order, the suggested order will ensure that all required data is available when requested. If a selection is done from a non-existent graph, and error page will be shown. In this case, press the "Back" button on your browser and try another query. You are not restricted to the queries in the list, and tutorial will accept both TQL and SPARQL queries.
The data loaded in this tutorial comes from the Mulgara Jar files, and should always be available.
User Interface
The User Interface link is directed at http://localhost:8080/webui. When you first start the page, it should appear as below:
General Use
While the tutorial supplies a set of example queries, the Web UI page is used for general access to a Mulgara database. All queries and commands are taken from the Query Text box, and all responses are rendered to the page. Note that this is not the web interface to use for XML or JSON responses. Use the SPARQL HTTP interface and the TQL HTTP interfaces for these.
The fields on the page are described here:
Graph URI
If the Query Text field contains a query that returns a set of results that includes RDF resources, then each resource will be linked to a query for that resource in the graph provided here.
e.g. If this field contains <foo:bar>, and a query is submitted that provides <foo:data:baz> in the results, then this URI will be linked to a query for all details about <foo:data:baz> in the graph <foo:bar>.
SPARQL Only: If the Query Text field contains a SPARQL query, then this field provides the default graph for the query. If the query is not SPARQL, or has an explicit FROM clause, then this field is ignored.
Query Text
This contains a single command or query in either TQL or SPARQL.
SPARQL is currently a query-only language, and will always give a result set as a response.
TQL is a query and update language. SELECT queries will give a result set as a response. All other queries will give a text string indicating the server response to the command.
File
This is used to select a file containing an RDF graph for uploading to a server. Use the Browse... button to find the file with a file selection dialog window.
When Upload is pressed, the file will be sent to the server and loaded into the graph specified in the Graph URI field. If this graph does not exist, then it will be created automatically.
Changes from previous version
This describes changes from previous versions of the Web UI.
- The Query box now autodetects SPARQL. This lets you type any SPARQL query, and it will execute as normal. We are still working on 100% SPARQL compliance, but this has been steadily improving all year. TQL commands and queries still work exactly the same, so if you never use SPARQL you will not see the difference.
- Graph URIs need no longer look like: rmi://host/server#name
Instead, any valid absolute URI can be used (relative URIs are
coming). This means you can create and use graphs with names like:
** http://yourdomain.com/mydata
** urn:www.agxml.org:schemas:all:2:0
** foo:bar
If you create a graph with a given URI then you can insert and select
from it as usual. Mulgara also offers the option of querying graphs
that you haven't defined. If the URI of the graph is a URL that
Mulgara understands, then it will attempt to retrieve data from that
source and interpret it accordingly (through the mechanism we call
"Resolvers"). For instance, you can find out the all the classes in
RDF by querying the ontology published at the location described in
the RDF namespace URL:
select $class from <http://www.w3.org/1999/02/22-rdf-syntax-ns> where $class <rdf:type> <rdfs:Class>;
- The Graph URI field is now used as the default graph for
SPARQL queries. This field is initially set for the "Example Queries",
and has always been used as a location for resources returned from a
query, allowing URIs in results to be linked to queries about those
resources. While this has not changed, SPARQL queries which do not
define a FROM clause will also use this field as the location for the
data being queried. When combined with the URL resolution above, this
makes it easy to do things like testing the DAWG test cases, such as
the one at:
http://www.w3.org/2001/sw/DataAccess/tests/r2#dawg-triple-pattern-003
Set the Graph URI to:
http://www.w3.org/2001/sw/DataAccess/tests/data-r2/triple-match/data-02.ttl
Type the test query into the Query Text field:
SELECT * WHERE { ?a ?a ?b . }The results are then rendered in the WebUI table layout.
- Graph URIs may now be relative. This means that rmi://host/server#name can now be expressed as #name.
- In the past, graphs on other servers were always referenced with URLs using the rmi protocol. This restricted remote graphs to those which were relative to the server, like rmi://host/server#name. Now any graph can be referenced by using it as a graph parameter in the query on a server URL. For instance, the graph foo:bar on host/server becomes: rmi://host/server?graph=foo%3Abar.
Attachments
- WebUI.png (42.4 kB) -
Image of WebUI web page
, added by pag on 10/30/08 20:28:14. - WebUI-screenshot.png (38.9 kB) -
Screenshot of new WebUI
, added by pag on 12/06/08 11:49:05.


