public void releaseResources() {
    try {
      close();
    } catch (IOException e) {
      LOG.debug(e.toString(), e);
    }
    // Return back all the BBs to pool
    for (ByteBuff buf : this.allBufs) {
      buf.release();
    }
    this.allBufs = null;
    this.curBuf = null;
  }
Release the resources it uses (The ByteBuffers) which are obtained from pool. Call this only
when all the data is fully used. And it must be called at the end of usage else we will leak
ByteBuffers from pool.
hbase-common/src/main/java/org/apache/hadoop/hbase/io/ByteBufferListOutputStream.java