Skip to content

Commit

Permalink
Trim log file options sizes in test
Browse files Browse the repository at this point in the history
  • Loading branch information
alanpaxton committed Oct 2, 2024
1 parent f014680 commit f9db2de
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions java/src/test/java/org/rocksdb/util/LoggerFromOptionsTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -44,18 +44,18 @@ public void openReadOnlyWithLoggerFromOptions() throws RocksDBException, IOExcep

// Expect these configured options to be output in the log
List<String> remainingMatches = new ArrayList<>(
Arrays.asList("Options.max_log_file_size: 1048576", "Options.log_file_time_to_roll: 2048",
"Options.keep_log_file_num: 24", "Options.recycle_log_file_num: 8"));
Arrays.asList("Options.max_log_file_size: 65536", "Options.log_file_time_to_roll: 2048",
"Options.keep_log_file_num: 8", "Options.recycle_log_file_num: 3"));

// Configure the log in order for the dump of log configuration to the log to be unique
// Open the DB readonly and give it the new logger to use
try (final Options options = new Options()
.setInfoLogLevel(InfoLogLevel.DEBUG_LEVEL)
.setLogger(logger)
.setMaxLogFileSize(1024L * 1024L)
.setRecycleLogFileNum(8)
.setMaxLogFileSize(1024L * 64L)
.setRecycleLogFileNum(3)
.setLogFileTimeToRoll(2048)
.setKeepLogFileNum(24);
.setKeepLogFileNum(8);
final RocksDB db = RocksDB.openReadOnly(options, dbFolder.getRoot().getAbsolutePath())) {
assertThat(db.getDBOptions()).isNotNull();
}
Expand Down

0 comments on commit f9db2de

Please sign in to comment.