private void checkLogReload(long originalLogCapacity, long originalSegmentCapacity, List<LogSegmentName> allSegmentNames)
      throws IOException, StoreException {
    // modify the segment capacity (mimics modifying the config)
    long[] newConfigs = {originalSegmentCapacity - 1, originalSegmentCapacity + 1};
    for (long newConfig : newConfigs) {
      Log log = new Log(tempDir.getAbsolutePath(), originalLogCapacity, StoreTestUtils.DEFAULT_DISK_SPACE_ALLOCATOR,
          createStoreConfig(newConfig, true), metrics, null);
      try {
        // the new config should be ignored.
        checkLog(log, originalSegmentCapacity, allSegmentNames);
      } finally {
        log.close(false);
      }
    }
  }
Reloads a {@link Log} (by creating a new instance) that already has segments and mimics changed configs and ensures
that the config is ignored.
@param originalLogCapacity the original total capacity of the log.
@param originalSegmentCapacity the original segment capacity of the log.
@param allSegmentNames the expected names of the all the segments.
@throws IOException
ambry-store/src/test/java/com/github/ambry/store/LogTest.java