Class EndpointManager


  • public class EndpointManager
    extends Object
    EndpointManager is the singleton instance that manages available Endpoints. Particular endpoints can be looked up by their id and connection and all relevant information can be used.
    Author:
    Andreas Schwarte
    • Field Detail

      • log

        protected static final org.slf4j.Logger log
      • inRepair

        protected boolean inRepair
      • lastRepaired

        protected Long lastRepaired
    • Method Detail

      • initialize

        public static EndpointManager initialize​(List<Endpoint> endpoints)
        Initialize the singleton endpoint manager with the provided endpoints
        Parameters:
        endpoints -
      • addEndpoint

        public void addEndpoint​(Endpoint e)
        Add the (initialized) endpoint to this endpoint manager to be used by the FederationManager.
        Parameters:
        e - the endpoint
      • getAvailableEndpoints

        public Collection<Endpoint> getAvailableEndpoints()
        Returns:
        a collection of available endpoints in this endpoint manager
      • getEndpoint

        public Endpoint getEndpoint​(String endpointID)
        Parameters:
        endpointID -
        Returns:
        the endpoint corresponding to the provided id or null
      • getEndpointByUrl

        public Endpoint getEndpointByUrl​(String endpointUrl)
        Return the Endpoint for the provided endpoint url, if it exists. Otherwise return null.
        Parameters:
        endpointUrl -
        Returns:
        the endpoint by its URL
      • getEndpointByName

        public Endpoint getEndpointByName​(String endpointName)