Package org.eclipse.rdf4j.federated
Class EndpointManager
java.lang.Object
org.eclipse.rdf4j.federated.EndpointManager
EndpointManager is the singleton instance that manages available
Endpoint
s. Particular endpoints can be
looked up by their id and connection and all relevant information can be used.- Author:
- Andreas Schwarte
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Add the (initialized) endpoint to this endpoint manager to be used by theFederationManager
.getEndpoint
(String endpointID) getEndpointByName
(String endpointName) getEndpointByUrl
(String endpointUrl) Return the Endpoint for the provided endpoint url, if it exists.getEndpoints
(Set<String> endpointIDs) static EndpointManager
initialize
(List<Endpoint> endpoints) Initialize the singleton endpoint manager with the provided endpointsprotected void
Remove the provided endpoint from this endpoint manager to be used by theFederationManager
.
-
Field Details
-
log
protected static final org.slf4j.Logger log -
endpoints
-
inRepair
protected boolean inRepair -
lastRepaired
-
-
Method Details
-
initialize
Initialize the singleton endpoint manager with the provided endpoints- Parameters:
endpoints
-
-
addEndpoint
Add the (initialized) endpoint to this endpoint manager to be used by theFederationManager
.- Parameters:
e
- the endpoint
-
removeEndpoint
Remove the provided endpoint from this endpoint manager to be used by theFederationManager
. In addition, this method unregisters theFederatedService
from RDF4J.- Parameters:
e
- the endpoint- Throws:
NoSuchElementException
- if there is no mapping for some endpoint id
-
getAvailableEndpoints
- Returns:
- a collection of available endpoints in this endpoint manager
-
getEndpoint
- Parameters:
endpointID
-- Returns:
- the endpoint corresponding to the provided id or null
-
getEndpointByUrl
Return the Endpoint for the provided endpoint url, if it exists. Otherwise return null.- Parameters:
endpointUrl
-- Returns:
- the endpoint by its URL
-
getEndpointByName
-
getEndpoints
- Parameters:
endpointIDs
-- Returns:
- a list of endpoints corresponding to the provided ids
- Throws:
NoSuchElementException
- if there is no mapping for some endpoint id
-