Class IncrementalDeletePolicy

  • Direct Known Subclasses:
    IncrementalDeleteFixedNumber

    public class IncrementalDeletePolicy
    extends java.lang.Object
    This class represents a policy for deleting index shards during a flush. This is useful if you want to want to discard older index shards to avoid the index growing infinitely.
    Since:
    4.0
    Author:
    Richard McCreadie, Stuart Mackie
    • Constructor Detail

      • IncrementalDeletePolicy

        public IncrementalDeletePolicy()
    • Method Detail

      • deletePolicy

        public boolean deletePolicy()
        No delete.
      • getIndicesToDelete

        protected java.util.List<java.lang.Integer> getIndicesToDelete​(java.util.List<Index> indices)
        Get a list of indices to delete (if any)
      • runPolicy

        public void runPolicy​(java.util.List<Index> indices)
      • deleteIndex

        public void deleteIndex​(IndexOnDisk index)