Class DelegatingSolrQueryRequest

java.lang.Object
org.apache.solr.request.DelegatingSolrQueryRequest
All Implemented Interfaces:
AutoCloseable, SolrQueryRequest

public class DelegatingSolrQueryRequest extends Object implements SolrQueryRequest
A SolrQueryRequest implementation that defers to a delegate in all cases.

Used primarily in cases where developers want to customize one or more SolrQueryRequest methods while deferring the remainder to an existing instances.

  • Constructor Details

    • DelegatingSolrQueryRequest

      public DelegatingSolrQueryRequest(SolrQueryRequest delegate)
  • Method Details

    • getParams

      public org.apache.solr.common.params.SolrParams getParams()
      Description copied from interface: SolrQueryRequest
      returns the current request parameters
      Specified by:
      getParams in interface SolrQueryRequest
    • setParams

      public void setParams(org.apache.solr.common.params.SolrParams params)
      Description copied from interface: SolrQueryRequest
      Change the parameters for this request. This does not affect the original parameters returned by getOriginalParams()
      Specified by:
      setParams in interface SolrQueryRequest
    • getContentStreams

      public Iterable<org.apache.solr.common.util.ContentStream> getContentStreams()
      Description copied from interface: SolrQueryRequest
      A Collection of ContentStreams passed to the request
      Specified by:
      getContentStreams in interface SolrQueryRequest
    • getOriginalParams

      public org.apache.solr.common.params.SolrParams getOriginalParams()
      Description copied from interface: SolrQueryRequest
      Returns the original request parameters. As this does not normally include configured defaults it's more suitable for logging.
      Specified by:
      getOriginalParams in interface SolrQueryRequest
    • getContext

      public Map<Object,Object> getContext()
      Description copied from interface: SolrQueryRequest
      Generic information associated with this request that may be both read and updated.
      Specified by:
      getContext in interface SolrQueryRequest
    • close

      public void close()
      Description copied from interface: SolrQueryRequest
      This method should be called when all uses of this request are finished, so that resources can be freed.
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface SolrQueryRequest
    • getStartTime

      public long getStartTime()
      Description copied from interface: SolrQueryRequest
      The start time of this request in milliseconds. Use this only if you need the absolute system time at the start of the request, getRequestTimer() provides a more accurate mechanism for timing purposes.
      Specified by:
      getStartTime in interface SolrQueryRequest
    • getRequestTimer

      public RTimerTree getRequestTimer()
      Description copied from interface: SolrQueryRequest
      The timer for this request, created when the request started being processed
      Specified by:
      getRequestTimer in interface SolrQueryRequest
    • getSearcher

      public SolrIndexSearcher getSearcher()
      Description copied from interface: SolrQueryRequest
      The index searcher associated with this request
      Specified by:
      getSearcher in interface SolrQueryRequest
    • getCore

      public SolrCore getCore()
      Description copied from interface: SolrQueryRequest
      The solr core (coordinator, etc) associated with this request
      Specified by:
      getCore in interface SolrQueryRequest
    • getSchema

      public IndexSchema getSchema()
      Description copied from interface: SolrQueryRequest
      The schema snapshot from core.getLatestSchema() at request creation.
      Specified by:
      getSchema in interface SolrQueryRequest
    • updateSchemaToLatest

      public void updateSchemaToLatest()
      Description copied from interface: SolrQueryRequest
      Replaces the current schema snapshot with the latest from the core.
      Specified by:
      updateSchemaToLatest in interface SolrQueryRequest
    • getParamString

      public String getParamString()
      Description copied from interface: SolrQueryRequest
      Returns a string representing all the important parameters. Suitable for logging.
      Specified by:
      getParamString in interface SolrQueryRequest
    • getJSON

      public Map<String,Object> getJSON()
      Description copied from interface: SolrQueryRequest
      Returns any associated JSON (or null if none) in deserialized generic form. Java classes used to represent the JSON are as follows: Map, List, String, Long, Double, Boolean
      Specified by:
      getJSON in interface SolrQueryRequest
    • setJSON

      public void setJSON(Map<String,Object> json)
      Specified by:
      setJSON in interface SolrQueryRequest
    • getUserPrincipal

      public Principal getUserPrincipal()
      Specified by:
      getUserPrincipal in interface SolrQueryRequest
    • getPath

      public String getPath()
      Specified by:
      getPath in interface SolrQueryRequest
    • getPathTemplateValues

      public Map<String,String> getPathTemplateValues()
      Description copied from interface: SolrQueryRequest
      Only for V2 API. Returns a map of path segments and their values. For example, if the path is configured as /path/{segment1}/{segment2} and a reguest is made as /path/x/y the returned map would contain {segment1:x ,segment2:y}
      Specified by:
      getPathTemplateValues in interface SolrQueryRequest
    • getCommands

      public List<org.apache.solr.common.util.CommandOperation> getCommands(boolean validateInput)
      Description copied from interface: SolrQueryRequest
      Only for v2 API if the request contains a command payload, it's parsed and returned as a list of CommandOperation objects
      Specified by:
      getCommands in interface SolrQueryRequest
      Parameters:
      validateInput - , If true it is validated against the json schema spec
    • getHttpMethod

      public String getHttpMethod()
      Specified by:
      getHttpMethod in interface SolrQueryRequest
    • getHttpSolrCall

      public HttpSolrCall getHttpSolrCall()
      Specified by:
      getHttpSolrCall in interface SolrQueryRequest
    • getTracer

      public io.opentracing.Tracer getTracer()
      Description copied from interface: SolrQueryRequest
      Distributed tracing Tracer. Never null but might implement NoopTracer.
      Specified by:
      getTracer in interface SolrQueryRequest
    • getSpan

      public io.opentracing.Span getSpan()
      Description copied from interface: SolrQueryRequest
      The distributed tracing Span for the request itself; never null. This is useful for adding tags or updating the operation name of the request span. If you need the current span, which might not necessarily be the request span, do this instead: tracer.activeSpan().
      Specified by:
      getSpan in interface SolrQueryRequest
    • getCoreContainer

      public CoreContainer getCoreContainer()
      Specified by:
      getCoreContainer in interface SolrQueryRequest
    • getCloudDescriptor

      public CloudDescriptor getCloudDescriptor()
      Specified by:
      getCloudDescriptor in interface SolrQueryRequest