From f2b4939da4ee7cc2c967e5bcabe468c5226fbb1d Mon Sep 17 00:00:00 2001 From: Hyeonseok Oh Date: Mon, 23 Jan 2017 12:50:40 -0800 Subject: [PATCH] fixed typo Summary: I fixed exisit -> exist Closes https://github.com/facebook/rocksdb/pull/1799 Differential Revision: D4451466 Pulled By: yiwu-arbug fbshipit-source-id: b447c3a --- db/db_sst_test.cc | 2 +- db/external_sst_file_test.cc | 8 ++++---- include/rocksdb/options.h | 2 +- include/rocksdb/sst_file_manager.h | 4 ++-- util/sst_file_manager_impl.cc | 6 +++--- utilities/persistent_cache/block_cache_tier.cc | 4 ++-- 6 files changed, 13 insertions(+), 13 deletions(-) diff --git a/db/db_sst_test.cc b/db/db_sst_test.cc index fd4304379..fb0c39077 100644 --- a/db/db_sst_test.cc +++ b/db/db_sst_test.cc @@ -613,7 +613,7 @@ TEST_F(DBSSTTest, OpenDBWithInfiniteMaxOpenFiles) { } Close(); - // Reopening the DB will load all exisitng files + // Reopening the DB will load all existing files Reopen(options); ASSERT_EQ("12,0,12", FilesPerLevel(0)); std::vector> files; diff --git a/db/external_sst_file_test.cc b/db/external_sst_file_test.cc index 210017cba..4bb75d075 100644 --- a/db/external_sst_file_test.cc +++ b/db/external_sst_file_test.cc @@ -258,11 +258,11 @@ TEST_F(ExternalSSTFileTest, Basic) { ASSERT_EQ(Get(Key(k)), Key(k) + "_val"); } - // This file has overlapping values with the exisitng data + // This file has overlapping values with the existing data s = DeprecatedAddFile({file3}); ASSERT_FALSE(s.ok()) << s.ToString(); - // This file has overlapping values with the exisitng data + // This file has overlapping values with the existing data s = DeprecatedAddFile({file4}); ASSERT_FALSE(s.ok()) << s.ToString(); @@ -510,7 +510,7 @@ TEST_F(ExternalSSTFileTest, AddList) { ASSERT_EQ(user_props["xyz_Count"], "100"); } - // This file list has overlapping values with the exisitng data + // This file list has overlapping values with the existing data s = DeprecatedAddFile(file_list3); ASSERT_FALSE(s.ok()) << s.ToString(); @@ -705,7 +705,7 @@ TEST_F(ExternalSSTFileTest, NoCopy) { ASSERT_TRUE(s.ok()) << s.ToString(); ASSERT_OK(env_->FileExists(file2)); - // This file have overlapping values with the exisitng data + // This file have overlapping values with the existing data s = DeprecatedAddFile({file2}, true /* move file */); ASSERT_FALSE(s.ok()) << s.ToString(); ASSERT_OK(env_->FileExists(file3)); diff --git a/include/rocksdb/options.h b/include/rocksdb/options.h index c0ab3edda..c50ca6c79 100644 --- a/include/rocksdb/options.h +++ b/include/rocksdb/options.h @@ -1508,7 +1508,7 @@ struct ReadOptions { // used in the table. Some table format (e.g. plain table) may not support // this option. // If true when calling Get(), we also skip prefix bloom when reading from - // block based table. It provides a way to read exisiting data after + // block based table. It provides a way to read existing data after // changing implementation of prefix extractor. bool total_order_seek; diff --git a/include/rocksdb/sst_file_manager.h b/include/rocksdb/sst_file_manager.h index bee243e4a..f8fee2742 100644 --- a/include/rocksdb/sst_file_manager.h +++ b/include/rocksdb/sst_file_manager.h @@ -68,13 +68,13 @@ class SstFileManager { // this value is set to 1024 (1 Kb / sec) and we deleted a file of size 4 Kb // in 1 second, we will wait for another 3 seconds before we delete other // files, Set to 0 to disable deletion rate limiting. -// @param delete_exisitng_trash: If set to true, the newly created +// @param delete_existing_trash: If set to true, the newly created // SstFileManager will delete files that already exist in trash_dir. // @param status: If not nullptr, status will contain any errors that happened // during creating the missing trash_dir or deleting existing files in trash. extern SstFileManager* NewSstFileManager( Env* env, std::shared_ptr info_log = nullptr, std::string trash_dir = "", int64_t rate_bytes_per_sec = 0, - bool delete_exisitng_trash = true, Status* status = nullptr); + bool delete_existing_trash = true, Status* status = nullptr); } // namespace rocksdb diff --git a/util/sst_file_manager_impl.cc b/util/sst_file_manager_impl.cc index cff9a7389..208971cb5 100644 --- a/util/sst_file_manager_impl.cc +++ b/util/sst_file_manager_impl.cc @@ -122,14 +122,14 @@ void SstFileManagerImpl::OnDeleteFileImpl(const std::string& file_path) { SstFileManager* NewSstFileManager(Env* env, std::shared_ptr info_log, std::string trash_dir, int64_t rate_bytes_per_sec, - bool delete_exisitng_trash, Status* status) { + bool delete_existing_trash, Status* status) { SstFileManagerImpl* res = new SstFileManagerImpl(env, info_log, trash_dir, rate_bytes_per_sec); Status s; if (trash_dir != "" && rate_bytes_per_sec > 0) { s = env->CreateDirIfMissing(trash_dir); - if (s.ok() && delete_exisitng_trash) { + if (s.ok() && delete_existing_trash) { std::vector files_in_trash; s = env->GetChildren(trash_dir, &files_in_trash); if (s.ok()) { @@ -161,7 +161,7 @@ SstFileManager* NewSstFileManager(Env* env, std::shared_ptr info_log, SstFileManager* NewSstFileManager(Env* env, std::shared_ptr info_log, std::string trash_dir, int64_t rate_bytes_per_sec, - bool delete_exisitng_trash, Status* status) { + bool delete_existing_trash, Status* status) { if (status) { *status = Status::NotSupported("SstFileManager is not supported in ROCKSDB_LITE"); diff --git a/utilities/persistent_cache/block_cache_tier.cc b/utilities/persistent_cache/block_cache_tier.cc index d81cb789a..585e61051 100644 --- a/utilities/persistent_cache/block_cache_tier.cc +++ b/utilities/persistent_cache/block_cache_tier.cc @@ -45,7 +45,7 @@ Status BlockCacheTier::Open() { // Create base/ directory status = opt_.env->CreateDir(GetCachePath()); if (!status.ok()) { - // directory already exisits, clean it up + // directory already exists, clean it up status = CleanupCacheFolder(GetCachePath()); assert(status.ok()); if (!status.ok()) { @@ -226,7 +226,7 @@ Status BlockCacheTier::InsertImpl(const Slice& key, const Slice& data) { LBA lba; if (metadata_.Lookup(key, &lba)) { - // the key already exisits, this is duplicate insert + // the key already exists, this is duplicate insert return Status::OK(); }