Class AllocationExplainRequest

java.lang.Object
co.elastic.clients.elasticsearch._types.RequestBase
co.elastic.clients.elasticsearch.cluster.AllocationExplainRequest
All Implemented Interfaces:
JsonpSerializable

@JsonpDeserializable public class AllocationExplainRequest extends RequestBase implements JsonpSerializable
Explain the shard allocations. Get explanations for shard allocations in the cluster. For unassigned shards, it provides an explanation for why the shard is unassigned. For assigned shards, it provides an explanation for why the shard is remaining on its current node and has not moved or rebalanced to another node. This API can be very useful when attempting to diagnose why a shard is unassigned or why a shard continues to remain on its current node when you might expect otherwise.
See Also:
  • Field Details

  • Method Details

    • of

    • currentNode

      @Nullable public final String currentNode()
      Specifies the node ID or the name of the node to only explain a shard that is currently located on the specified node.

      API name: current_node

    • includeDiskInfo

      @Nullable public final Boolean includeDiskInfo()
      If true, returns information about disk usage and shard sizes.

      API name: include_disk_info

    • includeYesDecisions

      @Nullable public final Boolean includeYesDecisions()
      If true, returns YES decisions in explanation.

      API name: include_yes_decisions

    • index

      @Nullable public final String index()
      Specifies the name of the index that you would like an explanation for.

      API name: index

    • masterTimeout

      @Nullable public final Time masterTimeout()
      Period to wait for a connection to the master node.

      API name: master_timeout

    • primary

      @Nullable public final Boolean primary()
      If true, returns explanation for the primary shard for the given shard ID.

      API name: primary

    • shard

      @Nullable public final Integer shard()
      Specifies the ID of the shard that you would like an explanation for.

      API name: shard

    • serialize

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

      protected void serializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
    • setupAllocationExplainRequestDeserializer

      protected static void setupAllocationExplainRequestDeserializer(ObjectDeserializer<AllocationExplainRequest.Builder> op)