Class SqlQuery.Builder

java.lang.Object
org.springframework.data.elasticsearch.core.query.SqlQuery.Builder
Enclosing class:
SqlQuery

public static class SqlQuery.Builder extends Object
  • Method Details

    • withAllowPartialSearchResults

      public SqlQuery.Builder withAllowPartialSearchResults(Boolean allowPartialSearchResults)
      If true, returns partial results if there are shard request timeouts or shard failures.
    • withCatalog

      public SqlQuery.Builder withCatalog(String catalog)
      Default catalog/cluster for queries. If unspecified, the queries are executed on the data in the local cluster only.
    • withColumnar

      public SqlQuery.Builder withColumnar(Boolean columnar)
      If true, returns results in a columnar format.
    • withCursor

      public SqlQuery.Builder withCursor(String cursor)
      To retrieve a set of paginated results, ignore other request body parameters when specifying a cursor and using the columnar and timeZone parameters.
    • withFetchSize

      public SqlQuery.Builder withFetchSize(Integer fetchSize)
      Maximum number of rows to return in the response.
    • withFieldMultiValueLeniency

      public SqlQuery.Builder withFieldMultiValueLeniency(Boolean fieldMultiValueLeniency)
      If false, the API returns an error for fields containing array values.
    • setFilter

      public SqlQuery.Builder setFilter(Query filter)
      Query that filter documents for the SQL search.
    • withIndexIncludeFrozen

      public SqlQuery.Builder withIndexIncludeFrozen(Boolean indexIncludeFrozen)
      If true, the search can run on frozen indices.
    • setKeepAlive

      public SqlQuery.Builder setKeepAlive(Duration keepAlive)
      Retention period for an async or saved synchronous search.
    • withKeepOnCompletion

      public SqlQuery.Builder withKeepOnCompletion(Boolean keepOnCompletion)
      If it is true, it will store synchronous searches when the waitForCompletionTimeout parameter is specified.
    • withPageTimeout

      public SqlQuery.Builder withPageTimeout(Duration pageTimeout)
      Minimum retention period for the scroll cursor.
    • withRequestTimeout

      public SqlQuery.Builder withRequestTimeout(Duration requestTimeout)
      Timeout before the request fails.
    • withParams

      public SqlQuery.Builder withParams(List<Object> params)
      Values for parameters in the query.
    • withParam

      public SqlQuery.Builder withParam(Object param)
      Value for parameters in the query.
    • withTimeZone

      public SqlQuery.Builder withTimeZone(TimeZone timeZone)
      Time zone ID for the search.
    • withWaitForCompletionTimeout

      public SqlQuery.Builder withWaitForCompletionTimeout(Duration waitForCompletionTimeout)
      Period to wait for complete results.
    • build

      public SqlQuery build()