Class SourceSelection
java.lang.Object
org.eclipse.rdf4j.federated.optimizer.SourceSelection
Perform source selection during optimization
- Author:
- Andreas Schwarte
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected classprotected static classTask for sending an ASK request to the endpoints (for source selection)protected static class -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final SourceSelectionCacheprotected final QueryInfoprotected Map<StatementPattern,List<StatementSource>> Map statements to their sources. -
Constructor Summary
ConstructorsConstructorDescriptionSourceSelection(List<Endpoint> endpoints, SourceSelectionCache cache, QueryInfo queryInfo) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddSource(StatementPattern stmt, StatementSource source) Add a source to the given statement in the map (synchronized through map)voiddoSourceSelection(List<StatementPattern> stmts) Perform source selection for the provided statements using cache or remote ASK queries.Retrieve a set of relevant sources for this query.
-
Field Details
-
endpoints
-
cache
-
queryInfo
-
stmtToSources
Map statements to their sources. Use synchronized access!
-
-
Constructor Details
-
SourceSelection
-
-
Method Details
-
doSourceSelection
Perform source selection for the provided statements using cache or remote ASK queries. Remote ASK queries are evaluated in parallel using the concurrency infrastructure of FedX. Note, that this method is blocking until every source is resolved. The statement patterns are replaced by appropriate annotations in this optimization.- Parameters:
stmts-
-
getRelevantSources
Retrieve a set of relevant sources for this query.- Returns:
- the relevant sources
-
addSource
Add a source to the given statement in the map (synchronized through map)- Parameters:
stmt-source-
-