Warning: This document is for an old version of RDFox. The latest version is 7.1.

2. RDFox Features and Requirements

2.1. RDFox Features

RDFox provides the following main functionality:

  • RDFox can import RDF triples, rules, and OWL 2 and SWRL axioms either programmatically or from files of certain formats (see Section 3 for a quick introduction). RDF data can be validated using the SHACL constraint language. Additionally, RDFox can access information from external data sources, such as CSV files, relational databases, or Apache Solr (see Section 10).

  • Triples, rules and axioms can be exported into a number of different formats. Furthermore, the contents of the system can be incrementally saved into a binary file, which can later be loaded to restore the system’s state.

  • RDFox supports ACID transactional updates (see Section 12 for further details on transactions).

  • Individual information elements in the system can be assigned different access permissions for different users (see Section 11 for further details on access control).

  • RDFox can answer SPARQL 1.1 queries (see Section 5) and provides functionality for monitoring query answering and accessing query plans.

  • RDFox supports materialization-based reasoning, where all triples that logically follow from the facts and rules in the system are materialized as new triples (see Section 6) . Materializations can be incrementally updated, which means that reasoning does not need to be performed from scratch once the information in the system is updated. Furthermore, the results of reasoning can be explained, which means that RDFox is able to return proofs for any new fact added to the store through materialization.

2.2. Software Archive

RDFox is distributed as an archive containing the following files and directories:

  • RDFox (macOS/Linux) or RDFox.exe (Windows): a stand-alone executable that can be used to run RDFox on the command line.

  • lib: a directory containing the following libraries:

    • JRDFox.jar: the Java bridge to the native RDFox engine.

    • libRDFox.dylib (macOS), libRDFox.so (Linux), or libRDFox.dll (Windows): a dynamic library that implements the native methods of JRDFox.

    • libRDFox.lib (Windows only): the import library needed for linking libRDFox.dll on Windows.

  • include: a directory containing definitions for an EXPERIMENTAL C API. The definitions include C++ classes that can be used to make it easier to correctly manage the resources exposed by the C API within C++ applications.

  • examples: a directory containing demonstration programs that show how to call RDFox as a library.

    • C: a directory containing a C source file demonstrating how to call RDFox via the experimental C API and a script (compile-and-run.sh on macOS and Linux; compile-and-run.bat on Windows) to build and run the demo. On macOS and Linux, the script assumes a C-99 compliant version of gcc is available on the path. On Windows, the script assumes that vcvars64.bat has been executed in the shell prior to execution.

    • C++: a directory containing a C++ source file demonstrating how to call RDFox via the C++ wrapper for the experimental C API and a script (compile-and-run.sh on macOS and Linux, compile-and-run.bat on Windows) to build and run the demo. On macOS and Linux, the script assumes a version of g++ supporting C++11 is available on the path. On Windows, the script assumes that vcvars64.bat has been executed in the shell prior to execution.

    • Java: a directory containing source code for a program demonstrating how to call RDFox via the JRDFox API. The examples/Java/build.xml Apache Ant script can be used to compile and run the program.

2.3. Interfaces

Users and developers can interact with RDFox through the following interfaces:

CLI

RDFox comes with a built-in shell that can be used to interact with and control the RDFox Server. The shell can be launched together with an RDFox Server instance using the shell or sandbox modes of the executable. Alternatively the remote executable mode (currently an EXPERIMENTAL feature) can be used to connect to and use the shell interface of a remote RDFox Server. See Section 16 for details.

RESTful API

When RDFox’s endpoint is running, clients can interact with the associated RDFox server via a RESTful API. For details of how to configure and start the endpoint, see Section 13. For details of the RESTful API, see Section 14.

Java API

RDFox can be embedded into Java applications and called via the Java API described in Section 14 and Section 15. To use JRDFox in your project, simply add JRDFox.jar to your classpath, and make sure that the path to the dynamic library is correctly specified when starting your program using the following JVM option:

-Djava.library.path=<path to the dynamic library>
C API (EXPERIMENTAL)

RDFox can be dynamically loaded and called through a C API.

GUI (EXPERIMENTAL)

As well as serving the REST API, the RDFox endpoint serves the RDFox Console, an experimental graphical browser application supporting basic querying and visualization of data store content. When the endpoint is running, the Console can be loaded by visiting http[s]:<hostname>:<port>/console/ where <hostname> and <port> are the host name and port number at which the endpoint can be reached.

2.4. System Requirements

2.4.1. Operating Systems

RDFox supports the following operating system versions:

Windows

Windows 8 or higher

Mac

macOS 10.14 or higher

Linux
  • Centos 7 or higher

  • Ubuntu 16.04 or higher

  • Fedora 27 or higher

Additionally, RDFox can be run using Docker. See Section 18 for details.

2.4.2. Hardware

RDFox is a main-memory data store and as such its performance is heavily dependent on access to a suitable amount of RAM. Oxford Semantic Technologies recommends that users ensure that RDFox has unpaged access to between 60 and 110 bytes of RAM per triple that their store will contain. This includes both explicitly imported triples and those materialized via reasoning.

2.4.3. License Key

Creating an RDFox Server requires a time-limited license key issued by Oxford Semantic Technologies. At server creation time, RDFox will search the following locations, in the order shown, for the license key:

  • the value of the license-content server parameter, if set

  • [RDFox executable only] the value of the RDFOX_LICENSE_CONTENT environment variable, if set

  • the content of the file specified via license-file server parameter, if set

  • [RDFox executable only] the content of the file specified via the RDFOX_LICENSE_FILE environment variable, if set

  • [RDFox executable only] the content of the file RDFox.lic in the directory containing the running executable, if the file exists

  • the content of the file RDFox.lic in the configured server directory, if the file exists

If a candidate key is found in one location, the remaining locations will not be checked even if the candidate turns out to be invalid or expired.

See Section 16.1 for details of how to specify server parameters when starting the RDFox executable. When using JRDFox, server parameters must be specified via tech.oxfordsemantic.jrdfox.client.ConnectionFactory.startLocalServer(...). For example:

Map<String, String> serverParams = new HashMap<>();
serverParams.put("license-file", "/home/user/rdfox.lic");
ConnectionFactory.startLocalServer(serverParams);