mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Chris Ridd
18.51.2014 f6916f5a1c919be18156c6e812d1edece3515aab
opendj-sdk/opendj3-server-dev/src/server/org/opends/server/replication/protocol/ReplicaOfflineMsg.java
@@ -90,6 +90,10 @@
  @Override
  public byte[] getBytes(short protocolVersion)
  {
    if (protocolVersion < ProtocolVersion.REPLICATION_PROTOCOL_V8)
    {
      return null;
    }
    final ByteArrayBuilder builder = new ByteArrayBuilder(size());
    builder.appendByte(MSG_TYPE_REPLICA_OFFLINE);
    builder.appendShort(protocolVersion);
opendj-sdk/opendj3-server-dev/src/server/org/opends/server/replication/protocol/ReplicationMsg.java
@@ -107,7 +107,8 @@
   * @param protocolVersion
   *          The protocol version to use for serialization. The version should
   *          normally be older than the current one.
   * @return The encoded PDU.
   * @return The encoded PDU, or <code>null</code> if the message isn't supported
   *          in that protocol version.
   */
  public abstract byte[] getBytes(short protocolVersion);
opendj-sdk/opendj3-server-dev/src/server/org/opends/server/replication/protocol/Session.java
@@ -319,6 +319,11 @@
  public void publish(final ReplicationMsg msg) throws IOException
  {
    final byte[] buffer = msg.getBytes(protocolVersion);
    if (buffer == null)
    {
      // skip anything that cannot be encoded for this peer.
      return;
    }
    if (isRunning.get())
    {
      while (!closeInitiated)