Class CommitUpdateCommand

java.lang.Object
org.apache.solr.update.UpdateCommand
org.apache.solr.update.CommitUpdateCommand
All Implemented Interfaces:
Cloneable

public class CommitUpdateCommand extends UpdateCommand
A commit index command encapsulated in an object.
  • Field Details

    • optimize

      public boolean optimize
    • openSearcher

      public boolean openSearcher
    • waitSearcher

      public boolean waitSearcher
    • expungeDeletes

      public boolean expungeDeletes
    • softCommit

      public boolean softCommit
    • prepareCommit

      public boolean prepareCommit
    • commitData

      public Map<String,String> commitData
      User provided commit data. Can be let to null if there is none. It is possible to commit this user data, even if there is no uncommitted change in the index writer, provided this user data is not empty.
    • maxOptimizeSegments

      public int maxOptimizeSegments
      During optimize, optimize down to <= this many segments. Must be >= 1
      See Also:
      • IndexWriter.forceMerge(int)
  • Constructor Details

    • CommitUpdateCommand

      public CommitUpdateCommand(SolrQueryRequest req, boolean optimize)
  • Method Details

    • closeOnCommit

      public static CommitUpdateCommand closeOnCommit(SolrQueryRequest req, boolean optimize)
      Creates a CommitUpdateCommand to commit before closing the core and also prevent any new update by setting the core in read-only mode. Does not open a new searcher.
    • isClosingOnCommit

      public boolean isClosingOnCommit()
      Indicates whether this command is a commit before the core is closed. Any new updates must be prevented after the commit.
    • name

      public String name()
      Specified by:
      name in class UpdateCommand
    • toString

      public String toString()
      Overrides:
      toString in class UpdateCommand