public void release(@NotNull ByteBuffer buffer) {
    if (buffer.isReadOnly()) {
      // slice of mapped byte buffer
      return;
    }

    // limit is set on allocate
    buffer.rewind();
    buffer.order(ByteOrder.BIG_ENDIAN);
    // keep the only buffer for size
    if (count.get() < MAX_POOL_SIZE && pool.putIfAbsent(buffer.capacity(), buffer) == null) {
      count.incrementAndGet();
    }
    else {
      this.releaser.accept(buffer);
    }
  }
public void release(@NotNull ByteBuffer buffer)