Record Class IndexSetUpdateRequest

java.lang.Object
java.lang.Record
org.graylog2.rest.resources.system.indexer.requests.IndexSetUpdateRequest
All Implemented Interfaces:
SimpleIndexSetConfig

public record IndexSetUpdateRequest(@NotBlank String title, @Nullable String description, boolean isWritable, @jakarta.validation.constraints.Min(1L) int shards, @jakarta.validation.constraints.Min(0L) int replicas, @Nullable String rotationStrategyClass, @Nullable RotationStrategyConfig rotationStrategyConfig, @Nullable String retentionStrategyClass, @Nullable RetentionStrategyConfig retentionStrategyConfig, @jakarta.validation.constraints.Min(1L) int indexOptimizationMaxNumSegments, boolean indexOptimizationDisabled, org.joda.time.Duration fieldTypeRefreshInterval, @Nullable @ValidObjectId String fieldTypeProfile, @Nullable DataTieringConfig dataTieringConfig, @Nullable Boolean useLegacyRotation) extends Record implements SimpleIndexSetConfig
  • Constructor Details

    • IndexSetUpdateRequest

      public IndexSetUpdateRequest(@NotBlank @NotBlank String title, @Nullable String description, boolean isWritable, @Min(1L) @jakarta.validation.constraints.Min(1L) int shards, @Min(0L) @jakarta.validation.constraints.Min(0L) int replicas, @Nullable String rotationStrategyClass, @Nullable RotationStrategyConfig rotationStrategyConfig, @Nullable String retentionStrategyClass, @Nullable RetentionStrategyConfig retentionStrategyConfig, @Min(1L) @jakarta.validation.constraints.Min(1L) int indexOptimizationMaxNumSegments, boolean indexOptimizationDisabled, org.joda.time.Duration fieldTypeRefreshInterval, @ValidObjectId @Nullable @ValidObjectId String fieldTypeProfile, @Nullable DataTieringConfig dataTieringConfig, @Nullable Boolean useLegacyRotation)
      Creates an instance of a IndexSetUpdateRequest record class.
      Parameters:
      title - the value for the title record component
      description - the value for the description record component
      isWritable - the value for the isWritable record component
      shards - the value for the shards record component
      replicas - the value for the replicas record component
      rotationStrategyClass - the value for the rotationStrategyClass record component
      rotationStrategyConfig - the value for the rotationStrategyConfig record component
      retentionStrategyClass - the value for the retentionStrategyClass record component
      retentionStrategyConfig - the value for the retentionStrategyConfig record component
      indexOptimizationMaxNumSegments - the value for the indexOptimizationMaxNumSegments record component
      indexOptimizationDisabled - the value for the indexOptimizationDisabled record component
      fieldTypeRefreshInterval - the value for the fieldTypeRefreshInterval record component
      fieldTypeProfile - the value for the fieldTypeProfile record component
      dataTieringConfig - the value for the dataTieringConfig record component
      useLegacyRotation - the value for the useLegacyRotation record component
  • Method Details

    • useLegacyRotation

      public Boolean useLegacyRotation()
      Returns the value of the useLegacyRotation record component.
      Returns:
      the value of the useLegacyRotation record component
    • fromIndexSetConfig

      public static IndexSetUpdateRequest fromIndexSetConfig(IndexSetConfig indexSet)
    • toIndexSetConfig

      public IndexSetConfig toIndexSetConfig(String id, IndexSetConfig oldConfig)
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • title

      @NotBlank public @NotBlank String title()
      Returns the value of the title record component.
      Returns:
      the value of the title record component
    • description

      @Nullable public String description()
      Returns the value of the description record component.
      Returns:
      the value of the description record component
    • isWritable

      public boolean isWritable()
      Returns the value of the isWritable record component.
      Returns:
      the value of the isWritable record component
    • shards

      @Min(1L) public @jakarta.validation.constraints.Min(1L) int shards()
      Returns the value of the shards record component.
      Specified by:
      shards in interface SimpleIndexSetConfig
      Returns:
      the value of the shards record component
    • replicas

      @Min(0L) public @jakarta.validation.constraints.Min(0L) int replicas()
      Returns the value of the replicas record component.
      Specified by:
      replicas in interface SimpleIndexSetConfig
      Returns:
      the value of the replicas record component
    • rotationStrategyClass

      @Nullable public String rotationStrategyClass()
      Returns the value of the rotationStrategyClass record component.
      Specified by:
      rotationStrategyClass in interface SimpleIndexSetConfig
      Returns:
      the value of the rotationStrategyClass record component
    • rotationStrategyConfig

      @Nullable public RotationStrategyConfig rotationStrategyConfig()
      Returns the value of the rotationStrategyConfig record component.
      Specified by:
      rotationStrategyConfig in interface SimpleIndexSetConfig
      Returns:
      the value of the rotationStrategyConfig record component
    • retentionStrategyClass

      @Nullable public String retentionStrategyClass()
      Returns the value of the retentionStrategyClass record component.
      Specified by:
      retentionStrategyClass in interface SimpleIndexSetConfig
      Returns:
      the value of the retentionStrategyClass record component
    • retentionStrategyConfig

      @Nullable public RetentionStrategyConfig retentionStrategyConfig()
      Returns the value of the retentionStrategyConfig record component.
      Specified by:
      retentionStrategyConfig in interface SimpleIndexSetConfig
      Returns:
      the value of the retentionStrategyConfig record component
    • indexOptimizationMaxNumSegments

      @Min(1L) public @jakarta.validation.constraints.Min(1L) int indexOptimizationMaxNumSegments()
      Returns the value of the indexOptimizationMaxNumSegments record component.
      Specified by:
      indexOptimizationMaxNumSegments in interface SimpleIndexSetConfig
      Returns:
      the value of the indexOptimizationMaxNumSegments record component
    • indexOptimizationDisabled

      public boolean indexOptimizationDisabled()
      Returns the value of the indexOptimizationDisabled record component.
      Specified by:
      indexOptimizationDisabled in interface SimpleIndexSetConfig
      Returns:
      the value of the indexOptimizationDisabled record component
    • fieldTypeRefreshInterval

      public org.joda.time.Duration fieldTypeRefreshInterval()
      Returns the value of the fieldTypeRefreshInterval record component.
      Specified by:
      fieldTypeRefreshInterval in interface SimpleIndexSetConfig
      Returns:
      the value of the fieldTypeRefreshInterval record component
    • fieldTypeProfile

      @ValidObjectId @Nullable public @ValidObjectId String fieldTypeProfile()
      Returns the value of the fieldTypeProfile record component.
      Returns:
      the value of the fieldTypeProfile record component
    • dataTieringConfig

      @Nullable public DataTieringConfig dataTieringConfig()
      Returns the value of the dataTieringConfig record component.
      Specified by:
      dataTieringConfig in interface SimpleIndexSetConfig
      Returns:
      the value of the dataTieringConfig record component