org.apache.solr.update.processor

## Class DistributedUpdateProcessor

- java.lang.Object
- - org.apache.solr.update.processor.UpdateRequestProcessor
  - - org.apache.solr.update.processor.DistributedUpdateProcessor

- Direct Known Subclasses:
    CdcrUpdateProcessor

      public class DistributedUpdateProcessor
      extends UpdateRequestProcessor

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `DistributedUpdateProcessor.DistribPhase` Values this processor supports for the `DISTRIB_UPDATE_PARAM`.
    `static class` | `DistributedUpdateProcessor.DistributedUpdatesAsyncException`
    `static class` | `DistributedUpdateProcessor.RequestReplicationTracker` Keeps track of the replication factor achieved for a distributed update request originated in this distributed update processor.

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static String` | `COMMIT_END_POINT`
    `static String` | `DISTRIB_FROM`
    `static String` | `DISTRIB_FROM_COLLECTION`
    `static String` | `DISTRIB_FROM_PARENT`
    `static String` | `DISTRIB_FROM_SHARD`
    `static String` | `LOG_REPLAY`
    `static String` | `VERSION_FIELD`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `DistributedUpdateProcessor(SolrQueryRequest req, SolrQueryResponse rsp, AtomicUpdateDocumentMerger docMerger, UpdateRequestProcessor next)` Specification of AtomicUpdateDocumentMerger is currently experimental.
    `DistributedUpdateProcessor(SolrQueryRequest req, SolrQueryResponse rsp, UpdateRequestProcessor next)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `doDeleteByQuery(DeleteUpdateCommand cmd)`
    `protected ModifiableSolrParams` | `filterParams(SolrParams params)`
    `void` | `finish()`
    `static boolean` | `getNonZkLeaderAssumption(SolrQueryRequest req)` Returns a boolean indicating whether or not the caller should behave as if this is the "leader" even when ZooKeeper is not enabled.
    `void` | `processAdd(AddUpdateCommand cmd)`
    `void` | `processCommit(CommitUpdateCommand cmd)`
    `void` | `processDelete(DeleteUpdateCommand cmd)`
    `protected boolean` | `versionAdd(AddUpdateCommand cmd)`
    `protected boolean` | `versionDelete(DeleteUpdateCommand cmd)`
    `protected void` | `versionDeleteByQuery(DeleteUpdateCommand cmd)`

    - ### Methods inherited from class org.apache.solr.update.processor.UpdateRequestProcessor

      `processMergeIndexes, processRollback`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### DISTRIB_FROM_SHARD

          public static final String DISTRIB_FROM_SHARD

      See Also:
        Constant Field Values

    - #### DISTRIB_FROM_COLLECTION

          public static final String DISTRIB_FROM_COLLECTION

      See Also:
        Constant Field Values

    - #### DISTRIB_FROM_PARENT

          public static final String DISTRIB_FROM_PARENT

      See Also:
        Constant Field Values

    - #### DISTRIB_FROM

          public static final String DISTRIB_FROM

      See Also:
        Constant Field Values

    - #### COMMIT_END_POINT

          public static final String COMMIT_END_POINT

      See Also:
        Constant Field Values

    - #### LOG_REPLAY

          public static final String LOG_REPLAY

      See Also:
        Constant Field Values

    - #### VERSION_FIELD

          public static final String VERSION_FIELD

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### DistributedUpdateProcessor

          public DistributedUpdateProcessor(SolrQueryRequest req,
                                            SolrQueryResponse rsp,
                                            UpdateRequestProcessor next)

    - #### DistributedUpdateProcessor

          public DistributedUpdateProcessor(SolrQueryRequest req,
                                            SolrQueryResponse rsp,
                                            AtomicUpdateDocumentMerger docMerger,
                                            UpdateRequestProcessor next)

      Specification of AtomicUpdateDocumentMerger is currently experimental.
      WARNING: This API is experimental and might change in incompatible ways in the next release.

  - ### Method Detail

    - #### processAdd

          public void processAdd(AddUpdateCommand cmd)
                          throws IOException

      Overrides:
        `processAdd` in class `UpdateRequestProcessor`
      Throws:
        `IOException`

    - #### versionAdd

          protected boolean versionAdd(AddUpdateCommand cmd)
                                throws IOException

      Returns:
        whether or not to drop this cmd
      Throws:
        `IOException` - If there is a low-level I/O error.

    - #### processDelete

          public void processDelete(DeleteUpdateCommand cmd)
                             throws IOException

      Overrides:
        `processDelete` in class `UpdateRequestProcessor`
      Throws:
        `IOException`

    - #### filterParams

          protected ModifiableSolrParams filterParams(SolrParams params)

      See Also:
        `DistributedUpdateProcessorFactory.addParamToDistributedRequestWhitelist(org.apache.solr.request.SolrQueryRequest, java.lang.String...)`

    - #### doDeleteByQuery

          public void doDeleteByQuery(DeleteUpdateCommand cmd)
                               throws IOException

      Throws:
        `IOException`

    - #### versionDeleteByQuery

          protected void versionDeleteByQuery(DeleteUpdateCommand cmd)
                                       throws IOException

      Throws:
        `IOException`

    - #### versionDelete

          protected boolean versionDelete(DeleteUpdateCommand cmd)
                                   throws IOException

      Throws:
        `IOException`

    - #### processCommit

          public void processCommit(CommitUpdateCommand cmd)
                             throws IOException

      Overrides:
        `processCommit` in class `UpdateRequestProcessor`
      Throws:
        `IOException`

    - #### finish

          public void finish()
                      throws IOException

      Overrides:
        `finish` in class `UpdateRequestProcessor`
      Throws:
        `IOException`

    - #### getNonZkLeaderAssumption

          public static boolean getNonZkLeaderAssumption(SolrQueryRequest req)

      Returns a boolean indicating whether or not the caller should behave as if this is the "leader" even when ZooKeeper is not enabled. (Even in non zk mode, tests may simulate updates to/from a leader)

Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.