@Override
  public Future<Long> write(ByteBuffer src, Callback<Long> callback) {
    if (src == null) {
      throw new IllegalArgumentException("Source buffer cannot be null");
    }
    ChunkData chunkData = new ChunkData(src, callback);
    chunks.add(chunkData);
    if (!isOpen()) {
      resolveAllRemainingChunks(new ClosedChannelException());
    }
    return chunkData.future;
  }
If the channel is open, simply queues the buffer to be handled later.
@param src the data that needs to be written to the channel.
@param callback the {@link Callback} that will be invoked once the write succeeds/fails. This can be null.
@return a {@link Future} that will eventually contain the result of the write operation.
@throws IllegalArgumentException if {@code src} is null.
ambry-test-utils/src/main/java/com/github/ambry/router/ByteBufferAWC.java