Class DocumentSearchRequest

java.lang.Object
com.atlassian.jira.search.issue.DocumentSearchRequest

@PublicApi public final class DocumentSearchRequest extends Object
Encapsulation of all parameters required to match index documents. Includes
  • Method Details

    • builder

      public static DocumentSearchRequest.Builder builder()
    • searcher

      @Nullable public ApplicationUser searcher()
      Returns the user on whose behalf the search is performed, or null if the search is anonymous.
    • jqlQuery

      @Nonnull public Query jqlQuery()
      Returns the JQL query to match documents. Must not be null.
    • filterQuery

      @Nullable public Query filterQuery()
      Returns an additional query to further restrict results, or null if no additional query is required.
    • fieldsToLoad

      @Nullable public Collection<String> fieldsToLoad()
      Returns he fields to load in the result documents, or null if all fields should be loaded. An empty collection means no fields will be loaded.
    • overrideSecurity

      public boolean overrideSecurity()
      Returns true if the search should ignore security restrictions, false otherwise.
    • aggregations

      @Nullable public AggregationsRequest aggregations()
      Returns the aggregation request to compute aggregated results, or null if no aggregation requested.
      Since:
      10.5
    • trackHits

      @Nullable public TrackHits trackHits()
      Returns the track hits option, which defines how total hits count is tracked.

      Only applicable for SearchPlatform.OPENSEARCH. If not specified, the default OpenSearch behavior is used which counts up to 10_000 results (equivalent to TrackHits.upTo(10_000)).

      For SearchPlatform.LUCENE the total hits count is always tracked (equivalent to TrackHits.all()).

      Since:
      11.0
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object