facebook / facebook/rocksdb

options_util_test fails if vector size is 0

Open
#9,364 4 comments 0 reactions 1 assignee Claimed by @sg20180546 View on GitHub
enhancement
Dominant language
C++
Stars
32.1k
Forks
6.9k
Avg merge
32m
Merged PRs (30d)
1

Description

### Expected behavior
options_util_test to succeed every time.

### Actual behavior

utilities/options/options_util_test.cc:62: Failure
PersistRocksDBOptions(db_opt, cf_names, cf_opts, kFileName, env_->GetFileSystem().get())
Invalid argument: [RocksDBOptionsParser]: failed the verification on ColumnFamilyOptions::max_bytes_for_level_multiplier_additional--- The specified one is while the persisted one is 1:1:1:1:1:1:1.

### Steps to reproduce the behavior

My machine is regularly creating a "random" column family with zero as the number of levels. This leads to the max_bytes_for_level_multiplier_additional vector to be of size zero. Looks like the code reading the "persisted" is leaving the vector in an default state instead of clearing it.

forcing the number of levels to size 1 or larger fixed the problem.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.