@Override
  public int available() {
    long available = _dataBuffer.size() - _currentOffset;
    if (available > Integer.MAX_VALUE) {
      return Integer.MAX_VALUE;
    } else {
      return (int) available;
    }
  }
@Test
  void testAvailable() {
    assertEquals(_dataBufferPinotInputStream.available(), BUFFER_SIZE);
    _dataBufferPinotInputStream.seek(1);
    assertEquals(_dataBufferPinotInputStream.available(), BUFFER_SIZE - 1);
  }