Package org.apache.solr.update.processor
Class SimpleUpdateProcessorFactory
java.lang.Object
org.apache.solr.update.processor.UpdateRequestProcessorFactory
org.apache.solr.update.processor.SimpleUpdateProcessorFactory
- All Implemented Interfaces:
NamedListInitializedPlugin
- Direct Known Subclasses:
TemplateUpdateProcessorFactory
A base class for writing a very simple UpdateProcessor without worrying too much about the API.
This is deliberately made to support only the add operation
- Since:
- 5.1.0
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.solr.update.processor.UpdateRequestProcessorFactory
UpdateRequestProcessorFactory.RunAlways -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetInstance(SolrQueryRequest req, SolrQueryResponse rsp, UpdateRequestProcessor next) protected Stringprotected Stringprotected String[]returns value from init args or request parameter.voidinit(org.apache.solr.common.util.NamedList<?> args) initwill be called just once, immediately after creation.protected abstract voidprocess(AddUpdateCommand cmd, SolrQueryRequest req, SolrQueryResponse rsp) This object is reused across requests.
-
Field Details
-
initArgs
protected org.apache.solr.common.util.NamedList<?> initArgs
-
-
Constructor Details
-
SimpleUpdateProcessorFactory
protected SimpleUpdateProcessorFactory()
-
-
Method Details
-
init
public void init(org.apache.solr.common.util.NamedList<?> args) Description copied from interface:NamedListInitializedPlugininitwill be called just once, immediately after creation.Source of the initialization arguments will typically be solrconfig.xml, but will ultimately depends on the plugin itself
- Parameters:
args- non-null list of initialization parameters (may be empty)
-
getInstance
public UpdateRequestProcessor getInstance(SolrQueryRequest req, SolrQueryResponse rsp, UpdateRequestProcessor next) - Specified by:
getInstancein classUpdateRequestProcessorFactory
-
getParam
-
getParams
returns value from init args or request parameter. the request parameter must have the URP shortname prefixed -
getMyName
-
process
This object is reused across requests. So,this method should not store anything in the instance variable.
-