private void deleteLogFiles(Path parent, String fileName) throws IOException {
    DirectoryStream<Path> stream =
        Files.newDirectoryStream(parent, fileName + ".*");
    for (Path path : stream) {
      Files.delete(path);
    }
  }
Test configuration and use of SlidingFilenameRolloverStrategy
@see SlidingFilenameRolloverStrategy
ql/src/test/org/apache/hadoop/hive/ql/log/TestSlidingFilenameRolloverStrategy.java