dump_manifest supports DB with more number of levels

Summary: Now ldb dump_manifest refuses to work if there are 20 levels. Extend the limit to 64.

Test Plan: Run the tool with 20 number of levels

Reviewers: kradhakrishnan, anthony, IslamAbdelRahman, yhchiang

Reviewed By: yhchiang

Subscribers: leveldb, dhruba

Differential Revision: https://reviews.facebook.net/D42879
This commit is contained in:
sdong 2015-08-03 11:01:24 -07:00
parent bd852bf118
commit 47316c2d08

View File

@ -537,6 +537,7 @@ void DumpManifestFile(std::string file, bool verbose, bool hex, bool json) {
// if VersionSet::DumpManifest() depends on any option done by // if VersionSet::DumpManifest() depends on any option done by
// SanitizeOptions(), we need to initialize it manually. // SanitizeOptions(), we need to initialize it manually.
options.db_paths.emplace_back("dummy", 0); options.db_paths.emplace_back("dummy", 0);
options.num_levels = 64;
WriteController wc(options.delayed_write_rate); WriteController wc(options.delayed_write_rate);
WriteBuffer wb(options.db_write_buffer_size); WriteBuffer wb(options.db_write_buffer_size);
VersionSet versions(dbname, &options, sopt, tc.get(), &wb, &wc); VersionSet versions(dbname, &options, sopt, tc.get(), &wb, &wc);