rocksdb/db
amayank 4c696ed001 Fix for the weird behaviour encountered by ldb Get where it could read only the second-latest value
Summary:
flush_on_destroy has a default value of false and the memtable is flushed
in the dbimpl-destructor only when that is set to true. Because we want the memtable to be flushed everytime that
the destructor is called(db is closed) and the cases where we work with the memtable only are very less
it is a good idea to give this a default value of true. Thus the put from ldb
wil have its data flushed to disk in the destructor and the next Get will be able to
read it when opened with OpenForReadOnly. The reason that ldb could read the latest value when
the db was opened in the normal Open mode is that the Get from normal Open first reads
the memtable and directly finds the latest value written there and the Get from OpenForReadOnly
doesn't have access to the memtable (which is correct because all its Put/Modify) are disabled

Test Plan: make all; ldb put and get and scans

Reviewers: dhruba, heyongqiang, sheki

Reviewed By: heyongqiang

CC: kosievdmerwe, zshao, dilipj, kailiu

Differential Revision: https://reviews.facebook.net/D8631
2013-02-15 16:56:06 -08:00
..
builder.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
builder.h A number of fixes: 2011-10-31 17:22:06 +00:00
c_test.c Fix poor error on num_levels mismatch and few other minor improvements 2013-01-25 15:37:26 -08:00
c.cc Fix poor error on num_levels mismatch and few other minor improvements 2013-01-25 15:37:26 -08:00
corruption_test.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
db_bench.cc Fix poor error on num_levels mismatch and few other minor improvements 2013-01-25 15:37:26 -08:00
db_filesnapshot.cc Fix all the lint errors. 2012-11-28 17:18:41 -08:00
db_impl_readonly.cc Fix for the weird behaviour encountered by ldb Get where it could read only the second-latest value 2013-02-15 16:56:06 -08:00
db_impl_readonly.h Add a readonly db 2012-11-07 14:19:48 -08:00
db_impl.cc Fix for the weird behaviour encountered by ldb Get where it could read only the second-latest value 2013-02-15 16:56:06 -08:00
db_impl.h Fix poor error on num_levels mismatch and few other minor improvements 2013-01-25 15:37:26 -08:00
db_iter.cc A number of fixes: 2011-10-31 17:22:06 +00:00
db_iter.h A number of fixes: 2011-10-31 17:22:06 +00:00
db_statistics.h Add counters to count gets and writes 2013-01-17 12:27:56 -08:00
db_stats_logger.cc remove boost 2012-09-16 19:33:43 -07:00
db_test.cc Fix poor error on num_levels mismatch and few other minor improvements 2013-01-25 15:37:26 -08:00
dbformat_test.cc Fix all warnings generated by -Wall option to the compiler. 2012-11-06 14:07:31 -08:00
dbformat.cc manifest_dump: Add --hex=1 option 2012-12-16 08:58:28 -08:00
dbformat.h manifest_dump: Add --hex=1 option 2012-12-16 08:58:28 -08:00
filename_test.cc Added meta-database support. 2012-12-17 11:26:59 -08:00
filename.cc Allow the logs to be purged by TTL. 2013-02-04 19:42:40 -08:00
filename.h Added meta-database support. 2012-12-17 11:26:59 -08:00
log_file.h GetUpdatesSince API to enable replication. 2012-12-07 11:42:13 -08:00
log_format.h A number of fixes: 2011-10-31 17:22:06 +00:00
log_reader.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
log_reader.h Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
log_test.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
log_writer.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
log_writer.h Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
memtable.cc Fixing and adding some comments 2013-01-03 17:13:56 -08:00
memtable.h Fixing and adding some comments 2013-01-03 17:13:56 -08:00
memtablelist.cc Fix all the lint errors. 2012-11-28 17:18:41 -08:00
memtablelist.h Fixing and adding some comments 2013-01-03 17:13:56 -08:00
repair.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
skiplist_test.cc Add optional clang compile mode 2013-01-15 18:48:37 -08:00
skiplist.h This is the mega-patch multi-threaded compaction 2012-10-19 14:00:53 -07:00
snapshot.h Various build cleanups/improvements 2013-01-14 18:40:22 -08:00
table_cache.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
table_cache.h Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
transaction_log_iterator_impl.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
transaction_log_iterator_impl.h Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
version_edit_test.cc Make some variables configurable for each db instance 2012-06-27 14:36:31 -07:00
version_edit.cc Fix poor error on num_levels mismatch and few other minor improvements 2013-01-25 15:37:26 -08:00
version_edit.h Fix poor error on num_levels mismatch and few other minor improvements 2013-01-25 15:37:26 -08:00
version_set_reduce_num_levels.cc disable size compaction in ldb reduce_levels and added compression and file size parameter to it 2012-11-09 10:14:47 -08:00
version_set_test.cc Fix all warnings generated by -Wall option to the compiler. 2012-11-06 14:07:31 -08:00
version_set.cc Fix a number of object lifetime/ownership issues 2013-01-23 16:54:11 -08:00
version_set.h Use fallocate to prevent excessive allocation of sst files and logs 2013-01-24 12:25:13 -08:00
write_batch_internal.h GetUpdatesSince API to enable replication. 2012-12-07 11:42:13 -08:00
write_batch_test.cc Fix all warnings generated by -Wall option to the compiler. 2012-11-06 14:07:31 -08:00
write_batch.cc added group commit; drastically speeds up mult-threaded synchronous write workloads 2012-03-08 16:23:21 -08:00