Class InitializeRcvAckMsg
- java.lang.Object
-
- org.opends.server.replication.protocol.ReplicationMsg
-
- org.opends.server.replication.protocol.InitializationMsg
-
- org.opends.server.replication.protocol.InitializeRcvAckMsg
-
public final class InitializeRcvAckMsg extends InitializationMsg
This message is used by Replicas to update the send window of the peer replica.A receiving replica should create such a message with a given credit when it wants to open the send window of the replica sending data; a replica should increase its send window when receiving such a message.
-
-
Field Summary
-
Fields inherited from class org.opends.server.replication.protocol.InitializationMsg
destination, senderId
-
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
Constructors Constructor Description InitializeRcvAckMsg(ReplicaId sender, ReplicaId destination, int numAck)Create a new message..
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]getBytes(short protocolVersion)Serializes the PDU using the provided replication protocol version.intgetNumAck()Get the number of message acknowledged by this message.ReplicaIdgetSenderID()Get the server ID of the server that sent this message.booleanisRetryable()Returns if in case of I/O error we should try to send this message again.StringtoString()-
Methods inherited from class org.opends.server.replication.protocol.InitializationMsg
getDestination
-
Methods inherited from class org.opends.server.replication.protocol.ReplicationMsg
decodeMsg
-
-
-
-
Constructor Detail
-
InitializeRcvAckMsg
public InitializeRcvAckMsg(ReplicaId sender, ReplicaId destination, int numAck)
Create a new message..- Parameters:
sender- The server ID of the server that send this message.destination- The destination server or servers of this message.numAck- The number of acknowledged messages. The window will be increase by this credit number.
-
-
Method Detail
-
getBytes
public byte[] getBytes(short protocolVersion)
Description copied from class:ReplicationMsgSerializes 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.- Specified by:
getBytesin classReplicationMsg- Parameters:
protocolVersion- The protocol version to use for serialization. The version should normally be older than the current one.- Returns:
- The encoded PDU, or
nullif the message isn't supported in that protocol version.
-
toString
public String toString()
- Overrides:
toStringin classInitializationMsg
-
getNumAck
public int getNumAck()
Get the number of message acknowledged by this message.- Returns:
- the number of message acknowledged by this message.
-
isRetryable
public boolean isRetryable()
Description copied from class:ReplicationMsgReturns if in case of I/O error we should try to send this message again.- Overrides:
isRetryablein classReplicationMsg- Returns:
- if in case of I/O error we should try to send this message again
-
getSenderID
public ReplicaId getSenderID()
Description copied from class:InitializationMsgGet the server ID of the server that sent this message.- Overrides:
getSenderIDin classInitializationMsg- Returns:
- the server id
-
-