How the Repository configuration template works

What’s in this document?

The diagram below provides an illustration of an RDF graph that describes a repository configuration:

_images/sesame_owlim_config.png

Often, it is helpful to ensure that a repository starts with a predefined set of RDF statements — usually one or more schema graphs. This is possible by using the graphdb:imports property. After start-up, these files are parsed and their contents are permanently added to the repository.

In short, the configuration is an RDF graph, where the root node is of rdf:type rep:Repository, and it must be connected through the rep:RepositoryID property to a Literal that contains the human readable name of the repository. The root node must be connected via the rep:repositoryImpl property to a node that describes the configuration.

GraphDB repository

The type of the repository is defined via the rep:repositoryType property and its value must be graphdb:SailRepository to let RDF4J know what the desired Sail repository implementation is. Then, a node that specifies the Sail implementation to be instantiated must be connected through the sr:sailImpl property. To instantiate GraphDB, this last node must have a property sail:sailType with the value graphdb:Sail — the RDF4J framework will locate the correct SailFactory within the application classpath that will be used to instantiate the Java implementation class.

The prefixes used above represent the following namespaces:

rep: <http://www.openrdf.org/config/repository#>
sr: <http://www.openrdf.org/config/repository/sail#>
sail: <http://www.openrdf.org/config/sail#>
graphdb: <http://www.ontotext.com/trree/graphdb#>

All properties used to specify the GraphDB configuration parameters use the graphdb: prefix and the local names match up with the configuration parameters. For example, the value of the ruleset parameter can be specified using the graphdb:ruleset property.