Class ExistsRequest

java.lang.Object
co.elastic.clients.elasticsearch._types.RequestBase
co.elastic.clients.elasticsearch.core.ExistsRequest

public class ExistsRequest extends RequestBase
Checks if a document in an index exists.
See Also:
  • Field Details

  • Method Details

    • of

    • source

      @Nullable public final SourceConfigParam source()
      true or false to return the _source field or not, or a list of fields to return.

      API name: _source

    • sourceExcludes

      public final List<String> sourceExcludes()
      A comma-separated list of source fields to exclude in the response.

      API name: _source_excludes

    • sourceIncludes

      public final List<String> sourceIncludes()
      A comma-separated list of source fields to include in the response.

      API name: _source_includes

    • id

      public final String id()
      Required - Identifier of the document.

      API name: id

    • index

      public final String index()
      Required - Comma-separated list of data streams, indices, and aliases. Supports wildcards (*).

      API name: index

    • preference

      @Nullable public final String preference()
      Specifies the node or shard the operation should be performed on. Random by default.

      API name: preference

    • realtime

      @Nullable public final Boolean realtime()
      If true, the request is real-time as opposed to near-real-time.

      API name: realtime

    • refresh

      @Nullable public final Boolean refresh()
      If true, Elasticsearch refreshes all shards involved in the delete by query after the request completes.

      API name: refresh

    • routing

      @Nullable public final String routing()
      Target the specified primary shard.

      API name: routing

    • storedFields

      public final List<String> storedFields()
      List of stored fields to return as part of a hit. If no fields are specified, no stored fields are included in the response. If this field is specified, the _source parameter defaults to false.

      API name: stored_fields

    • version

      @Nullable public final Long version()
      Explicit version number for concurrency control. The specified version must match the current version of the document for the request to succeed.

      API name: version

    • versionType

      @Nullable public final VersionType versionType()
      Specific version type: external, external_gte.

      API name: version_type