You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/sail/index.adoc
+17-6Lines changed: 17 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -66,8 +66,7 @@ Sail "1" *- "*" SailConnection
66
66
67
67
....
68
68
69
-
In diagram <<figure-sail-main>> we see an overview of the two main interfaces: `Sail`, and `SailConnection`. Although SAIL is not a JDBC implementation, its design is inspired by it.
70
-
The `Sail` interface is the main access point for RDF storage. Roughly speaking, this is "the database". Each `Sail` object is composed of zero or more `SailConnection` objects. This is where all the actual database access functionality is concentrated. `SailConnection` provides methods to execute queries, retrieve and modify triples, and manage transactions.
69
+
In diagram <<figure-sail-main>> we see an overview of the two main interfaces: `Sail`, and `SailConnection`. The `Sail` interface is the main access point for RDF storage. Roughly speaking, this is "the database". Each `Sail` object is composed of zero or more `SailConnection` objects. This is where all the actual database access functionality is concentrated. `SailConnection` provides methods to execute queries, retrieve and modify triples, and manage transactions.
71
70
72
71
=== AbstractSail and AbstractSailConnection
73
72
@@ -235,16 +234,28 @@ More fine-grained event data is available at the Connection level. The `Notifyin
235
234
RDF4J also provides base implementation classes for these two interfaces. As can be seen in diagram <<figure-notifying-sail>>, these classes - `AbstractNotifyingSail` and `AbstractNotifyingSailConnection` - are extensions of the AbstractSail(Connection) classes that add
236
235
default implementations of the methods defined in the NotifyingSail(Connection) interfaces.
237
236
238
-
=== StackableSail
237
+
=== Stacking SAILs
239
238
240
-
TODO
239
+
.Stackable SAIL interface
240
+
[[figure-stackable-sail]]
241
+
[plantuml, diagram-stackable-sail, png]
242
+
....
243
+
interface Sail
244
+
interface StackableSail {
245
+
+ setBaseSail(Sail)
246
+
+ getBaseSail()
247
+
}
248
+
249
+
Sail <|-- StackableSail
250
+
....
251
+
252
+
The SAIL API provides the `StackableSail` interface to allow SAIL implementations to "stack" on top of each other, providing a chain of responsility: each SAIL implementation in the stack implements a specific feature (reasoning, access control, data filtering, query expansion, etc. etc.). The last SAIL implementation in the stack is expected to _not_ implement `StackableSail`, and this Sail is responsible for the actual persistence of the data. RDF4J's `NativeStore` and `MemoryStore` are implementations of such a persistence SAIL, while the `ForwardChainingRDFSInferencer` (responsible for RDFS inferencing) and `LuceneSail` (responsible for full-text indexing) are examples of `StackableSail` implementations.
241
253
242
254
== Querying
243
255
244
256
The SAIL API has no knowledge of SPARQL queries. Instead, it operates on a query algebra, that is, an object representation of a (SPARQL) query as provided by the SPARQL query parser.
245
257
246
-
`SailConnection` has a single `evaluate()` method, which accepts a `TupleExpr` object. This is the object representation of the query as produced by the query parser.
247
-
258
+
`SailConnection` has a single `evaluate()` method, which accepts a `org.eclipse.rdf4j.queryalgebra.model.TupleExpr` object. This is the object representation of the query as produced by the query parser.
0 commit comments