Represents a versioned collection of retention leases. We version the collection of retention leases to ensure that sync requests that
arrive out of order on the replica, using the version to ensure that older sync requests are rejected.
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
Constructs a new retention lease collection from a stream. The retention lease collection should have been written via
writeTo(StreamOutput).
Parameters:
in - the stream to construct the retention lease collection from
Throws:
IOException - if an I/O exception occurs reading from the stream
Method Details
primaryTerm
publiclongprimaryTerm()
The primary term of this retention lease collection.
Returns:
the primary term
version
publiclongversion()
The version of this retention lease collection. The version is managed on the primary and incremented any time that a retention lease
is added, renewed, or when retention leases expire.