RequestHandlerBase (Solr 3.6.2 API)
Keywords: org.apache.solr.handler.RequestHandlerBase class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.solr.handler
Class RequestHandlerBase

    java.lang.Object
      org.apache.solr.handler.RequestHandlerBase

All Implemented Interfaces:
  SolrInfoMBean, SolrRequestHandler

Direct Known Subclasses:
  AnalysisRequestHandler, AnalysisRequestHandlerBase, ContentStreamHandlerBase, CoreAdminHandler, DataImportHandler, DumpRequestHandler, FileFloatSource.ReloadCacheRequestHandler, LukeRequestHandler, MoreLikeThisHandler, PingRequestHandler, PluginInfoHandler, PropertiesRequestHandler, ReplicationHandler, SearchHandler, ShowFileRequestHandler, SolrInfoMBeanHandler, SpellCheckerRequestHandler, SystemInfoHandler, ThreadDumpHandler

    public abstract class RequestHandlerBase

extends Object
implements SolrRequestHandler, SolrInfoMBean

Nested Class Summary

Nested classes/interfaces inherited from interface org.apache.solr.core.SolrInfoMBean
`SolrInfoMBean.Category`

Field Summary
`protected SolrParams` | `appends`
`protected SolrParams` | `defaults`
`protected boolean` | `httpCaching`
`protected NamedList` | `initArgs`
`protected SolrParams` | `invariants`

Constructor Summary
`RequestHandlerBase()`

Method Summary
`SolrInfoMBean.Category` | `getCategory()` Purpose of this Class
`abstract String` | `getDescription()` Simple one or two line description
`URL[]` | `getDocs()` Documentation URL list.
`NamedList` | `getInitArgs()`
`String` | `getName()` Simple common usage name, e.g.
`abstract String` | `getSource()` CVS Source, SVN Source, etc
`abstract String` | `getSourceId()` CVS Id, SVN Id, etc
`NamedList` | `getStatistics()` Any statistics this instance would like to be publicly available via the Solr Administration interface.
`abstract String` | `getVersion()` Simple common usage version, e.g.
`void` | `handleRequest(SolrQueryRequest req, SolrQueryResponse rsp)` Handles a query request, this method must be thread safe.
`abstract void` | `handleRequestBody(SolrQueryRequest req, SolrQueryResponse rsp)`
`void` | `init(NamedList args)` Initializes the `SolrRequestHandler` by creating three `SolrParams` named.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### initArgs

    protected NamedList initArgs

### defaults

    protected SolrParams defaults

### appends

    protected SolrParams appends

### invariants

    protected SolrParams invariants

### httpCaching

    protected boolean httpCaching

Constructor Detail

### RequestHandlerBase

    public RequestHandlerBase()

Method Detail

### init

    public void init(NamedList args)

  Initializes the `SolrRequestHandler` by creating three `SolrParams` named.

  Name | Description
  --- | ---
  defaults | Contains all of the named arguments contained within the list element named "defaults".
  appends | Contains all of the named arguments contained within the list element named "appends".
  invariants | Contains all of the named arguments contained within the list element named "invariants".

  Example:

       <lst name="defaults">
       <str name="echoParams">explicit</str>
       <str name="qf">text^0.5 features^1.0 name^1.2 sku^1.5 id^10.0</str>
       <str name="mm">2<-1 5<-2 6<90%</str>
       <str name="bq">incubationdate_dt:[* TO NOW/DAY-1MONTH]^2.2</str>
       </lst>
       <lst name="appends">
       <str name="fq">inStock:true</str>
       </lst>

       <lst name="invariants">
       <str name="facet.field">cat</str>
       <str name="facet.field">manu_exact</str>
       <str name="facet.query">price:[* TO 500]</str>
       <str name="facet.query">price:[500 TO *]</str>
       </lst>

  Specified by:
    `init` in interface `SolrRequestHandler`
  Parameters:
    `args` - The `NamedList` to initialize from
  See Also:
    `handleRequest(org.apache.solr.request.SolrQueryRequest, org.apache.solr.response.SolrQueryResponse)`, `handleRequestBody(org.apache.solr.request.SolrQueryRequest, org.apache.solr.response.SolrQueryResponse)`, `SolrPluginUtils.setDefaults(org.apache.solr.request.SolrQueryRequest, org.apache.solr.common.params.SolrParams, org.apache.solr.common.params.SolrParams, org.apache.solr.common.params.SolrParams)`, `See also the example solrconfig.xml located in the Solr codebase (example/solr/conf).`

### getInitArgs

    public NamedList getInitArgs()

### handleRequestBody

    public abstract void handleRequestBody(SolrQueryRequest req,
                                           SolrQueryResponse rsp)
                                    throws Exception

  Throws:
    `Exception`

### handleRequest

    public void handleRequest(SolrQueryRequest req,
                              SolrQueryResponse rsp)

  Description copied from interface: `SolrRequestHandler`
  Handles a query request, this method must be thread safe.

  Information about the request may be obtained from `req` and response information may be set using `rsp`.

  There are no mandatory actions that handleRequest must perform. An empty handleRequest implementation would fulfill all interface obligations.

  Specified by:
    `handleRequest` in interface `SolrRequestHandler`

### getName

    public String getName()

  Description copied from interface: `SolrInfoMBean`
  Simple common usage name, e.g. BasicQueryHandler, or fully qualified clas name.

  Specified by:
    `getName` in interface `SolrInfoMBean`

### getDescription

    public abstract String getDescription()

  Description copied from interface: `SolrInfoMBean`
  Simple one or two line description

  Specified by:
    `getDescription` in interface `SolrInfoMBean`

### getSourceId

    public abstract String getSourceId()

  Description copied from interface: `SolrInfoMBean`
  CVS Id, SVN Id, etc

  Specified by:
    `getSourceId` in interface `SolrInfoMBean`

### getSource

    public abstract String getSource()

  Description copied from interface: `SolrInfoMBean`
  CVS Source, SVN Source, etc

  Specified by:
    `getSource` in interface `SolrInfoMBean`

### getVersion

    public abstract String getVersion()

  Description copied from interface: `SolrInfoMBean`
  Simple common usage version, e.g. 2.0

  Specified by:
    `getVersion` in interface `SolrInfoMBean`

### getCategory

    public SolrInfoMBean.Category getCategory()

  Description copied from interface: `SolrInfoMBean`
  Purpose of this Class

  Specified by:
    `getCategory` in interface `SolrInfoMBean`

### getDocs

    public URL[] getDocs()

  Description copied from interface: `SolrInfoMBean`
  Documentation URL list.

  Suggested documentation URLs: Homepage for sponsoring project, FAQ on class usage, Design doc for class, Wiki, bug reporting URL, etc...

  Specified by:
    `getDocs` in interface `SolrInfoMBean`

### getStatistics

    public NamedList getStatistics()

  Description copied from interface: `SolrInfoMBean`
  Any statistics this instance would like to be publicly available via the Solr Administration interface.

  Any Object type may be stored in the list, but only the `toString()` representation will be used.

  Specified by:
    `getStatistics` in interface `SolrInfoMBean`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD