Package org.apache.solr.rest
Class RestManager.Registry
java.lang.Object
org.apache.solr.rest.RestManager.Registry
- Enclosing class:
RestManager
Per-core registry of ManagedResources found during core initialization.
Registering of managed resources can happen before the RestManager is fully initialized. To avoid timing issues, resources register themselves and then the RestManager initializes all ManagedResources before the core is activated.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionCollection<org.apache.solr.rest.RestManager.ManagedResourceRegistration> Get a view of the currently registered resources.Returns the set of non-registrable endpoints.voidregisterManagedResource(String resourceId, Class<? extends ManagedResource> implClass, ManagedResourceObserver observer) Register the need to use a ManagedResource; this method is typically called by a Solr component during core initialization to register itself as an observer of a specific type of ManagedResource.
-
Constructor Details
-
Registry
public Registry()
-
-
Method Details
-
getReservedEndpoints
Returns the set of non-registrable endpoints. -
getRegistered
Get a view of the currently registered resources. -
registerManagedResource
public void registerManagedResource(String resourceId, Class<? extends ManagedResource> implClass, ManagedResourceObserver observer) Register the need to use a ManagedResource; this method is typically called by a Solr component during core initialization to register itself as an observer of a specific type of ManagedResource. As many Solr components may share the same ManagedResource, this method only serves to associate the observer with an endpoint and implementation class. The actual construction of the ManagedResource and loading of data from storage occurs later once the RestManager is fully initialized.- Parameters:
resourceId- - An endpoint in the Rest API to manage the resource; must start with /config and /schema.implClass- - Class that implements ManagedResource.observer- - Solr component that needs to know when the data being managed by the ManagedResource is loaded, such as a TokenFilter.
-