Class CreateIndexRequest

All Implemented Interfaces:

public class CreateIndexRequest
extends RequestBase
implements JsonpSerializable
Creates an index with optional settings and mappings.
See Also:
API specification
  • Field Details

  • Method Details

    • of

      public static CreateIndexRequest of​(java.util.function.Function<CreateIndexRequest.Builder,​ObjectBuilder<CreateIndexRequest>> fn)
    • aliases

      public final java.util.Map<java.lang.String,​Alias> aliases()
      API name: aliases
    • index

      public final java.lang.String index()
      Required - The name of the index

      API name: index

    • mappings

      @Nullable public final TypeMapping mappings()
      Mapping for fields in the index. If specified, this mapping can include:
      • Field names
      • Field data types
      • Mapping parameters

      API name: mappings

    • masterTimeout

      @Nullable public final Time masterTimeout()
      Specify timeout for connection to master

      API name: master_timeout

    • settings

      @Nullable public final IndexSettings settings()
      API name: settings
    • timeout

      @Nullable public final Time timeout()
      Explicit operation timeout

      API name: timeout

    • waitForActiveShards

      @Nullable public final WaitForActiveShards waitForActiveShards()
      Set the number of active shards to wait for before the operation returns.

      API name: wait_for_active_shards

    • serialize

      public void serialize​( generator, JsonpMapper mapper)
      Serialize this object to JSON.
      Specified by:
      serialize in interface JsonpSerializable
    • serializeInternal

      protected void serializeInternal​( generator, JsonpMapper mapper)
    • setupCreateIndexRequestDeserializer

      protected static void setupCreateIndexRequestDeserializer​(ObjectDeserializer<CreateIndexRequest.Builder> op)