public void sendReplEvent(ReplEvent event,boolean forceSend) throws IOException {
  if (buffering) {
    buffer.add(event);
    if (forceSend || buffer.size() >= bufferSize) {
      writeMessage(new ProtocolMessage(buffer));
      buffer.clear();
    }
  }
 else {
    writeMessage(new ProtocolReplEvent(event));
  }
}

public void sendReplEvent ( ReplEvent event , boolean forceSend ) throws IOException { if ( buffering ) { buffer . add ( event ) ; if ( forceSend || buffer . size ( ) >= bufferSize ) { writeMessage ( new ProtocolMessage ( buffer ) ) ; buffer . clear ( ) ; } } else { writeMessage ( new ProtocolReplEvent ( event ) ) ; } }
send a replication event to the client .
