Class RecoveryFileChunkRequest

All Implemented Interfaces:
Writeable, org.elasticsearch.common.util.concurrent.RefCounted, TaskAwareRequest

public final class RecoveryFileChunkRequest
extends RecoveryTransportRequest
implements org.elasticsearch.common.util.concurrent.RefCounted
  • Constructor Details

    • RecoveryFileChunkRequest

      public RecoveryFileChunkRequest​(StreamInput in) throws java.io.IOException
      Throws:
      java.io.IOException
    • RecoveryFileChunkRequest

      public RecoveryFileChunkRequest​(long recoveryId, long requestSeqNo, ShardId shardId, StoreFileMetadata metadata, long position, ReleasableBytesReference content, boolean lastChunk, int totalTranslogOps, long sourceThrottleTimeInNanos)
  • Method Details

    • recoveryId

      public long recoveryId()
    • shardId

      public ShardId shardId()
    • name

      public java.lang.String name()
    • position

      public long position()
    • length

      public long length()
    • content

      public ReleasableBytesReference content()
    • totalTranslogOps

      public int totalTranslogOps()
    • sourceThrottleTimeInNanos

      public long sourceThrottleTimeInNanos()
    • writeTo

      public void writeTo​(StreamOutput out) throws java.io.IOException
      Description copied from interface: Writeable
      Write this into the StreamOutput.
      Specified by:
      writeTo in interface Writeable
      Overrides:
      writeTo in class RecoveryTransportRequest
      Throws:
      java.io.IOException
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object
    • metadata

      public StoreFileMetadata metadata()
    • lastChunk

      public boolean lastChunk()
      Returns true if this chunk is the last chunk in the stream.
    • incRef

      public void incRef()
      Specified by:
      incRef in interface org.elasticsearch.common.util.concurrent.RefCounted
      Overrides:
      incRef in class TransportMessage
    • tryIncRef

      public boolean tryIncRef()
      Specified by:
      tryIncRef in interface org.elasticsearch.common.util.concurrent.RefCounted
      Overrides:
      tryIncRef in class TransportMessage
    • decRef

      public boolean decRef()
      Specified by:
      decRef in interface org.elasticsearch.common.util.concurrent.RefCounted
      Overrides:
      decRef in class TransportMessage