rocksdb/db
Yi Wu c2247dc1c7 Make DBImpl::has_unpersisted_data_ atomic
Summary:
Seems to me `has_unpersisted_data_` is read from read thread and write
from write thread concurrently without synchronization. Making it an
atomic.

I update the logic not because seeing any problem with it, but it just
feel confusing.
Closes https://github.com/facebook/rocksdb/pull/1869

Differential Revision: D4555837

Pulled By: yiwu-arbug

fbshipit-source-id: eff2ab8
2017-02-13 18:54:13 -08:00
..
auto_roll_logger.cc
auto_roll_logger.h
auto_roll_logger_test.cc Windows thread 2017-02-06 14:54:18 -08:00
builder.cc Remove disableDataSync option 2017-02-13 11:09:13 -08:00
builder.h Remove Arena in RangeDelAggregator 2016-11-19 14:24:12 -08:00
c.cc Remove disableDataSync option 2017-02-13 11:09:13 -08:00
c_test.c c: allow set savepoint to writebatch 2017-01-20 13:24:13 -08:00
column_family.cc Fix for 2PC causing WAL to grow too large 2017-01-19 15:39:12 -08:00
column_family.h Fix for 2PC causing WAL to grow too large 2017-01-19 15:39:12 -08:00
column_family_test.cc Remove disableDataSync option 2017-02-13 11:09:13 -08:00
compact_files_test.cc Windows thread 2017-02-06 14:54:18 -08:00
compacted_db_impl.cc Revert "PinnableSlice" 2017-01-08 14:24:12 -08:00
compacted_db_impl.h Disable IngestExternalFile in ReadOnly mode 2017-01-19 15:54:19 -08:00
compaction.cc Compaction::IsTrivialMove relaxing 2016-12-07 11:54:11 -08:00
compaction.h Compaction::IsTrivialMove relaxing 2016-12-07 11:54:11 -08:00
compaction_iteration_stats.h Support for range skips in compaction filter 2016-12-01 07:09:15 -08:00
compaction_iterator.cc Abort compactions more reliably when closing DB 2017-01-11 15:09:21 -08:00
compaction_iterator.h Abort compactions more reliably when closing DB 2017-01-11 15:09:21 -08:00
compaction_iterator_test.cc Windows thread 2017-02-06 14:54:18 -08:00
compaction_job.cc Remove disableDataSync option 2017-02-13 11:09:13 -08:00
compaction_job.h Abort compactions more reliably when closing DB 2017-01-11 15:09:21 -08:00
compaction_job_stats_test.cc
compaction_job_test.cc
compaction_picker.cc
compaction_picker.h Compaction::IsTrivialMove relaxing 2016-12-07 11:54:11 -08:00
compaction_picker_test.cc Compaction::IsTrivialMove relaxing 2016-12-07 11:54:11 -08:00
comparator_db_test.cc
convenience.cc
corruption_test.cc Change corruption_test to use 4 bits. 2017-01-27 11:24:16 -08:00
cuckoo_table_db_test.cc Enable allow_concurrent_memtable_write and enable_write_thread_adaptive_yield by default 2016-11-16 09:39:09 -08:00
db_block_cache_test.cc
db_bloom_filter_test.cc Enable allow_concurrent_memtable_write and enable_write_thread_adaptive_yield by default 2016-11-16 09:39:09 -08:00
db_compaction_filter_test.cc Support for range skips in compaction filter 2016-12-01 07:09:15 -08:00
db_compaction_test.cc Windows thread 2017-02-06 14:54:18 -08:00
db_dynamic_level_test.cc Windows thread 2017-02-06 14:54:18 -08:00
db_filesnapshot.cc Remove unnecessary header include 2016-12-09 11:54:21 -08:00
db_flush_test.cc Flush job should release reference current version if sync log failed 2017-01-19 23:09:15 -08:00
db_impl.cc Make DBImpl::has_unpersisted_data_ atomic 2017-02-13 18:54:13 -08:00
db_impl.h Make DBImpl::has_unpersisted_data_ atomic 2017-02-13 18:54:13 -08:00
db_impl_debug.cc Fix for 2PC causing WAL to grow too large 2017-01-19 15:39:12 -08:00
db_impl_experimental.cc
db_impl_readonly.cc Revert "PinnableSlice" 2017-01-08 14:24:12 -08:00
db_impl_readonly.h Disable IngestExternalFile in ReadOnly mode 2017-01-19 15:54:19 -08:00
db_info_dumper.cc
db_info_dumper.h
db_inplace_update_test.cc Enable allow_concurrent_memtable_write and enable_write_thread_adaptive_yield by default 2016-11-16 09:39:09 -08:00
db_io_failure_test.cc Add WriteOptions.no_slowdown 2016-11-21 18:09:13 -08:00
db_iter.cc Maintain position in range deletions map 2017-01-05 10:39:12 -08:00
db_iter.h
db_iter_test.cc Rename merger.h -> merging_iterator.h 2017-02-02 16:54:19 -08:00
db_iterator_test.cc Windows thread 2017-02-06 14:54:18 -08:00
db_log_iter_test.cc
db_memtable_test.cc Enable allow_concurrent_memtable_write and enable_write_thread_adaptive_yield by default 2016-11-16 09:39:09 -08:00
db_merge_operator_test.cc Iterator should be in corrupted status if merge operator return false 2016-12-16 11:09:16 -08:00
db_options_test.cc Made delete_obsolete_files_period_micros option dynamic 2016-12-05 14:24:16 -08:00
db_properties_test.cc Unified InlineSkipList::Insert algorithm with hinting 2016-11-22 14:09:13 -08:00
db_range_del_test.cc Fix DeleteRange including sentinels in output files 2017-01-25 11:09:12 -08:00
db_sst_test.cc fixed typo 2017-01-23 12:54:13 -08:00
db_table_properties_test.cc
db_tailing_iter_test.cc Enable allow_concurrent_memtable_write and enable_write_thread_adaptive_yield by default 2016-11-16 09:39:09 -08:00
db_test.cc Remove disableDataSync option 2017-02-13 11:09:13 -08:00
db_test2.cc Windows thread 2017-02-06 14:54:18 -08:00
db_test_util.cc Two-level Indexes 2017-02-06 16:39:12 -08:00
db_test_util.h Two-level Indexes 2017-02-06 16:39:12 -08:00
db_universal_compaction_test.cc
db_wal_test.cc Windows thread 2017-02-06 14:54:18 -08:00
dbformat.cc Support for range skips in compaction filter 2016-12-01 07:09:15 -08:00
dbformat.h Collapse range deletions 2016-12-19 16:54:12 -08:00
dbformat_test.cc
deletefile_test.cc
event_helpers.cc Performance: Iterate vector by reference 2017-01-11 10:54:37 -08:00
event_helpers.h
experimental.cc
external_sst_file_ingestion_job.cc Rename merger.h -> merging_iterator.h 2017-02-02 16:54:19 -08:00
external_sst_file_ingestion_job.h Add EventListener::OnExternalFileIngested() event 2016-12-06 14:09:17 -08:00
external_sst_file_test.cc Windows thread 2017-02-06 14:54:18 -08:00
fault_injection_test.cc Fix travis (compile for clang < 3.9) 2016-12-01 10:09:22 -08:00
file_indexer.cc gcc-7 requires include <functional> for std::function 2016-12-16 11:24:18 -08:00
file_indexer.h
file_indexer_test.cc
filename.cc Remove disableDataSync option 2017-02-13 11:09:13 -08:00
filename.h
filename_test.cc
flush_job.cc Remove disableDataSync option 2017-02-13 11:09:13 -08:00
flush_job.h Flush job should release reference current version if sync log failed 2017-01-19 23:09:15 -08:00
flush_job_test.cc
flush_scheduler.cc
flush_scheduler.h
forward_iterator.cc Rename merger.h -> merging_iterator.h 2017-02-02 16:54:19 -08:00
forward_iterator.h
forward_iterator_bench.cc Windows thread 2017-02-06 14:54:18 -08:00
inlineskiplist.h Unified InlineSkipList::Insert algorithm with hinting 2016-11-22 14:09:13 -08:00
inlineskiplist_test.cc Unified InlineSkipList::Insert algorithm with hinting 2016-11-22 14:09:13 -08:00
internal_stats.cc Print the missed last layer in cfstats 2017-02-08 10:39:15 -08:00
internal_stats.h Print the missed last layer in cfstats 2017-02-08 10:39:15 -08:00
job_context.h
listener_test.cc Gcc 7 error expansion to defined 2016-12-13 18:39:14 -08:00
log_format.h
log_reader.cc
log_reader.h
log_test.cc
log_writer.cc
log_writer.h
managed_iterator.cc Rename merger.h -> merging_iterator.h 2017-02-02 16:54:19 -08:00
managed_iterator.h
manual_compaction_test.cc
memtable.cc Adding GetApproximateMemTableStats method 2017-02-06 14:54:16 -08:00
memtable.h Adding GetApproximateMemTableStats method 2017-02-06 14:54:16 -08:00
memtable_allocator.cc
memtable_allocator.h
memtable_list.cc Adding GetApproximateMemTableStats method 2017-02-06 14:54:16 -08:00
memtable_list.h Adding GetApproximateMemTableStats method 2017-02-06 14:54:16 -08:00
memtable_list_test.cc
memtablerep_bench.cc Windows thread 2017-02-06 14:54:18 -08:00
merge_context.h
merge_helper.cc Abort compactions more reliably when closing DB 2017-01-11 15:09:21 -08:00
merge_helper.h Abort compactions more reliably when closing DB 2017-01-11 15:09:21 -08:00
merge_helper_test.cc
merge_operator.cc
merge_test.cc
options_file_test.cc
perf_context_test.cc Windows thread 2017-02-06 14:54:18 -08:00
pinned_iterators_manager.h Delegate Cleanables 2016-12-29 15:54:19 -08:00
plain_table_db_test.cc Allow plain table to store index on file with bloom filter disabled 2016-11-17 11:09:13 -08:00
prefix_test.cc Enable allow_concurrent_memtable_write and enable_write_thread_adaptive_yield by default 2016-11-16 09:39:09 -08:00
range_del_aggregator.cc Fix DeleteRange including sentinels in output files 2017-01-25 11:09:12 -08:00
range_del_aggregator.h Maintain position in range deletions map 2017-01-05 10:39:12 -08:00
range_del_aggregator_test.cc Maintain position in range deletions map 2017-01-05 10:39:12 -08:00
repair.cc Fix repair issues 2017-02-10 10:54:12 -08:00
repair_test.cc Fix repair issues 2017-02-10 10:54:12 -08:00
skiplist.h
skiplist_test.cc
snapshot_impl.cc
snapshot_impl.h
table_cache.cc Fix range deletion covering key in same SST file 2016-11-28 22:54:13 -08:00
table_cache.h Eliminate redundant cache lookup with range deletion 2016-11-21 21:24:11 -08:00
table_properties_collector.cc
table_properties_collector.h
table_properties_collector_test.cc
transaction_log_impl.cc
transaction_log_impl.h
version_builder.cc Windows thread 2017-02-06 14:54:18 -08:00
version_builder.h
version_builder_test.cc
version_edit.cc
version_edit.h
version_edit_test.cc
version_set.cc Remove disableDataSync option 2017-02-13 11:09:13 -08:00
version_set.h Flush job should release reference current version if sync log failed 2017-01-19 23:09:15 -08:00
version_set_test.cc
wal_manager.cc
wal_manager.h
wal_manager_test.cc
write_batch.cc
write_batch_base.cc
write_batch_internal.h
write_batch_test.cc Range deletion microoptimizations 2016-11-21 12:24:13 -08:00
write_callback.h
write_callback_test.cc Windows thread 2017-02-06 14:54:18 -08:00
write_controller.cc
write_controller.h Improve Write Stalling System 2016-11-23 09:24:15 -08:00
write_controller_test.cc Improve Write Stalling System 2016-11-23 09:24:15 -08:00
write_thread.cc Fix 2PC with concurrent memtable insert 2017-01-17 11:24:28 -08:00
write_thread.h Add WriteOptions.no_slowdown 2016-11-21 18:09:13 -08:00
xfunc_test_points.cc
xfunc_test_points.h