Class ReplicaOfflineMsg
java.lang.Object
org.opends.server.replication.protocol.ReplicationMsg
org.opends.server.replication.protocol.UpdateMsg
org.opends.server.replication.protocol.ReplicaOfflineMsg
- All Implemented Interfaces:
Comparable<UpdateMsg>
Class that define messages sent by a replica (DS) to the replication server (RS) to let the RS know the date at which
a replica went offline.
-
Field Summary
Fields inherited from class org.opends.server.replication.protocol.ReplicationMsg
COMPACT_MASK, COMPACT_TYPE_ADD, COMPACT_TYPE_DELETE, COMPACT_TYPE_MODIFY, COMPACT_TYPE_MODIFY_DN, COMPACT_TYPE_REPLICA_OFFLINE, MSG_TYPE_DISK_ENCODING
-
Constructor Summary
ConstructorDescriptionReplicaOfflineMsg
(byte[] in) Creates a message by deserializing it from the provided byte array.ReplicaOfflineMsg
(CSN offlineCSN) Constructor of a replica offline message providing the offline timestamp in a CSN. -
Method Summary
Modifier and TypeMethodDescription<E extends Exception>
voidaccept
(UpdateMsgVisitor<E> visitor) Applies anUpdateMsgVisitor
to thisUpdateMsg
.byte[]
getBytes
(short protocolVersion) Serializes the PDU using the provided replication protocol version.int
size()
Return the number of bytes used by this message.Methods inherited from class org.opends.server.replication.protocol.UpdateMsg
compareTo, equals, getBytes, getCSN, getVersion, hashCode, toJson, toString
Methods inherited from class org.opends.server.replication.protocol.ReplicationMsg
decodeMsg, isRetryable
-
Constructor Details
-
ReplicaOfflineMsg
Constructor of a replica offline message providing the offline timestamp in a CSN.- Parameters:
offlineCSN
- the provided offline CSN
-
ReplicaOfflineMsg
Creates a message by deserializing it from the provided byte array.- Parameters:
in
- The provided byte array.- Throws:
DataFormatException
- When an error occurs during decoding .
-
-
Method Details
-
getBytes
public byte[] getBytes(short protocolVersion) Description copied from class:ReplicationMsg
Serializes the PDU using the provided replication protocol version. WARNING: should be overwritten by a PDU (sub class) we want to support older protocol version serialization for. -
size
public int size()Description copied from class:UpdateMsg
Return the number of bytes used by this message. -
accept
Description copied from class:UpdateMsg
Applies anUpdateMsgVisitor
to thisUpdateMsg
.- Specified by:
accept
in classUpdateMsg
- Type Parameters:
E
- The type of the exception thrown by the visitor method if it fails, orNeverThrowsException
if the visitor cannot fail.- Parameters:
visitor
- The message visitor.- Throws:
E
- If the visitor failed.
-