@Test
  public void testGetIntStringLength() {
    for (int i = 0; i < 10; i++) {
      String value = TestUtils.getRandomString(1000 + TestUtils.RANDOM.nextInt(10000));
      assertEquals("Size mismatch ", Integer.BYTES + value.length(), Utils.getIntStringLength(value));
    }
    assertEquals("Size mismatch for empty string ", Integer.BYTES, Utils.getIntStringLength(""));
    assertEquals("Size mismatch for null string ", Integer.BYTES, Utils.getIntStringLength(null));
  }
Return the internal byte array of the given {@link ByteBuffer}. It only works when the {@link ByteBuffer} is not
a direct {@link ByteBuffer}.
@param buffer The {@link ByteBuffer}.
@return The internal byte array.
@throws Exception Any unexpected error.
ambry-utils/src/test/java/com/github/ambry/utils/UtilsTest.java