类 ResizeRequest

java.lang.Object
org.easysearch.client.TimedRequest
org.easysearch.client.indices.ResizeRequest
所有已实现的接口:
Validatable, org.easysearch.common.xcontent.ToXContent, org.easysearch.common.xcontent.ToXContentObject

public class ResizeRequest
extends TimedRequest
implements Validatable, org.easysearch.common.xcontent.ToXContentObject
Request class to resize an index
  • 嵌套类概要

    从接口继承的嵌套类/接口 org.easysearch.common.xcontent.ToXContent

    org.easysearch.common.xcontent.ToXContent.DelegatingMapParams, org.easysearch.common.xcontent.ToXContent.MapParams, org.easysearch.common.xcontent.ToXContent.Params
  • 字段概要

    从类继承的字段 org.easysearch.client.TimedRequest

    DEFAULT_ACK_TIMEOUT, DEFAULT_MASTER_NODE_TIMEOUT

    从接口继承的字段 org.easysearch.common.xcontent.ToXContent

    EMPTY_PARAMS

    从接口继承的字段 org.easysearch.client.Validatable

    EMPTY
  • 构造器概要

    构造器
    构造器 说明
    ResizeRequest​(java.lang.String targetIndex, java.lang.String sourceIndex)
    Creates a new resize request
  • 方法概要

    修饰符和类型 方法 说明
    java.util.Set<org.easysearch.action.admin.indices.alias.Alias> getAliases()
    Returns the Aliases to be used on the target index
    org.easysearch.common.settings.Settings getSettings()
    Returns the Settings to be used on the target index
    java.lang.String getSourceIndex()
    Returns the source index name
    java.lang.String getTargetIndex()
    Returns the target index name
    org.easysearch.action.support.ActiveShardCount getWaitForActiveShards()  
    ResizeRequest setAliases​(java.util.List<org.easysearch.action.admin.indices.alias.Alias> aliases)
    Sets the Aliases to be used on the target index
    ResizeRequest setSettings​(org.easysearch.common.settings.Settings settings)
    Sets the Settings to be used on the target index
    ResizeRequest setWaitForActiveShards​(int waitForActiveShards)
    A shortcut for setWaitForActiveShards(ActiveShardCount) where the numerical shard count is passed in, instead of having to first call ActiveShardCount.from(int) to get the ActiveShardCount.
    ResizeRequest setWaitForActiveShards​(org.easysearch.action.support.ActiveShardCount waitForActiveShards)
    Sets the number of shard copies that should be active for creation of the new shrunken index to return.
    org.easysearch.common.xcontent.XContentBuilder toXContent​(org.easysearch.common.xcontent.XContentBuilder builder, org.easysearch.common.xcontent.ToXContent.Params params)  
    java.util.Optional<ValidationException> validate()
    Perform validation.

    从类继承的方法 org.easysearch.client.TimedRequest

    masterNodeTimeout, setMasterTimeout, setTimeout, timeout

    从类继承的方法 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    从接口继承的方法 org.easysearch.common.xcontent.ToXContentObject

    isFragment
  • 构造器详细资料

    • ResizeRequest

      public ResizeRequest​(java.lang.String targetIndex, java.lang.String sourceIndex)
      Creates a new resize request
      参数:
      targetIndex - the new index to create with resized shards
      sourceIndex - the index to resize
  • 方法详细资料

    • setSettings

      public ResizeRequest setSettings​(org.easysearch.common.settings.Settings settings)
      Sets the Settings to be used on the target index
    • getSettings

      public org.easysearch.common.settings.Settings getSettings()
      Returns the Settings to be used on the target index
    • setAliases

      public ResizeRequest setAliases​(java.util.List<org.easysearch.action.admin.indices.alias.Alias> aliases)
      Sets the Aliases to be used on the target index
    • getAliases

      public java.util.Set<org.easysearch.action.admin.indices.alias.Alias> getAliases()
      Returns the Aliases to be used on the target index
    • validate

      public java.util.Optional<ValidationException> validate()
      从接口复制的说明: Validatable
      Perform validation. This method does not have to be overridden in the event that no validation needs to be done, or the validation was done during object construction time. A ValidationException that is not null is assumed to contain validation errors and will be thrown.
      指定者:
      validate 在接口中 Validatable
      返回:
      An Optional ValidationException that contains a list of validation errors.
    • getTargetIndex

      public java.lang.String getTargetIndex()
      Returns the target index name
    • getSourceIndex

      public java.lang.String getSourceIndex()
      Returns the source index name
    • setWaitForActiveShards

      public ResizeRequest setWaitForActiveShards​(org.easysearch.action.support.ActiveShardCount waitForActiveShards)
      Sets the number of shard copies that should be active for creation of the new shrunken index to return. Defaults to ActiveShardCount.DEFAULT, which will wait for one shard copy (the primary) to become active. Set this value to ActiveShardCount.ALL to wait for all shards (primary and all replicas) to be active before returning. Otherwise, use ActiveShardCount.from(int) to set this value to any non-negative integer, up to the number of copies per shard (number of replicas + 1), to wait for the desired amount of shard copies to become active before returning. Index creation will only wait up until the timeout value for the number of shard copies to be active before returning. Check ShardsAcknowledgedResponse.isShardsAcknowledged() to determine if the requisite shard copies were all started before returning or timing out.
      参数:
      waitForActiveShards - number of active shard copies to wait on
    • setWaitForActiveShards

      public ResizeRequest setWaitForActiveShards​(int waitForActiveShards)
      A shortcut for setWaitForActiveShards(ActiveShardCount) where the numerical shard count is passed in, instead of having to first call ActiveShardCount.from(int) to get the ActiveShardCount.
    • getWaitForActiveShards

      public org.easysearch.action.support.ActiveShardCount getWaitForActiveShards()
    • toXContent

      public org.easysearch.common.xcontent.XContentBuilder toXContent​(org.easysearch.common.xcontent.XContentBuilder builder, org.easysearch.common.xcontent.ToXContent.Params params) throws java.io.IOException
      指定者:
      toXContent 在接口中 org.easysearch.common.xcontent.ToXContent
      抛出:
      java.io.IOException