Record Class ResumeInfo.ScrollWorkerResumeInfo

java.lang.Object
java.lang.Record
org.elasticsearch.index.reindex.ResumeInfo.ScrollWorkerResumeInfo
All Implemented Interfaces:
NamedWriteable, Writeable, ResumeInfo.WorkerResumeInfo
Enclosing class:
ResumeInfo

public static record ResumeInfo.ScrollWorkerResumeInfo(String scrollId, long startTimeEpochMillis, BulkByScrollTask.Status status, Version remoteVersion) extends Record implements ResumeInfo.WorkerResumeInfo
Resume information for a scroll-based BulkByScrollTask worker.
  • Field Details

  • Constructor Details

    • ScrollWorkerResumeInfo

      public ScrollWorkerResumeInfo(String scrollId, long startTimeEpochMillis, BulkByScrollTask.Status status, @Nullable Version remoteVersion)
      Creates an instance of a ScrollWorkerResumeInfo record class.
      Parameters:
      scrollId - the value for the scrollId record component
      startTimeEpochMillis - the value for the startTimeEpochMillis record component
      status - the value for the status record component
      remoteVersion - the value for the remoteVersion record component
    • ScrollWorkerResumeInfo

      public ScrollWorkerResumeInfo(StreamInput in) throws IOException
      Throws:
      IOException
  • Method Details

    • writeTo

      public void writeTo(StreamOutput out) throws IOException
      Description copied from interface: Writeable
      Write this into the StreamOutput.
      Specified by:
      writeTo in interface Writeable
      Throws:
      IOException
    • getWriteableName

      public String getWriteableName()
      Description copied from interface: NamedWriteable
      Returns the name of the writeable object
      Specified by:
      getWriteableName in interface NamedWriteable
    • 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.
    • scrollId

      public String scrollId()
      Returns the value of the scrollId record component.
      Returns:
      the value of the scrollId record component
    • startTimeEpochMillis

      public long startTimeEpochMillis()
      Returns the value of the startTimeEpochMillis record component.
      Specified by:
      startTimeEpochMillis in interface ResumeInfo.WorkerResumeInfo
      Returns:
      the value of the startTimeEpochMillis record component
    • status

      public BulkByScrollTask.Status status()
      Returns the value of the status record component.
      Specified by:
      status in interface ResumeInfo.WorkerResumeInfo
      Returns:
      the value of the status record component
    • remoteVersion

      @Nullable public Version remoteVersion()
      Returns the value of the remoteVersion record component.
      Returns:
      the value of the remoteVersion record component