664acfa | Dmitry Marakasov | 15 September 2015, 11:44:16 UTC | Fix printf format for size_t | 15 September 2015, 18:00:52 UTC |
66a007f | Dmitry Marakasov | 15 September 2015, 11:41:00 UTC | Fix `integer overflow in expression' error | 15 September 2015, 18:00:45 UTC |
5559488 | sdong | 14 September 2015, 21:01:13 UTC | DBImpl::FindObsoleteFiles() shouldn't release mutex between getting min_pending_output and scanning files Summary: Releasing mutex between getting min_pending_output and scanning files may cause min_pending_output to be max but some non-final files are found in file scanning, ending up with deleting wrong files. As a recent regression, mutex can be released while waiting for log sync. We move it to after file scanning. Test Plan: Run all existing tests. Don't think it is easy to write a unit test. Maybe we should find a way to assert lock not released so that we can have some test verification for similar cases. Reviewers: igor, anthony, IslamAbdelRahman, kradhakrishnan, yhchiang, kolmike, rven Reviewed By: rven Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D46899 | 15 September 2015, 17:57:00 UTC |
d0ce28b | Islam AbdelRahman | 14 September 2015, 19:42:06 UTC | Fix compaction_job_stats under ROCKSDB_LITE Summary: Fix compaction_job_stats under ROCKSDB_LITE Test Plan: compile using ROCKSDB_LITE Reviewers: yhchiang, igor, sdong Reviewed By: sdong Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D46887 | 15 September 2015, 17:50:14 UTC |
2488020 | Andres Noetzli | 14 September 2015, 18:54:47 UTC | Relax asserts in arena_test Summary: Commit c67d2068988edccd0c732faec3d3c206089482c0 did not fix all test conditions which use Arena::MemoryAllocatedBytes() (see Travis failure https://travis-ci.org/facebook/rocksdb/jobs/79957700). The assumption of that commit was that aligned allocations do not call Arena::AllocateNewBlock(), so malloc_usable_block_size() would not be used for Arena::MemoryAllocatedBytes(). However, there is a code path where Arena::AllocateAligned() calls AllocateFallback() which in turn calls Arena::AllocateNewBlock(), so Arena::MemoryAllocatedBytes() may return a greater value than expected even for aligned requests. Test Plan: make arena_test && ./arena_test Reviewers: rven, anthony, yhchiang, aekmekji, igor, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46869 | 15 September 2015, 17:50:09 UTC |
af06d1a | agiardullo | 12 September 2015, 01:10:50 UTC | Transactions: Release Locks when rolling back to a savepoint Summary: Transaction::RollbackToSavePoint() will now release any locks that were taken since the previous SavePoint. To do this cleanly, I moved tracked_keys_ management into TransactionBase. Test Plan: New Transaction test. Reviewers: igor, rven, sdong Reviewed By: sdong Subscribers: dhruba, spetrunia, leveldb Differential Revision: https://reviews.facebook.net/D46761 | 15 September 2015, 17:50:01 UTC |
5266ed3 | Andres Noetzli | 11 September 2015, 19:32:59 UTC | Fixed arena_test failure due to malloc_usable_size() Summary: ArenaTest.MemoryAllocatedBytes on Travis failed: https://travis-ci.org/facebook/rocksdb/jobs/79887849 . This is probably due to malloc_usable_size() returning a value greater than the requested size. From the man page: The value returned by malloc_usable_size() may be greater than the requested size of the allocation because of alignment and minimum size constraints. Although the excess bytes can be overwritten by the application without ill effects, this is not good programming practice: the number of excess bytes in an allocation depends on the underlying implementation. Test Plan: make arena_test && ./arena_test Reviewers: rven, anthony, yhchiang, aekmekji, sdong, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46743 | 15 September 2015, 17:49:53 UTC |
7584091 | Andres Noetzli | 11 September 2015, 17:13:49 UTC | Fixed bug in compaction iterator Summary: During the refactoring, the condition that makes sure that compaction filters are only applied to records newer than the latest snapshot got butchered. This patch fixes the condition and adds a test case. Test Plan: make db_compaction_filter_test && ./db_compaction_filter_test Reviewers: rven, anthony, yhchiang, sdong, aekmekji, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46707 | 15 September 2015, 17:49:37 UTC |
af7cdbf | Igor Canadi | 10 September 2015, 03:30:00 UTC | Run full test suite in Travis Summary: With old travis infrastructure, we couldn't run the whole test suite without crashing. Now we transfered to the new architecture and are able to run full `make check` instead of just db_test. Test Plan: https://travis-ci.org/facebook/rocksdb/builds/79591564 This test has failed, true, but it's actual problem with tests: * t8316104 -- Failed ColumnFamilyTest.ReadDroppedColumnFamily and also https://github.com/facebook/rocksdb/issues/673 * Too many open files: db/db_universal_compaction_test.cc:514: Failure Put(1, Key(i % num_keys), Key(i)) IO error: /tmp/rocksdbtest-501/db_universal_compaction_prallel_test/000331.sst: Too many open files Reviewers: sdong, anthony, kradhakrishnan, IslamAbdelRahman Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46545 | 10 September 2015, 22:38:43 UTC |
c25f6a8 | Andres Noetzli | 10 September 2015, 22:16:32 UTC | Removed __unused__ attribute Summary: The current build is failing on some platforms due to an __unused__ attribute. This patch prevents the problem by using a pattern similar to MergeHelper (assert not on the variable but inside a condition that uses the variable). We should have better error handling in both cases in the future. Test Plan: make clean all check Reviewers: rven, anthony, yhchiang, sdong, igor, aekmekji Reviewed By: aekmekji Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46623 | 10 September 2015, 22:16:32 UTC |
6db0a93 | Ari Ekmekji | 10 September 2015, 21:37:00 UTC | Fix DBCompactionTest failure with parallel L0-L1 compactions Summary: The test SuggestCompactRangeNoTwoLevel0Compactions in DBCompactionTest fails when there are parallel L0-L1 compactions taking place because the test makes sure that only one compaction involving L0 takes place at any given time (since before having parallel compactions this was impossible). I changed the test to only run with DBOptions.max_subcompactions=1 so as to not hit this issue which is not a correctness issue but just an inherent changing of assumptions after introducing parallel compactions. This failed after landing https://reviews.facebook.net/D43269#inline-321303 so now this should fix it Test Plan: make all && make check Reviewers: yhchiang, igor, anthony, noetzli, sdong Reviewed By: sdong Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D46617 | 10 September 2015, 21:37:00 UTC |
8aa1f15 | Andres Noetzli | 10 September 2015, 21:35:25 UTC | Refactored common code of Builder/CompactionJob out into a CompactionIterator Summary: Builder and CompactionJob share a lot of fairly complex code. This patch refactors this code into a separate class, the CompactionIterator. Because the shared code is fairly complex, this patch hopefully improves maintainability. While there are is a lot of potential for further improvements, the patch is intentionally pretty close to the original structure because the change is already complex enough. Test Plan: make clean all check && ./db_stress Reviewers: rven, anthony, yhchiang, sdong, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46197 | 10 September 2015, 21:35:25 UTC |
41bce05 | krad | 09 September 2015, 23:32:26 UTC | CI job improvements Summary: Added more jobs and refactored code express the jobs more cleanly Test Plan: Manual test Reviewers: igor sdong CC: leveldb@ Task ID: #6968635 Blame Rev: | 10 September 2015, 21:29:41 UTC |
95ffc5d | Igor Canadi | 10 September 2015, 21:17:12 UTC | Correct ASSERT_OK() in ReadDroppedColumnFamily Summary: ReadDroppedColumnFamily is consistently failing in Travis CI environment (can't repro locally). I suspect it might be failing with non-OK status. This diff will give us more info about the failure. Test Plan: none Reviewers: sdong, kradhakrishnan Reviewed By: kradhakrishnan Subscribers: kradhakrishnan, dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46611 | 10 September 2015, 21:17:12 UTC |
3c37b3c | Ari Ekmekji | 10 September 2015, 20:50:00 UTC | Determine boundaries of subcompactions Summary: Up to this point, the subcompactions that make up a compaction job have been divided based on the key range of the L1 files, and each subcompaction has handled the key range of only one file. However DBOption.max_subcompactions allows the user to designate how many subcompactions at most to perform. This patch updates the CompactionJob::GetSubcompactionBoundaries() to determine these divisions accordingly based on that option and other input/system factors. The current approach orders the starting and/or ending keys of certain compaction input files and then generates a histogram to approximate the size covered by the key range between each consecutive pair of keys. Then it groups these ranges into groups so that the sizes are approximately equal to one another. The approach has also been adapted to work for universal compaction as well instead of just for level-based compaction as it was before. These subcompactions are then executed in parallel by locally spawning threads, one for each. The results are then aggregated and the compaction completed. Test Plan: make all && make check Reviewers: yhchiang, anthony, igor, noetzli, sdong Reviewed By: sdong Subscribers: MarkCallaghan, dhruba, leveldb Differential Revision: https://reviews.facebook.net/D43269 | 10 September 2015, 20:50:00 UTC |
1126644 | krad | 10 September 2015, 04:59:28 UTC | Relaxing consistency detection to include errors while inserting to memtable as WAL recovery error. Summary: The current code, considers data to be consistent if the record checksum passes. We do have customer issues where the record checksum passed but the data was incomprehensible. There is no way to get out of this error case since all WAL recovery model will consider this error as unrelated to WAL. Relaxing the definition and including errors while inserting to memtable as WAL errors and handing them as per the recovery level. Test Plan: Used customer dump to verify the fix for different level. The db opens for kSkipAnyCorruptedRecords and kPointInTimeRecovery, but fails for kAbsoluteConsistency and kTolerateCorruptedTailRecords. Reviewers: sdon igor CC: leveldb@ Task ID: #7918721 Blame Rev: | 10 September 2015, 19:56:17 UTC |
abc7f5f | sdong | 10 September 2015, 18:22:57 UTC | Make DBTest.ReadLatencyHistogramByLevel more robust Summary: DBTest.ReadLatencyHistogramByLevel was not written as expected. After writes, reads aren't guaranteed to hit data written. It was not expected. Fix it. Test Plan: Run the test multiple times Reviewers: IslamAbdelRahman, rven, anthony, kradhakrishnan, yhchiang, igor Reviewed By: igor Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D46587 | 10 September 2015, 18:32:19 UTC |
ac9bcb5 | Igor Canadi | 10 September 2015, 17:49:28 UTC | Set max_open_files based on ulimit Summary: We should never set max_open_files to be bigger than the system's ulimit. Otherwise we will get "Too many open files" errors. See an example in this Travis run: https://travis-ci.org/facebook/rocksdb/jobs/79591566 Test Plan: make check I will also verify that max_max_open_files is reasonable. Reviewers: anthony, kradhakrishnan, IslamAbdelRahman, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46551 | 10 September 2015, 17:49:28 UTC |
4cbd2f9 | Igor Canadi | 10 September 2015, 03:22:49 UTC | Merge pull request #714 from facebook/travisformac Run travis tests on OS X | 10 September 2015, 03:22:49 UTC |
d0df54d | Igor Canadi | 10 September 2015, 01:53:55 UTC | Run travis tests on OS X | 10 September 2015, 02:56:08 UTC |
a55e5a5 | Igor Canadi | 10 September 2015, 01:44:44 UTC | Merge pull request #711 from facebook/testtravis Upgrade travis to new architecture | 10 September 2015, 01:44:44 UTC |
2b676d5 | Igor Canadi | 10 September 2015, 00:55:33 UTC | Upgrade travis to new architecture | 10 September 2015, 01:40:35 UTC |
c66d53f | Andres Noetzli | 09 September 2015, 23:36:19 UTC | Fixed minor issue in CompressionTypeSupported() Summary: CompressionTypeSupported was returning LZ4_Supported() for kZSTDNotFinalCompression. This patch changes it to ZSTD_Supported(). Test Plan: make clean all check Reviewers: rven, anthony, yhchiang, sdong, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46521 | 09 September 2015, 23:36:19 UTC |
f3f2032 | Islam AbdelRahman | 09 September 2015, 23:01:03 UTC | Release RocksDB 4.0.0 Summary: Release RocksDB 4.0.0 Test Plan: no test Reviewers: sdong, yhchiang, anthony, rven, kradhakrishnan, igor Reviewed By: igor Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D46515 | 09 September 2015, 23:01:03 UTC |
44b6e99 | agiardullo | 09 September 2015, 00:54:35 UTC | update max_write_buffer_number_to_maintain docblock Summary: fix comment Test Plan: n/a Reviewers: sdong, IslamAbdelRahman Reviewed By: IslamAbdelRahman Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46455 | 09 September 2015, 20:36:38 UTC |
aa6eed0 | agiardullo | 25 August 2015, 02:13:18 UTC | Transaction stats Summary: Added funtions to fetch the number of locked keys in a transaction, the number of pending puts/merge/deletes, and the elapsed time Test Plan: unit tests Reviewers: yoshinorim, jkedgar, rven, sdong, yhchiang, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45417 | 09 September 2015, 20:35:53 UTC |
25dbc57 | agiardullo | 09 September 2015, 00:50:20 UTC | Update HISTORY file for transactions Summary: Move line about pessimistic transactions to the correct place in the history file and no longer refer to it as 'experimental' Test Plan: n/a Reviewers: igor, sdong, IslamAbdelRahman Reviewed By: IslamAbdelRahman Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46449 | 09 September 2015, 20:27:19 UTC |
52386a1 | krad | 09 September 2015, 17:41:07 UTC | Minor fix to sandcastle jobs commands Summary: Dropping parallel compilation since that seen to introduce compilation errors spuriously Test Plan: Run the command manually Reviewers: sdon igor CC: leveldb@ Task ID: #6968635 Blame Rev: | 09 September 2015, 17:54:50 UTC |
b5b2b75 | agiardullo | 01 September 2015, 21:43:23 UTC | better tuning of arena block size Summary: Currently, if users didn't set options.arena_block_size, we set "result.arena_block_size = result.write_buffer_size / 10". It makes result.arena_block_size not a multiplier of 4KB, even if options.write_buffer_size is a multiplier of MBs. When calling malloc to arena_block_size, we may waste a small amount of memory for it. We now make the default to be /8 or /16 and align it to 4KB. Test Plan: unit tests Reviewers: sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46467 | 09 September 2015, 03:53:32 UTC |
342ba80 | sdong | 09 September 2015, 01:31:36 UTC | Make DBTest.OptimizeFiltersForHits more deterministic Summary: This commit makes DBTest.OptimizeFiltersForHits more deterministic by: (1) make key inserts more random (2) make sure L0 has one file (3) make file size smaller compared to level target so L1 will cover more range. Test Plan: Run the test many times. Reviewers: rven, IslamAbdelRahman, kradhakrishnan, igor, anthony Reviewed By: anthony Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D46461 | 09 September 2015, 02:31:34 UTC |
e17e92e | Andres Notzli | 09 September 2015, 00:15:11 UTC | Relaxed assert in forward iterator Summary: It looks like in some cases an assert in SeekInternal failed when computing the hints for the next level because user_key was the same as the largest key and not strictly smaller. Relaxing the assert to expect smaller or equal keys. Test Plan: make clean all check Reviewers: sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46443 | 09 September 2015, 00:15:11 UTC |
5e94f68 | agiardullo | 08 September 2015, 19:36:48 UTC | TransactionDB Custom Locking API Summary: Prototype of API to allow MyRocks to override default Mutex/CondVar used by transactions with their own implementations. They would simply need to pass their own implementations of Mutex/CondVar to the templated TransactionDB::Open(). Default implementation of TransactionDBMutex/TransactionDBCondVar provided (but the code is not currently changed to use this). Let me know if this API makes sense or if it should be changed Test Plan: n/a Reviewers: yhchiang, rven, igor, sdong, spetrunia Reviewed By: spetrunia Subscribers: maykov, dhruba, leveldb Differential Revision: https://reviews.facebook.net/D43761 | 09 September 2015, 00:03:57 UTC |
0ccf2db | Andres Notzli | 08 September 2015, 22:46:16 UTC | Fixed broken build due to format specifier Summary: Clang expects %llu for uint64_t, while gcc expects %lu. Replaced the format specifier with a format macro. This should fix the build on gcc and Clang. Test Plan: Build on gcc and clang. Reviewers: rven, anthony, yhchiang, sdong, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46431 | 08 September 2015, 22:46:16 UTC |
6bdc484 | Andres Noetzli | 08 September 2015, 22:30:49 UTC | Added Equal method to Comparator interface Summary: In some cases, equality comparisons can be done more efficiently than three-way comparisons. There are quite a few places in the code where we only care about equality. This patch adds an Equal() method that defaults to using the Compare() method. Test Plan: make clean all check Reviewers: rven, anthony, yhchiang, igor, sdong Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46233 | 08 September 2015, 22:30:49 UTC |
7a31960 | Amit Arya | 08 September 2015, 21:23:42 UTC | Tests for ManifestDumpCommand and ListColumnFamiliesCommand Summary: Added tests for two LDBCommands namely i) ManifestDumpCommand and ii) ListColumnFamiliesCommand. + Minor fix in the sscanf formatter (along relace C cast with C++ cast) + replacing localtime with localtime_r which is thread safe. Test Plan: make all && ./tools/ldb_test.py Reviewers: anthony, igor, IslamAbdelRahman, kradhakrishnan, lgalanis, rven, sdong Reviewed By: sdong Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D45819 | 08 September 2015, 21:23:42 UTC |
778cf44 | krad | 04 September 2015, 19:25:15 UTC | Adding email notification. Summary: The email notifications needs to be at command level and the job level. Adding command level notification. Test Plan: Run command manually Reviewers: igor sdong CC: leveldb@ Task ID: #6968635 Blame Rev: | 08 September 2015, 21:19:03 UTC |
3a0df7f | Andres Noetzli | 08 September 2015, 16:47:54 UTC | Fixed comparison in ForwardIterator when computing hint for GetNextLevelIndex() Summary: When computing the hint for GetNextLevelIndex(), ForwardIterator was doing a redundant comparison. This patch fixes the comparison (using https://github.com/facebook/rocksdb/blob/master/db/version_set.cc#L158 as a reference) and moves it inside an assert because we expect `level_files[f_idx]` to contain the next key after Seek(), so user_key should always be smaller than the largest key. Test Plan: make clean all check Reviewers: rven, anthony, yhchiang, igor, sdong Reviewed By: sdong Subscribers: tnovak, sdong, dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46227 | 08 September 2015, 16:47:54 UTC |
91f3c90 | Venkatesh Radhakrishnan | 04 September 2015, 21:28:45 UTC | Fix case when forward iterator misses a new update Summary: This diff fixes a case when the forward iterator misses a new insert when the mutable iterator is not current. The test is also improved and the check for deleted iterators is made more informative. Test Plan: DBTailingIteratorTest.*Trim Reviewers: tnovak, sdong Reviewed By: sdong Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D46167 | 04 September 2015, 21:28:45 UTC |
ff1953c | Igor Canadi | 04 September 2015, 02:52:27 UTC | Merge pull request #707 from dkorolev/master Fixed a typo in INSTALL.md | 04 September 2015, 02:52:27 UTC |
7b463e6 | Dima | 04 September 2015, 02:46:09 UTC | Fixed a typo in INSTALL.md | 04 September 2015, 02:46:09 UTC |
d9f42aa | Mayank Pundir | 02 September 2015, 16:03:55 UTC | Adding a verifyBackup method to BackupEngine Summary: This diff adds a verifyBackup method to BackupEngine. The method verifies the name and size of each file in the backup. Test Plan: Unit test cases created and passing. Reviewers: igor, benj Subscribers: zelaine.fong, yhchiang, sdong, lgalanis, dhruba, AaronFeldman Differential Revision: https://reviews.facebook.net/D46029 | 04 September 2015, 00:27:21 UTC |
50dc5f0 | Paul Marinescu | 04 September 2015, 00:00:09 UTC | Replace BackupRateLimiter with GenericRateLimiter Summary: BackupRateLimiter removed and uses replaced with the existing GenericRateLimiter Test Plan: make all check make clean USE_CLANG=1 make all make clean OPT=-DROCKSDB_LITE make release Reviewers: leveldb, igor Reviewed By: igor Subscribers: igor, dhruba Differential Revision: https://reviews.facebook.net/D46095 | 04 September 2015, 00:00:09 UTC |
20ef64c | krad | 03 September 2015, 21:53:33 UTC | Moving jobs to use gcc-4.9 Summary: Fixed the glitch in Sandcastle and added gcc-4.9 support. Moving the jobs to 4.9 Test Plan: Manually run the script Reviewers: sdon igor CC: leveldb@ Task ID: #6968635 Blame Rev: | 03 September 2015, 22:20:36 UTC |
0f1aab6 | agiardullo | 01 September 2015, 23:51:49 UTC | Add SetLockTimeout for Transactions Summary: MyRocks wants to be able to change the lock timeout of a transaction that has already started. Expose existing SetLockTimeout function to users. Test Plan: unit test Reviewers: spetrunia, rven, sdong, yhchiang, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45987 | 03 September 2015, 03:07:19 UTC |
14456ae | Igor Canadi | 02 September 2015, 23:05:53 UTC | Fix compile Summary: There was a merge conflict with https://reviews.facebook.net/D45993 Test Plan: make check Reviewers: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46065 | 02 September 2015, 23:05:53 UTC |
76f286c | Igor Canadi | 02 September 2015, 22:36:47 UTC | Optimize bloom filter cache misses Summary: This optimizes the case when (cache_index_and_filter_blocks=1) and bloom filter is not present in the cache. Previously we did: 1. Read meta block from file 2. Read the filter position from the meta block 3. Read the filter Now, we pre-load the filter position on Table::Open(), so we can skip steps (1) and (2) on bloom filter cache miss. Instead of 2 IOs, we do only 1. Test Plan: make check Reviewers: sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46047 | 02 September 2015, 22:36:47 UTC |
0e6e547 | Yueh-Hsuan Chiang | 02 September 2015, 22:07:44 UTC | Fixed a compile warning in rocksjni/loggerjnicallback.cc Summary: This patch fixes the following compile warning. java/rocksjni/loggerjnicallback.cc: In constructor ‘rocksdb::LoggerJniCallback::LoggerJniCallback(JNIEnv*, jobject)’: java/rocksjni/loggerjnicallback.cc:19:14: warning: unused variable ‘rs’ [-Wunused-variable] const jint rs = env->GetJavaVM(&m_jvm); ^ Test Plan: make rocksdbjavastaticrelease Reviewers: sdong, anthony, IslamAbdelRahman, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45981 | 02 September 2015, 22:07:44 UTC |
b8a962d | krad | 02 September 2015, 19:16:42 UTC | Adding commands for few more CI jobs. Summary: Added commands to spawn crash, stress, asan, asan_crash, clang CI jobs Test Plan: Manual test Reviewers: sdong CC: leveldb@ Task ID: #6968635 Blame Rev: | 02 September 2015, 21:06:03 UTC |
8a2d59a | Igor Canadi | 02 September 2015, 21:04:51 UTC | Add Cloudera's blog post to USERS.md Summary: As title Test Plan: none Reviewers: yhchiang, rven, anthony, IslamAbdelRahman, kradhakrishnan, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D46053 | 02 September 2015, 21:04:51 UTC |
3c9cef1 | Andres Noetzli | 02 September 2015, 20:58:22 UTC | Unified maps with Comparator for sorting, other cleanup Summary: This diff is a collection of cleanups that were initially part of D43179. Additionally it adds a unified way of defining key-value maps that use a Comparator for sorting (this was previously implemented in four different places). Test Plan: make clean check all Reviewers: rven, anthony, yhchiang, sdong, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45993 | 02 September 2015, 20:58:22 UTC |
3e0a672 | sdong | 02 September 2015, 17:25:20 UTC | Bug fix: table readers created by TableCache::Get() doesn't have latency histogram reported Summary: TableCache::Get() puts parameters in the wrong places so that table readers created by Get() will not have the histogram updated. Test Plan: Will write a unit test for that. Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D46035 | 02 September 2015, 19:57:07 UTC |
b42cd6b | Igor Canadi | 02 September 2015, 18:49:49 UTC | Remove the need for LATEST_BACKUP in BackupEngine Summary: In the first implementation of BackupEngine, LATEST_BACKUP was the commit point. The backup became committed after the write to LATEST_BACKUP completed. However, we can avoid the need for LATEST_BACKUP. Instead of write to LATEST_BACKUP, the commit point can be the rename from `meta/<backup_id>.tmp` to `meta/<backup_id>`. Once we see that there exists a file `meta/<backup_id>` (without tmp), we can assume that backup is valid. In this diff, we still write out the file LATEST_BACKUP. We need to do this so that we can maintain backward compatibility. However, the new version doesn't depend on this file anymore. We get the latest backup by `ls`-ing `meta` directory. This diff depends on D41925 Test Plan: Adjusted backupable_db_test to this new behavior Reviewers: benj, yhchiang, sdong, AaronFeldman Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D42069 | 02 September 2015, 18:49:49 UTC |
0f763db | Siying Dong | 02 September 2015, 18:35:17 UTC | Merge pull request #705 from yuslepukhin/rate_limiter_fix Make WinEnv::NowMicros return system time | 02 September 2015, 18:35:17 UTC |
20c44fe | Amit Arya | 02 September 2015, 18:17:02 UTC | t6913679: Use fallocate on LOG FILESS Summary: Use fallocate on LOG FILES to Test Plan: make check + ===check with strace=== [arya@devvm1441 ~/rocksdb] strace -e trace=fallocate ./ldb --db=/tmp/test_new scan fallocate(3, 01, 0, 4194304) = 0 Reviewers: sdong, anthony, IslamAbdelRahman, kradhakrishnan, lgalanis, rven, igor Reviewed By: igor Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D45969 | 02 September 2015, 18:17:02 UTC |
f14c336 | Dmitri Smirnov | 02 September 2015, 18:12:07 UTC | Make WinEnv::NowMicros return system time Previous change for the function https://github.com/facebook/rocksdb/commit/555ca3e7b7f06bd01dfd5e04dbb2cef5360f7917#diff-bdc04e0404c2db4fd3ac5118a63eaa4a made use of the QueryPerformanceCounter to return microseconds values that do not repeat as std::chrono::system_clock returned values that made auto_roll_logger_test fail. The interface documentation does not state that we need to return system time describing the return value as a number of microsecs since some moment in time. However, because on Linux it is implemented using gettimeofday various pieces of code (such as GenericRateLimiter) took advantage of that and make use of NowMicros() as a system timestamp. Thus the previous change broke rate_limiter_test on Windows. In addition, the interface name NowMicros() suggests that it is actually a timestamp so people use it as such. This change makes use of the new system call on Windows that returns system time with required precision. This change preserves the fix for auto_roll_logger_test and fixes rate_limiter_test. Note that DBTest.RateLimitingTest still fails due to a separately reported issue. | 02 September 2015, 18:12:07 UTC |
aad0572 | Yueh-Hsuan Chiang | 01 September 2015, 18:07:43 UTC | Fixed the build issue of rocksdbjavastaticrelease Summary: This patch fixed couple build issues of rocksdbjavastaticrelease. Test Plan: make rocksdbjavastaticrelease Reviewers: sdong, anthony, IslamAbdelRahman, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45915 | 01 September 2015, 18:07:43 UTC |
5508122 | Tomislav Novak | 31 August 2015, 23:44:34 UTC | Fix a perf regression in ForwardIterator Summary: I noticed that memtable iterator usually crosses the `iterate_upper_bound` threshold when tailing. Changes introduced in D43833 made `NeedToSeekImmutable` always return true in such case, even when `Seek()` only needs to rewind the memtable iterator. In a test I ran, this caused the "tailing efficiency" (ratio of calls to `Seek()` that only affect the memtable versus all seeks) to drop almost to zero. This diff attempts to fix the regression by using a different flag to indicate that `current_` is over the limit instead of resetting `valid_` in `UpdateCurrent()`. Test Plan: `DBTestTailingIterator.TailingIteratorUpperBound` Reviewers: sdong, rven Reviewed By: rven Subscribers: dhruba, march Differential Revision: https://reviews.facebook.net/D45909 | 01 September 2015, 16:54:30 UTC |
b722007 | Andres Notzli | 01 September 2015, 06:11:12 UTC | Fix listener_test when using ROCKSDB_MALLOC_USABLE_SIZE Summary: Flushes in listener_test happened to early when ROCKSDB_MALLOC_USABLE_SIZE was active (e.g. when compiling with ROCKSDB_FBCODE_BUILD_WITH_481=1) due to malloc_usable_size() reporting a better estimate (similar to https://reviews.facebook.net/D43317 ). This patch grows the write buffer size slightly to compensate for this. Test Plan: ROCKSDB_FBCODE_BUILD_WITH_481=1 make listener_test && ./listener_test Reviewers: rven, anthony, yhchiang, igor, sdong Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45921 | 01 September 2015, 06:11:12 UTC |
40cd91b | Yueh-Hsuan Chiang | 01 September 2015, 01:36:17 UTC | Fixed compile warning in rocksdbjava Summary: Fixed the following compile warning in rocksdbjava: java/rocksjni/comparatorjnicallback.cc:20:14: warning: unused variable ‘rs’ [-Wunused-variable] const jint rs = env->GetJavaVM(&m_jvm); ^ java/rocksjni/comparatorjnicallback.cc: In member function ‘JNIEnv* rocksdb::BaseComparatorJniCallback::getJniEnv() const’: java/rocksjni/comparatorjnicallback.cc:45:8: warning: unused variable ‘rs’ [-Wunused-variable] jint rs = m_jvm->AttachCurrentThread(reinterpret_cast<void **>(&env), NULL); ^ java/rocksjni/loggerjnicallback.cc: In constructor ‘rocksdb::LoggerJniCallback::LoggerJniCallback(JNIEnv*, jobject)’: java/rocksjni/loggerjnicallback.cc:19:14: warning: unused variable ‘rs’ [-Wunused-variable] const jint rs = env->GetJavaVM(&m_jvm); ^ java/rocksjni/loggerjnicallback.cc: In member function ‘JNIEnv* rocksdb::LoggerJniCallback::getJniEnv() const’: java/rocksjni/loggerjnicallback.cc:33:8: warning: unused variable ‘rs’ [-Wunused-variable] jint rs = m_jvm->AttachCurrentThread(reinterpret_cast<void **>(&env), NULL); ^ Test Plan: make rocksdbjava -j32 Reviewers: sdong, anthony, IslamAbdelRahman, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45891 | 01 September 2015, 01:36:17 UTC |
90415cf | Yueh-Hsuan Chiang | 01 September 2015, 01:35:12 UTC | Fixed a compile warning in linux32 environment. Summary: Fixed the following compile warning in linux32 environment. ==> linux32: util/sst_dump_tool.cc: In member function ‘int rocksdb::SstFileReader::ShowAllCompressionSizes(size_t)’: ==> linux32: util/sst_dump_tool.cc:167:50: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘size_t {aka unsigned int}’ [-Wformat=] ==> linux32: fprintf(stdout, "Block Size: %lu\n", block_size); Test Plan: make sst_dump Reviewers: anthony, IslamAbdelRahman, sdong, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45885 | 01 September 2015, 01:35:12 UTC |
9d6503f | sdong | 31 August 2015, 23:20:40 UTC | Fix arena_test test break using glibc-2.17 Summary: arena_test is failing with glibc-2.17. Make it more robust Test Plan: Run arena_test using both of glibc-2.17 and 2.2 and make sure both passes. Reviewers: yhchiang, rven, IslamAbdelRahman, kradhakrishnan, igor Reviewed By: igor Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D45879 | 31 August 2015, 23:53:23 UTC |
77a2861 | agiardullo | 14 August 2015, 23:45:05 UTC | Support static Status messages Summary: Provide a way to specify a detailed static error message for a Status without incurring a memcpy. Let me know what people think of this approach. Test Plan: added simple test Reviewers: igor, yhchiang, rven, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D44259 | 31 August 2015, 23:13:29 UTC |
18db1e4 | agiardullo | 28 August 2015, 23:09:34 UTC | better db_bench options for transactions Summary: Pessimistic Transaction expiration time checking currently causes a performace regression, Lets disable it in db_bench by default. Also, in order to be able to better tune how much contention we're simulating, added new optinos to set lock timeout and snapshot. Test Plan: run db_bench randomtranansaction Reviewers: sdong, igor, yhchiang, MarkCallaghan Reviewed By: MarkCallaghan Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45831 | 31 August 2015, 22:56:07 UTC |
0be2605 | Igor Canadi | 31 August 2015, 20:48:26 UTC | Merge pull request #702 from PraveenSinghRao/remove_spurious remove spurious compression definitions | 31 August 2015, 20:48:26 UTC |
8b68954 | Ari Ekmekji | 31 August 2015, 19:59:02 UTC | Add Subcompactions to Universal Compaction Unit Tests Summary: Now that the approach to parallelizing L0-L1 level-based compactions by breaking the compaction job into subcompactions is being extended to apply to universal compactions as well, the unit tests need to account for this and run the universal compaction tests with subcompactions both enabled and disabled. Test Plan: make all && make check Reviewers: sdong, igor, noetzli, anthony, yhchiang Reviewed By: yhchiang Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D45657 | 31 August 2015, 19:59:02 UTC |
c6d870f | krad | 31 August 2015, 19:42:56 UTC | Merge branch 'arcpatch-D45741' | 31 August 2015, 19:42:56 UTC |
57b3a87 | krad | 31 August 2015, 19:37:26 UTC | Adding sandcastle determinator for RocksDB Summary: This fuels commands to be executed for different sandcastle jobs. This is a nice way to separate RocksDB specific commands from Sandcastle specific job definition. Test Plan: None. Will be tested when we add Sandcastle job. Reviewers: igor, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45741 | 31 August 2015, 19:37:26 UTC |
3d78eb6 | sdong | 26 August 2015, 21:19:31 UTC | Arena usage to be calculated using malloc_usable_size() Summary: malloc_usable_size() gets a better estimation of memory usage. It is already used to calculate block cache memory usage. Use it in arena too. Test Plan: Run all unit tests Reviewers: anthony, kradhakrishnan, rven, IslamAbdelRahman, yhchiang Reviewed By: yhchiang Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D43317 | 31 August 2015, 16:39:27 UTC |
effd9dd | Andres Noetzli | 29 August 2015, 01:06:32 UTC | Fix deadlock in WAL sync Summary: MarkLogsSynced() was doing `logs_.erase(it++);`. The standard is saying: ``` all iterators and references are invalidated, unless the erased members are at an end (front or back) of the deque (in which case only iterators and references to the erased members are invalidated) ``` Because `it` is an iterator to the first element of the container, it is invalidated, only one iteration is executed and `log.getting_synced = false;` is not being done, so `while (logs_.front().getting_synced)` in `WriteImpl()` is not terminating. Test Plan: make db_bench && ./db_bench --benchmarks=fillsync Reviewers: igor, rven, IslamAbdelRahman, anthony, kradhakrishnan, yhchiang, sdong, tnovak Reviewed By: tnovak Subscribers: kolmike, dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45807 | 29 August 2015, 01:06:32 UTC |
64f07de | Praveen Rao | 28 August 2015, 18:17:02 UTC | remove spurious compression definitions | 28 August 2015, 18:17:02 UTC |
72a9b73 | Andres Noetzli | 28 August 2015, 18:13:20 UTC | Removed unnecessary checks in DBTest.ApproximateMemoryUsage Summary: Just realized that after D45675, part of the code in DBTest.ApproximateMemoryUsage, does not really test anything anymore, so I removed it. Test Plan: make clean all check Reviewers: rven, igor, sdong, anthony, yhchiang Reviewed By: yhchiang Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45783 | 28 August 2015, 18:13:20 UTC |
cb164bf | Venkatesh Radhakrishnan | 28 August 2015, 18:07:07 UTC | Do not delete iterators for immutable memtables. Summary: The immutable memtable iterators are allocated from an arena and there is no benefit from deleting these. Also the immutable memtables themselves will continue to be in memory until the version set containing it is alive. We will not remove immutable memtable iterators over the upper bound. We now add immutable iterators to the test. Test Plan: db_tailing_iter_test.TailingIteratorTrimSeekToNext Reviewers: tnovak, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45597 | 28 August 2015, 18:07:07 UTC |
7a0dbdf | sdong | 27 August 2015, 22:40:42 UTC | Add ZSTD (not final format) compression type Summary: Add ZSTD compression type. The same way as adding LZ4. Test Plan: run all tests. Generate files in db_bench. Make sure reads succeed. But the SST files cannot be opened in older versions. Also some other adhoc tests. Reviewers: rven, anthony, IslamAbdelRahman, kradhakrishnan, igor Reviewed By: igor Subscribers: MarkCallaghan, maykov, yoshinorim, leveldb, dhruba Differential Revision: https://reviews.facebook.net/D45747 | 28 August 2015, 18:01:13 UTC |
e2db15e | Igor Canadi | 28 August 2015, 00:13:55 UTC | Merge pull request #701 from PraveenSinghRao/usewinapi_notcruntime Remove usage of C runtime API that has file handle limitation | 28 August 2015, 00:13:55 UTC |
e853191 | Andres Noetzli | 27 August 2015, 23:17:08 UTC | Fix DBTest.ApproximateMemoryUsage Summary: This patch fixes two issues in DBTest.ApproximateMemoryUsage: - It was possible that a flush happened between getting the two properties in Phase 1, resulting in different numbers for the properties and failing the assertion. This is fixed by waiting for the flush to finish before getting the properties. - There was a similar issue in Phase 2 and additionally there was an issue that rocksdb.size-all-mem-tables was not monotonically increasing because it was possible that a flush happened just after getting the properties and then another flush just before getting the properties in the next round. In this situation, the reported memory usage decreased. This is fixed by forcing a flush before getting the properties. Note: during testing, I found that kFlushesPerRound does not seem very accurate. I added a TODO for this and it would be great to get some input on what to do there. Test Plan: The first issue can be made more likely to trigger by inserting a `usleep(10000);` between the calls to GetIntProperty() in Phase 1. The second issue can be made more likely to trigger by inserting a `if (r != 0) usleep(10000);` before the calls to GetIntProperty() and a `usleep(10000);` after the calls. Then execute make db_test && ./db_test --gtest_filter=DBTest.ApproximateMemoryUsage Reviewers: rven, yhchiang, igor, sdong, anthony Reviewed By: anthony Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45675 | 27 August 2015, 23:17:08 UTC |
7c916a5 | Siying Dong | 27 August 2015, 17:06:48 UTC | Merge pull request #699 from OpenChannelSSD/to_fb_master Helper functions to support direct IO | 27 August 2015, 17:06:48 UTC |
0886f4f | Javier González | 26 August 2015, 13:28:09 UTC | Helper functions to support direct IO Summary: This patch adds the helper functions and variables to allow a backend implementing WritableFile to support direct IO when persisting a memtable. Test Plan: Since there is no upstream implementation of WritableFile supporting direct IO, the new behavior is disabled. Tests should be provided by the backend implementing WritableFile. | 27 August 2015, 06:36:56 UTC |
7e32798 | Praveen Rao | 27 August 2015, 01:51:18 UTC | Remove usage of C runtime API that has file handle limitation | 27 August 2015, 01:51:18 UTC |
8ef0144 | Yueh-Hsuan Chiang | 27 August 2015, 01:27:23 UTC | Add argument --show_table_properties to db_bench Summary: Add argument --show_table_properties to db_bench -show_table_properties (If true, then per-level table properties will be printed on every stats-interval when stats_interval is set and stats_per_interval is on.) type: bool default: false Test Plan: ./db_bench --show_table_properties=1 --stats_interval=100000 --stats_per_interval=1 ./db_bench --show_table_properties=1 --stats_interval=100000 --stats_per_interval=1 --num_column_families=2 Sample Output: Compaction Stats [column_family_name_000001] Level Files Size(MB) Score Read(GB) Rn(GB) Rnp1(GB) Write(GB) Wnew(GB) Moved(GB) W-Amp Rd(MB/s) Wr(MB/s) Comp(sec) Comp(cnt) Avg(sec) Stall(cnt) KeyIn KeyDrop --------------------------------------------------------------------------------------------------------------------------------------------------------------------- L0 3/0 5 0.8 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 86.3 0 17 0.021 0 0 0 L1 5/0 9 0.9 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0 0 0.000 0 0 0 L2 9/0 16 0.2 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0 0 0.000 0 0 0 Sum 17/0 31 0.0 0.0 0.0 0.0 0.0 0.0 0.0 1.0 0.0 86.3 0 17 0.021 0 0 0 Int 0/0 0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 1.0 0.0 83.9 0 2 0.022 0 0 0 Flush(GB): cumulative 0.030, interval 0.004 Stalls(count): 0 level0_slowdown, 0 level0_numfiles, 0 memtable_compaction, 0 leveln_slowdown_soft, 0 leveln_slowdown_hard Level[0]: # data blocks=2571; # entries=84813; raw key size=2035512; raw average key size=24.000000; raw value size=8481300; raw average value size=100.000000; data block size=5690119; index block size=82415; filter block size=0; (estimated) table size=5772534; filter policy name=N/A; Level[1]: # data blocks=4285; # entries=141355; raw key size=3392520; raw average key size=24.000000; raw value size=14135500; raw average value size=100.000000; data block size=9487353; index block size=137377; filter block size=0; (estimated) table size=9624730; filter policy name=N/A; Level[2]: # data blocks=7713; # entries=254439; raw key size=6106536; raw average key size=24.000000; raw value size=25443900; raw average value size=100.000000; data block size=17077893; index block size=247269; filter block size=0; (estimated) table size=17325162; filter policy name=N/A; Level[3]: # data blocks=0; # entries=0; raw key size=0; raw average key size=0.000000; raw value size=0; raw average value size=0.000000; data block size=0; index block size=0; filter block size=0; (estimated) table size=0; filter policy name=N/A; Level[4]: # data blocks=0; # entries=0; raw key size=0; raw average key size=0.000000; raw value size=0; raw average value size=0.000000; data block size=0; index block size=0; filter block size=0; (estimated) table size=0; filter policy name=N/A; Level[5]: # data blocks=0; # entries=0; raw key size=0; raw average key size=0.000000; raw value size=0; raw average value size=0.000000; data block size=0; index block size=0; filter block size=0; (estimated) table size=0; filter policy name=N/A; Level[6]: # data blocks=0; # entries=0; raw key size=0; raw average key size=0.000000; raw value size=0; raw average value size=0.000000; data block size=0; index block size=0; filter block size=0; (estimated) table size=0; filter policy name=N/A; Reviewers: anthony, IslamAbdelRahman, MarkCallaghan, sdong, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45651 | 27 August 2015, 01:27:23 UTC |
1fb2aba | Yueh-Hsuan Chiang | 26 August 2015, 23:13:56 UTC | ColumnFamilyOptions serialization / deserialization. Summary: This patch adds GetStringFromColumnFamilyOptions(), the inverse function of the existing GetColumnFamilyOptionsFromString(), and improves the implementation of GetColumnFamilyOptionsFromString(). Test Plan: Add a test in options_test.cc Reviewers: igor, sdong, anthony, IslamAbdelRahman Reviewed By: IslamAbdelRahman Subscribers: noetzli, dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45009 | 26 August 2015, 23:13:56 UTC |
5f4166c | Igor Canadi | 26 August 2015, 22:25:59 UTC | ReadaheadRandomAccessFile -- userspace readahead Summary: ReadaheadRandomAccessFile acts as a transparent layer on top of RandomAccessFile. When a Read() request is issued, it issues a much bigger request to the OS and caches the result. When a new request comes in and we already have the data cached, it doesn't have to issue any requests to the OS. We add ReadaheadRandomAccessFile layer only when file is read during compactions. D45105 was incorrectly closed by Phabricator because I committed it to a separate branch (not master), so I'm resubmitting the diff. Test Plan: make check Reviewers: MarkCallaghan, sdong Reviewed By: sdong Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D45123 | 26 August 2015, 22:25:59 UTC |
16ebe3a | Igor Canadi | 26 August 2015, 21:51:38 UTC | Mmap reads should not return error if reading past file Summary: Currently, mmap returns IOError when user tries to read data past the end of the file. This diff changes the behavior. Now, we return just the bytes that we can, and report the size we returned via a Slice result. This is consistent with non-mmap behavior and also pread() system call. This diff is taken out of D45123. Test Plan: make check Reviewers: sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45645 | 26 August 2015, 21:51:38 UTC |
d286b5d | sdong | 25 August 2015, 20:40:52 UTC | DBIter to out extra keys with higher sequence numbers when changing direction from forward to backward Summary: When DBIter changes iterating direction from forward to backward, it might see some much larger keys with higher sequence ID. With this commit, these rows will be actively filtered out. It should fix existing disabled tests in db_iter_test. This may not be a perfect fix, but it introduces least impact on existing codes, in order to be safe. Test Plan: Enable existing tests and make sure they pass. Add a new test DBIterWithMergeIterTest.InnerMergeIteratorDataRace8. Also run all existing tests. Reviewers: yhchiang, rven, anthony, IslamAbdelRahman, kradhakrishnan, igor Reviewed By: igor Subscribers: leveldb, dhruba Differential Revision: https://reviews.facebook.net/D45567 | 26 August 2015, 20:01:39 UTC |
3795449 | Andres Noetzli | 26 August 2015, 17:10:26 UTC | Fix DBTest.GetProperty Summary: DBTest.GetProperty was failing occasionally (see task #8131266). The reason was that the test closed the database before the compaction was done. When the test reopened the database, RocksDB would schedule a compaction which in turn created table readers and lead the test to fail the assertion that rocksdb.estimate-table-readers-mem is 0. In most cases, GetIntProperty() of rocksdb.estimate-table-readers-mem happened before the compaction created the table readers, hiding the problem. This patch changes the WaitForFlushMemTable() to WaitForCompact(). WaitForFlushMemTable() is not necessary because it is already being called a couple of lines before without any insertions in-between. Test Plan: Insert `usleep(10000);` just after `Reopen(options);` on line 2333 to make the issue more likely, then run: make db_test && while ./db_test --gtest_filter=DBTest.GetProperty; do true; done Reviewers: rven, yhchiang, anthony, igor, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45603 | 26 August 2015, 17:10:26 UTC |
a7834a1 | Igor Canadi | 26 August 2015, 00:15:23 UTC | Merge pull request #698 from yuslepukhin/address_noexcept_windows Address noexcept and const integer lambda capture on win | 26 August 2015, 00:15:23 UTC |
9ccf1bd | Yueh-Hsuan Chiang | 25 August 2015, 23:45:23 UTC | Correct the comment for GetProperty() API. Summary: "rocksdb.aggregated-table-properties" and "rocksdb.aggregated-table-properties-at-level<N>" should belong to GetProperty() instead of GetIntProperty(), but the comment mistakenly classifies them to GetIntProperty(). This patch fix this comment error. Test Plan: no code change. Reviewers: sdong, anthony, IslamAbdelRahman, igor Reviewed By: igor Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D45561 | 25 August 2015, 23:45:23 UTC |
fbe2c05 | Dmitri Smirnov | 25 August 2015, 23:34:39 UTC | s/NOEXCEPT/ROCKSDB_NOEXCEPT | 25 August 2015, 23:34:39 UTC |
6924d75 | Dmitri Smirnov | 25 August 2015, 22:17:14 UTC | Address noexcept and const integer lambda capture VS 2013 does not support noexcept. Complains about usage of ineteger constant within lambda requiring explicit capture. | 25 August 2015, 22:17:14 UTC |
2f8d71e | Ari Ekmekji | 25 August 2015, 21:03:10 UTC | Moving sequence number compaction variables from SubCompactionState to CompactionJob Summary: It was pointed out to me that the members of SubCompactionState 'earliest_snapshot', 'latest_snapshot' and 'visible_at_tip' are never modified by the subcompactions, so they can stay as global varaibles instead to make things simpler. Test Plan: make all && make check Reviewers: sdong, igor, noetzli, anthony, yhchiang Reviewed By: yhchiang Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D45477 | 25 August 2015, 21:03:10 UTC |
bab9934 | Venkatesh Radhakrishnan | 25 August 2015, 21:02:03 UTC | Fix build failure caused by bad merge. Summary: There was a bad merge during refresh. Test Plan: make -j all; make check Reviewers: sdong Reviewed By: sdong Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D45555 | 25 August 2015, 21:02:03 UTC |
4d28a7d | Venkatesh Radhakrishnan | 25 August 2015, 20:40:58 UTC | Add a whitebox test for deleted file iterators. Summary: We have earlier added a feature to delete file iterators when the current key is over the iterate upper bound. We now add a whitebox test to check if the file iterators were actually deleted. Test Plan: Add check for a range which has deleted iterators. Reviewers: sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45321 | 25 August 2015, 20:40:58 UTC |
249fb4f | Venkatesh Radhakrishnan | 25 August 2015, 20:38:35 UTC | Fix use of deleted file iterators with incomplete iterators Summary: After deleting file iterators which are over the iterate upper bound, we also need to check for null pointers in ResetIncompletIterators. Test Plan: db_tailing_iter_test.TailingIteratorTrimSeekToNext Reviewers: tnovak, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45525 | 25 August 2015, 20:38:35 UTC |
53b8878 | Igor Canadi | 25 August 2015, 20:32:46 UTC | Add throttling to multi-threaded backups Summary: See internal task t8056182 Test Plan: Added multi-threading in RateLimiter test Reviewers: benj, AaronFeldman Reviewed By: AaronFeldman Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45459 | 25 August 2015, 20:32:46 UTC |
09d982f | Andres Notzli | 25 August 2015, 19:29:44 UTC | Fix compact_files_example Summary: See task #7983654. The example was triggering an assert in compaction job because the compaction was not marked as manual. With this patch, CompactionPicker::FormCompaction() marks compactions as manual. This patch also fixes a couple of typos, adds optimistic_transaction_example to .gitignore and librocksdb as a dependency for examples. Adding librocksdb as a dependency makes sure that the examples are built with the latest changes in librocksdb. Test Plan: make clean && cd examples && make all && ./compact_files_example Reviewers: rven, sdong, anthony, igor, yhchiang Reviewed By: yhchiang Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45117 | 25 August 2015, 19:29:44 UTC |
6996de8 | Yueh-Hsuan Chiang | 25 August 2015, 19:03:54 UTC | Expose per-level aggregated table properties via GetProperty() Summary: This patch adds "rocksdb.aggregated-table-properties" and "rocksdb.aggregated-table-properties-at-levelN", the former returns the aggreated table properties of a column family, while the later returns the aggregated table properties of the specified level N. Test Plan: Added tests in db_test Reviewers: igor, sdong, IslamAbdelRahman, anthony Reviewed By: anthony Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45087 | 25 August 2015, 19:03:54 UTC |
86d6c3c | agiardullo | 25 August 2015, 17:50:27 UTC | Fix Windows build Summary: wrong filename Test Plan: none Reviewers: sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45531 | 25 August 2015, 18:02:31 UTC |
20d1e54 | agiardullo | 21 August 2015, 22:47:21 UTC | Common base class for transactions Summary: As I keep adding new features to transactions, I keep creating more duplicate code. This diff cleans this up by creating a base implementation class for Transaction and OptimisticTransaction to inherit from. The code in TransactionBase.h/.cc is all just copied from elsewhere. The only entertaining part of this class worth looking at is the virtual TryLock method which allows OptimisticTransactions and Transactions to share the same common code for Put/Get/etc. The rest of this diff is mostly red and easy on the eyes. Test Plan: No functionality change. existing tests pass. Reviewers: sdong, jkedgar, rven, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45135 | 25 August 2015, 02:09:43 UTC |
2050832 | Andres Noetzli | 25 August 2015, 00:04:18 UTC | Fixing race condition in DBTest.DynamicMemtableOptions Summary: This patch fixes a race condition in DBTEst.DynamicMemtableOptions. In rare cases, it was possible that the main thread would fill up both memtables before the flush job acquired its work. Then, the flush job was flushing both memtables together, producing only one L0 file while the test expected two. Now, the test waits for flushes to finish earlier, to make sure that the memtables are flushed in separate flush jobs. Test Plan: Insert "usleep(10000);" after "IOSTATS_SET_THREAD_POOL_ID(Env::Priority::HIGH);" in BGWorkFlush() to make the issue more likely. Then test with: make db_test && time while ./db_test --gtest_filter=*DynamicMemtableOptions; do true; done Reviewers: rven, sdong, yhchiang, anthony, igor Reviewed By: igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45429 | 25 August 2015, 00:04:18 UTC |
e46bcc0 | Igor Canadi | 24 August 2015, 23:43:18 UTC | Remove an extra 's' from cur-size-all-mem-tabless Summary: As title Test Plan: make check Reviewers: yhchiang Reviewed By: yhchiang Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D45447 | 24 August 2015, 23:43:18 UTC |
4ab26c5 | Igor Canadi | 24 August 2015, 18:11:12 UTC | Smarter purging during flush Summary: Currently, we only purge duplicate keys and deletions during flush if `earliest_seqno_in_memtable <= newest_snapshot`. This means that the newest snapshot happened before we first created the memtable. This is almost never true for MyRocks and MongoRocks. This patch makes purging during flush able to understand snapshots. The main logic is copied from compaction_job.cc, although the logic over there is much more complicated and extensive. However, we should try to merge the common functionality at some point. I need this patch to implement no_overwrite_i_promise functionality for flush. We'll also need this to support SingleDelete() during Flush(). @yoshinorim requested the feature. Test Plan: make check I had to adjust some unit tests to understand this new behavior Reviewers: yhchiang, yoshinorim, anthony, sdong, noetzli Reviewed By: noetzli Subscribers: yoshinorim, dhruba, leveldb Differential Revision: https://reviews.facebook.net/D42087 | 24 August 2015, 18:11:12 UTC |