Interface ReplicatedLogEntry
- All Known Implementing Classes:
SimpleReplicatedLogEntry
Represents one entry in the replicated log.
-
Method Summary
Modifier and TypeMethodDescriptioncommand()
Returns this entry'sStateMachineCommand
.boolean
Checks if persistence is pending for this entry.int
Return the estimate of serialized size of this entry when passed through serialization.int
size()
Returns the size of the entry in bytes.
-
Method Details
-
command
Payload command()Description copied from interface:LogEntry
Returns this entry'sStateMachineCommand
.- Specified by:
command
in interfaceLogEntry
- Returns:
- this entry's
StateMachineCommand
-
size
int size()Returns the size of the entry in bytes. An approximate number may be good enough.- Returns:
- the size of the entry in bytes.
-
serializedSize
int serializedSize()Return the estimate of serialized size of this entry when passed through serialization. The estimate needs to be reasonably accurate and should err on the side of caution and report a slightly-higher size in face of uncertainty.- Returns:
- An estimate of serialized size.
-
isPersistencePending
boolean isPersistencePending()Checks if persistence is pending for this entry.- Returns:
- true if persistence is pending, false otherwise.
-