java.lang.Object
org.apache.jena.sparql.service.ServiceExecutorRegistry
Registry for service executors that can be extended with custom ones.
Bulk and single (=non-bulk) executors are maintained in two separate lists.
Default execution will always start with the bulk list first.
Once that list is exhausted by means of all bulk executors having delegated the request,
then the non-bulk ones will be considered.
There is no need to explicitly register a bulk-to-non-bulk bridge.
-
Field Summary
Modifier and TypeFieldDescriptionstatic ServiceExecutor
A "call with SPARQL query" service executor. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionWraps the given service executor as a chaining one and prepends it to the non-bulk chain viaaddSingleLink(ChainingServiceExecutor)
Add a chaining bulk executor as a link to the executor chainPrepend the given service executor as a link to the per-binding chainstatic ServiceExecutorRegistry
chooseRegistry
(Context context) Return the registry from the given context if present; otherwise return the global onecopy()
Create an independent copy of the registryReturn a copy of the registry in the context (if present) or a fresh instancestatic ServiceExecutorRegistry
Copies the origin registry into a new one, or makes a fresh instance if the specified registry isnull
.static QueryIterator
exec
(QueryIterator input, OpService opService, ExecutionContext execCxt) Deprecated, for removal: This API element is subject to removal in a future version.To be removed.static ServiceExecutorRegistry
get()
Return the global instance from the ARQ context; create that instance if needed.static ServiceExecutorRegistry
Return the registry from the given context only; null if there is noneRetrieve the actual list of bulk executors; allows for re-orderingRetrieve the actual list of per-binding executors; allows for re-orderingstatic void
init()
static void
initWithDefaults
(ServiceExecutorRegistry registry) Blindly adds the default executor(s); concretely adds the http executorRemove a given service executor - internally attempts to unwrap every chaining service executorRemove the given service executorRemove the given service executor from the per-binding chainstatic void
set
(Context context, ServiceExecutorRegistry reg) static ServiceExecutorRegistry
-
Field Details
-
httpService
A "call with SPARQL query" service executor.
-
-
Constructor Details
-
ServiceExecutorRegistry
public ServiceExecutorRegistry()
-
-
Method Details
-
standardRegistry
-
initWithDefaults
Blindly adds the default executor(s); concretely adds the http executor -
init
public static void init() -
get
Return the global instance from the ARQ context; create that instance if needed. Never returns null. -
chooseRegistry
Return the registry from the given context if present; otherwise return the global one -
get
Return the registry from the given context only; null if there is none -
set
-
createFrom
Copies the origin registry into a new one, or makes a fresh instance if the specified registry isnull
.- Parameters:
from
-ServiceExecutorRegistry
ornull
- Returns:
ServiceExecutorRegistry
a new instance
-
addSingleLink
Prepend the given service executor as a link to the per-binding chain -
removeSingleLink
Remove the given service executor from the per-binding chain -
add
Wraps the given service executor as a chaining one and prepends it to the non-bulk chain viaaddSingleLink(ChainingServiceExecutor)
-
remove
Remove a given service executor - internally attempts to unwrap every chaining service executor -
getSingleChain
Retrieve the actual list of per-binding executors; allows for re-ordering -
addBulkLink
Add a chaining bulk executor as a link to the executor chain -
removeBulkLink
Remove the given service executor -
getBulkChain
Retrieve the actual list of bulk executors; allows for re-ordering -
copy
Create an independent copy of the registry -
copyFrom
Return a copy of the registry in the context (if present) or a fresh instance -
exec
@Deprecated(forRemoval=true, since="4.9.0") public static QueryIterator exec(QueryIterator input, OpService opService, ExecutionContext execCxt) Deprecated, for removal: This API element is subject to removal in a future version.Execution
-