Class Coverage

java.lang.Object
com.yahoo.container.handler.Coverage

public class Coverage extends Object
The coverage report for a result set.
Author:
Steinar Knutsen, baldersheim
  • Field Details

    • docs

      protected long docs
    • active

      protected long active
    • targetActive

      protected long targetActive
    • degradedReason

      protected int degradedReason
    • nodes

      protected int nodes
    • resultSets

      protected int resultSets
    • fullResultSets

      protected int fullResultSets
    • fullReason

      protected Coverage.FullCoverageDefinition fullReason
    • DEGRADED_BY_MATCH_PHASE

      public static final int DEGRADED_BY_MATCH_PHASE
      See Also:
    • DEGRADED_BY_TIMEOUT

      public static final int DEGRADED_BY_TIMEOUT
      See Also:
    • DEGRADED_BY_ADAPTIVE_TIMEOUT

      public static final int DEGRADED_BY_ADAPTIVE_TIMEOUT
      See Also:
  • Constructor Details

    • Coverage

      protected Coverage(long docs, long active, int nodes, int resultSets)
    • Coverage

      public Coverage(long docs, int nodes, boolean full)
    • Coverage

      protected Coverage(long docs, int nodes, boolean full, int resultSets)
  • Method Details

    • merge

      public void merge(Coverage other)
    • getDocs

      public long getDocs()
      Returns the number of documents searched for this result. If the final result set is produced through several queries, this number will be the sum for all the queries.
    • getActive

      public long getActive()
      Returns the total number of documents that could be searched.
    • getTargetActive

      public long getTargetActive()
      Returns the total number of documents that will be searchable once redistribution has settled.
    • isDegraded

      public boolean isDegraded()
    • isDegradedByMatchPhase

      public boolean isDegradedByMatchPhase()
    • isDegradedByTimeout

      public boolean isDegradedByTimeout()
    • isDegradedByAdapativeTimeout

      public boolean isDegradedByAdapativeTimeout()
    • isDegradedByNonIdealState

      public boolean isDegradedByNonIdealState()
    • getFull

      public boolean getFull()
      Returns whether the search had full coverage or not
    • getNodes

      public int getNodes()
      Returns the number of search instances which participated successfully in the search.
    • getNodesTried

      public int getNodesTried()
      Returns the number of search instances which tried to participate in the search.
    • setNodesTried

      public Coverage setNodesTried(int nodesTried)
    • getFullResultSets

      public int getFullResultSets()
      A Coverage instance contains coverage information for potentially more than one search. If several queries, e.g. through blending of results from multiple clusters, produced a result set, this number will show how many of the result sets for these queries had full coverage.
      Returns:
      the number of result sets which had full coverage
    • getResultSets

      public int getResultSets()
      A Coverage instance contains coverage information for potentially more than one search. If several queries, e.g. through blending of results from multiple clusters, produced a result set, this number will show how many result sets containing coverage information this Coverage instance contains information about.
      Returns:
      the number of result sets with coverage information for this instance
    • getResultPercentage

      public int getResultPercentage()
      An int between 0 (inclusive) and 100 (inclusive) representing the percent coverage of the result sets this instance contains information about.
    • toLoggingCoverage

      public Coverage toLoggingCoverage()