Class ApplyCommitRequest

java.lang.Object
org.elasticsearch.transport.TransportMessage
org.elasticsearch.transport.TransportRequest
org.elasticsearch.cluster.coordination.ApplyCommitRequest
All Implemented Interfaces:
Writeable, org.elasticsearch.common.util.concurrent.RefCounted, TaskAwareRequest

public class ApplyCommitRequest
extends TransportRequest
A master node sends this request to its peers to inform them that it could commit the cluster state with the given term and version. Peers that have accepted the given cluster state will then consider it as committed and proceed to apply the state locally.
  • Field Details

    • sourceNode

      protected final DiscoveryNode sourceNode
    • term

      protected final long term
    • version

      protected final long version
  • Constructor Details

    • ApplyCommitRequest

      public ApplyCommitRequest​(DiscoveryNode sourceNode, long term, long version)
    • ApplyCommitRequest

      public ApplyCommitRequest​(StreamInput in) throws java.io.IOException
      Throws:
      java.io.IOException
  • Method Details

    • 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
      Throws:
      java.io.IOException
    • toString

      public java.lang.String toString()
    • getSourceNode

      public DiscoveryNode getSourceNode()
    • getTerm

      public long getTerm()
    • getVersion

      public long getVersion()
    • equals

      public boolean equals​(java.lang.Object o)
      Overrides:
      equals in class java.lang.Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class java.lang.Object