rocksdb

A library that provides an embeddable, persistent key-value store for fast storage.

GPL-2.0 License

Stars
28K
Committers
977
rocksdb - RocksDB 4.13.5

Published by IslamAbdelRahman almost 8 years ago

We have skipped releasing 4.12.x and went directly to 4.13.5

4.13.5

Public API Change

  • Fix a regression in compaction performance.
  • Disallow calling IngestExternalFile() on a dropped column family.
  • Add EventListener::OnExternalFileIngested() event that will be called for files that are successfully ingested.

4.13.4

Public API Change

  • Removed flashcache support.

4.13.0 (10/18/2016)

Public API Change

  • DB::GetOptions() reflect dynamic changed options (i.e. through DB::SetOptions()) and return copy of options instead of reference.
  • Added Statistics::getAndResetTickerCount().

New Features

  • Add DB::SetDBOptions() to dynamic change base_background_compactions and max_background_compactions.
  • Added Iterator::SeekForPrev(). This new API will seek to the last key that is less than or equal to the target key.

4.12.0 (9/12/2016)

Public API Change

  • CancelAllBackgroundWork() flushes all memtables for databases containing writes that have bypassed the WAL (writes issued with WriteOptions::disableWAL=true) before shutting down background threads.
  • Merge options source_compaction_factor, max_grandparent_overlap_bytes and expanded_compaction_factor into max_compaction_bytes.
  • Remove ImmutableCFOptions.
  • Add a compression type ZSTD, which can work with ZSTD 0.8.0 or up. Still keep ZSTDNotFinal for compatibility reasons.

New Features

  • Introduce NewClockCache, which is based on CLOCK algorithm with better concurrent performance in some cases. It can be used to replace the default LRU-based block cache and table cache. To use it, RocksDB need to be linked with TBB lib.
  • Change ticker/histogram statistics implementations to accumulate data in thread-local storage, which improves CPU performance by reducing cache coherency costs. Callers of CreateDBStatistics do not need to change anything to use this feature.
  • Block cache mid-point insertion, where index and filter block are inserted into LRU block cache with higher priority. The feature can be enabled by setting BlockBasedTableOptions::cache_index_and_filter_blocks_with_high_priority to true and high_pri_pool_ratio > 0 when creating NewLRUCache.
rocksdb - RocksDB 4.11.2

Published by siying about 8 years ago

We abandoned release candidates 4.10.x and directly go to 4.11.2 from 4.9, to make sure the latest release is stable. In 4.11.2, we fixed several data corruption related bugs in 4.9.0.

4.11.2 (9/15/2016)

Bug fixes

  • Segfault when failing to open an SST file for read-ahead iterators.
  • WAL without data for all CFs is not deleted after recovery.

4.11.1 (8/30/2016)

Bug Fixes

  • Mitigate the regression bug of deadlock condition during recovery when options.max_successive_merges hits.
  • Fix data race condition related to hash index in block based table when putting indexes in the block cache.

4.11.0 (8/1/2016)

Public API Change

  • options.memtable_prefix_bloom_huge_page_tlb_size => memtable_huge_page_size. When it is set, RocksDB will try to allocate memory from huge page for memtable too, rather than just memtable bloom filter.

New Features

  • A tool to migrate DB after options change. See include/rocksdb/utilities/option_change_migration.h.
  • Add ReadOptions.background_purge_on_iterator_cleanup. If true, we avoid file deletion when destorying iterators.

4.10.0 (7/5/2016)

Public API Change

  • options.memtable_prefix_bloom_bits changes to options.memtable_prefix_bloom_bits_ratio and deprecate options.memtable_prefix_bloom_probes
  • enum type CompressionType and PerfLevel changes from char to unsigned char. Value of all PerfLevel shift by one.
  • Deprecate options.filter_deletes.

New Features

  • Add avoid_flush_during_recovery option.
  • Add a read option background_purge_on_iterator_cleanup to avoid deleting files in foreground when destroying iterators. Instead, a job is scheduled in high priority queue and would be executed in a separate background thread.
  • RepairDB support for column families. RepairDB now associates data with non-default column families using information embedded in the SST/WAL files (4.7 or later). For data written by 4.6 or earlier, RepairDB associates it with the default column family.
  • Add options.write_buffer_manager which allows users to control total memtable sizes across multiple DB instances.
rocksdb - RocksDB 4.9

Published by lightmark about 8 years ago

Public API changes

  • Add bottommost_compression option, This option can be used to set a specific compression algorithm for the bottommost level (Last level containing files in the DB).
  • Introduce CompactionJobInfo::compression, This field state the compression algorithm used to generate the output files of the compaction.
  • Deprecate BlockBaseTableOptions.hash_index_allow_collision=false
  • Deprecate options builder (GetOptions()).

New Features

  • Introduce NewSimCache() in rocksdb/utilities/sim_cache.h. This function creates a block cache that is able to give simulation results (mainly hit rate) of simulating block behavior with a configurable cache size.
rocksdb -

Published by yiwu-arbug about 8 years ago

Public API Change

  • Allow preset compression dictionary for improved compression of block-based tables. This is supported for zlib, zstd, and lz4. The compression dictionary's size is configurable via CompressionOptions::max_dict_bytes.
  • Delete deprecated classes for creating backups (BackupableDB) and restoring from backups (RestoreBackupableDB). Now, BackupEngine should be used for creating backups, and BackupEngineReadOnly should be used for restorations. For more details, see https://github.com/facebook/rocksdb/wiki/How-to-backup-RocksDB%3F
  • Expose estimate of per-level compression ratio via DB property: "rocksdb.compression-ratio-at-levelN".
    Added EventListener::OnTableFileCreationStarted. EventListener::OnTableFileCreated will be called on failure case. User can check creation status via TableFileCreationInfo::status.

New Features

  • Add ReadOptions::readahead_size. If non-zero, NewIterator will create a new table reader which performs reads of the given size.
rocksdb - RocksDB 4.6.1

Published by ajkr over 8 years ago

Public API Changes

  • Change default of BlockBasedTableOptions.format_version to 2. It means default DB created by 4.6 or up cannot be opened by RocksDB version 3.9 or earlier.
  • Added strict_capacity_limit option to NewLRUCache. If the flag is set to true, insert to cache will fail if no enough capacity can be free. Signature of Cache::Insert() is updated accordingly.
  • Tickers [NUMBER_DB_NEXT, NUMBER_DB_PREV, NUMBER_DB_NEXT_FOUND, NUMBER_DB_PREV_FOUND, ITER_BYTES_READ] are not updated immediately. The are updated when the Iterator is deleted.
  • Add monotonically increasing counter (DB property "rocksdb.current-super-version-number") that increments upon any change to the LSM tree.

New Features

  • Add CompactionPri::kMinOverlappingRatio, a compaction picking mode friendly to write amplification.
  • Deprecate Iterator::IsKeyPinned() and replace it with Iterator::GetProperty() with prop_name="rocksdb.iterator.is.key.pinned"
rocksdb - RocksDB 4.5.1

Published by siying over 8 years ago

Public API Changes

  • Add a new perf context level between kEnableCount and kEnableTime. Level 2 now does not include timers for mutexes.
  • Statistics of mutex operation durations will not be measured by default. If you want to have them enabled, you need to set Statistics::stats_level_ to kAll.
  • DBOptions::delete_scheduler and NewDeleteScheduler() are removed, please use DBOptions::sst_file_manager and NewSstFileManager() instead

New Features

  • ldb tool now supports operations to non-default column families.
  • Add kPersistedTier to ReadTier. This option allows Get and MultiGet to read only the persited data and skip mem-tables if writes were done with disableWAL = true.
  • Add DBOptions::sst_file_manager. Use NewSstFileManager() in include/rocksdb/sst_file_manager.h to create a SstFileManager that can be used to track the total size of SST files and control the SST files deletion rate.
rocksdb - RocksDB 4.4.1

Published by yhchiang over 8 years ago

New Features

  • Dynamic slow-down on writes. When slow down on writes is triggered, RocksDB will dynamically optimize the slow-down per write based on the estimated pending compaction bytes. If the number of pending compaction bytes keeps increasing, then RocksDB will slow down on writes more to make compaction able to catch up to avoid write stall.
  • Introduce CompactionJobInfo::compaction_reason, this field include the reason to trigger the compaction.
  • Added a new parameter --path to ldb tool. --path accepts the name of either MANIFEST, SST or a WAL file. Either --db or --path can be used when calling ldb.

Public API Changes

  • Deprecate options.soft_rate_limit and add options.soft_pending_compaction_bytes_limit.
  • If options.max_write_buffer_number > 3, writes will be slowed down when writing to the last write buffer to delay a full stop.
  • Increase default options.delayed_write_rate to 2MB/s.
  • Change names in CompactionPri and add a new one.
rocksdb - RocksDB 4.3.1

Published by kradhakrishnan over 8 years ago

New Features

  • CompactionFilter has new member function called IgnoreSnapshots which allows CompactionFilter to be called even if there are snapshots later than the key.
  • RocksDB will now persist options under the same directory as the RocksDB database on successful DB::Open, CreateColumnFamily, DropColumnFamily, and SetOptions.
  • Introduce LoadLatestOptions() in rocksdb/utilities/options_util.h. This function can construct the latest DBOptions / ColumnFamilyOptions used by the specified RocksDB intance.
  • Introduce CheckOptionsCompatibility() in rocksdb/utilities/options_util.h. This function checks whether the input set of options is able to open the specified DB successfully.

Public API Changes

  • When options.db_write_buffer_size triggers, only the column family with the largest column family size will be flushed, not all the column families.
rocksdb - RocksDB 4.2

Published by siying over 8 years ago

New Features

  • Introduce CreateLoggerFromOptions(), this function create a Logger for provided DBOptions.
  • Add GetAggregatedIntProperty(), which returns the sum of the GetIntProperty of all the column families.
  • Add MemoryUtil in rocksdb/utilities/memory.h. It currently offers a way to get the memory usage by type from a list rocksdb instances.

Public API Changes

  • CompactionFilter::Context includes information of Column Family ID
  • The need-compaction hint given by TablePropertiesCollector::NeedCompact() will be persistent and recoverable after DB recovery. This introduces a breaking format change. If you use this experimental feature, including NewCompactOnDeletionCollectorFactory() in the new version, you may not be able to directly downgrade the DB back to version 4.0 or lower.
  • TablePropertiesCollectorFactory::CreateTablePropertiesCollector() now takes an option Context, containing the information of column family ID for the file being written.
  • Remove DefaultCompactionFilterFactory.
rocksdb - RocksDB 4.1

Published by yhchiang almost 9 years ago

New Features

  • Added single delete operation as a more efficient way to delete keys that have not been overwritten.
  • Added experimental AddFile() to DB interface that allow users to add files created by SstFileWriter into an empty Database, see include/rocksdb/sst_file_writer.h and DB::AddFile() for more info.
  • Added support for opening SST files with .ldb suffix which enables opening LevelDB databases.
  • CompactionFilter now supports filtering of merge operands and merge results.

Public API Changes

  • Added SingleDelete() to the DB interface.
  • Added AddFile() to DB interface.
  • Added SstFileWriter class.
  • CompactionFilter has a new method FilterMergeOperand() that RocksDB applies to every merge operand during compaction to decide whether to filter the operand.
  • We removed CompactionFilterV2 interfaces from include/rocksdb/compaction_filter.h. The functionality was deprecated already in version 3.13.
rocksdb - RocksDB 4.1

Published by yhchiang almost 9 years ago

New Features

  • Added single delete operation as a more efficient way to delete keys that have not been overwritten.
  • Added experimental AddFile() to DB interface that allow users to add files created by SstFileWriter into an empty Database, see include/rocksdb/sst_file_writer.h and DB::AddFile() for more info.
  • Added support for opening SST files with .ldb suffix which enables opening LevelDB databases.
  • CompactionFilter now supports filtering of merge operands and merge results.

Public API Changes

  • Added SingleDelete() to the DB interface.
  • Added AddFile() to DB interface.
  • Added SstFileWriter class.
  • CompactionFilter has a new method FilterMergeOperand() that RocksDB applies to every merge operand during compaction to decide whether to filter the operand.
  • We removed CompactionFilterV2 interfaces from include/rocksdb/compaction_filter.h. The functionality was deprecated already in version 3.13.
rocksdb - RocksDB 4.0

Published by IslamAbdelRahman about 9 years ago

New Features

  • Added support for transactions. See include/rocksdb/utilities/transaction.h for more info.
  • DB::GetProperty() now accepts "rocksdb.aggregated-table-properties" and "rocksdb.aggregated-table-properties-at-levelN", in which case it returns aggregated table properties of the target column family, or the aggregated table properties of the specified level N if the "at-level" version is used.
  • Add compression option kZSTDNotFinalCompression for people to experiment ZSTD although its format is not finalized.
  • We removed the need for LATEST_BACKUP file in BackupEngine. We still keep writing it when we create new backups (because of backward compatibility), but we don't read it anymore.

Public API Changes

  • Removed class Env::RandomRWFile and Env::NewRandomRWFile().
  • Renamed DBOptions.num_subcompactions to DBOptions.max_subcompactions to make the name better match the actual functionality of the option.
  • Added Equal() method to the Comparator interface that can optionally be overwritten in cases where equality comparisons can be done more efficiently than three-way comparisons.
  • Previous 'experimental' OptimisticTransaction class has been replaced by Transaction class.
rocksdb - RocksDB 3.13.1

Published by siying about 9 years ago

New Features

  • RollbackToSavePoint() in WriteBatch/WriteBatchWithIndex
  • Add NewCompactOnDeletionCollectorFactory() in utilities/table_properties_collectors, which allows rocksdb to mark a SST file as need-compaction when it observes at least D deletion entries in any N consecutive entries in that SST file. Note that this feature depends on an experimental NeedCompact() API --- the result of this API will not persist after DB restart.
  • Add DBOptions::delete_scheduler. Use NewDeleteScheduler() in include/rocksdb/delete_scheduler.h to create a DeleteScheduler that can be shared among multiple RocksDB instances to control the file deletion rate of SST files that exist in the first db_path.

Public API Changes

  • Deprecated WriteOptions::timeout_hint_us. We no longer support write timeout. If you really need this option, talk to us and we might consider returning it.
  • Deprecated purge_redundant_kvs_while_flush option.
  • Removed BackupEngine::NewBackupEngine() and NewReadOnlyBackupEngine() that were deprecated in RocksDB 3.8. Please use BackupEngine::Open() instead.
  • Deprecated Compaction Filter V2. We are not aware of any existing use-cases. If you use this filter, your compile will break with RocksDB 3.13. Please let us know if you use it and we'll put it back in RocksDB 3.14.
  • Env::FileExists now returns a Status instead of a boolean
  • Add statistics::getHistogramString() to print detailed distribution of a histogram metric.
  • Add DBOptions::skip_stats_update_on_db_open. When it is on, DB::Open() will run faster as it skips the random reads required for loading necessary stats from SST files to optimize compaction.
rocksdb - RocksDB 3.12.1

Published by agiardullo about 9 years ago

New Features

  • Added experimental support for optimistic transactions. See include/rocksdb/utilities/optimistic_transaction.h for more info.
  • Added a new way to report QPS from db_bench (check out --report_file and --report_interval_seconds)
  • Added a cache for individual rows. See DBOptions::row_cache for more info.
  • Several new features on EventListener (see include/rocksdb/listener.h):
    • OnCompationCompleted() now returns per-compaciton job statistics, defined in include/rocksdb/compaction_job_stats.h.
    • Added OnTableFileCreated() and OnTableFileDeleted().
  • Add compaction_options_universal.enable_trivial_move to true, to allow trivial move while performing universal compaction. Trivial move will happen only when all the input files are non overlapping.

Public API Changes

  • EventListener::OnFlushCompleted() now passes FlushJobInfo instead of a list of parameters.
  • DB::GetDbIdentity() is now a const function. If this function is overridden in your application, be sure to also make GetDbIdentity() const to avoid compile error.
  • Move listeners from ColumnFamilyOptions to DBOptions.
  • Add max_write_buffer_number_to_maintain option
  • DB::CompactRange()'s parameter reduce_level is changed to change_level, to allow users to move levels to lower levels if allowed. It can be used to migrate a DB from options.level_compaction_dynamic_level_bytes=false to options.level_compaction_dynamic_level_bytes.true.
  • Change default value for options.compaction_filter_factory and options.compaction_filter_factory_v2 to nullptr instead of DefaultCompactionFilterFactory and DefaultCompactionFilterFactoryV2.
  • If CancelAllBackgroundWork is called without doing a flush after doing loads with WAL disabled, the changes which haven't been flushed before the call to CancelAllBackgroundWork will be lost.
  • WBWIIterator::Entry() now returns WriteEntry instead of const WriteEntry&
  • options.hard_rate_limit is deprecated.
  • When options.soft_rate_limit or options.level0_slowdown_writes_trigger is triggered, the way to slow down writes is changed to: write rate to DB is limited to to options.delayed_write_rate.
  • DB::GetApproximateSizes() adds a parameter to allow the estimation to include data in mem table, with default to be not to include. It is now only supported in skip list mem table.
  • DB::CompactRange() now accept CompactRangeOptions instead of multiple paramters. CompactRangeOptions is defined in include/rocksdb/options.h.
  • CompactRange() will now skip bottommost level compaction for level based compaction if there is no compaction filter, bottommost_level_compaction is introduced in CompactRangeOptions to control when it's possbile to skip bottommost level compaction. This mean that if you want the compaction to produce a single file you need to set bottommost_level_compaction to BottommostLevelCompaction::kForce.
  • Add Cache.GetPinnedUsage() to get the size of memory occupied by entries that are in use by the system.
  • DB:Open() will fail if the compression specified in Options is not linked with the binary. If you see this failure, recompile RocksDB with compression libraries present on your system. Also, previously our default compression was snappy. This behavior is now changed. Now, the default compression is snappy only if it's available on the system. If it isn't we change the default to kNoCompression.
  • We changed how we account for memory used in block cache. Previously, we only counted the sum of block sizes currently present in block cache. Now, we count the actual memory usage of the blocks. For example, a block of size 4.5KB will use 8KB memory with jemalloc. This might decrease your memory usage and possibly decrease performance. Increase block cache size if you see this happening after an upgrade.
  • Add BackupEngineImpl.options_.max_background_operations to specify the maximum number of operations that may be performed in parallel. Add support for parallelized backup and restore.
rocksdb - RocksDB 3.11.2

Published by igorcanadi over 9 years ago

Fixes

  • Adjust the way we compensate for tombstones when choosing compactions. Previous heuristics led to pathological behavior in some cases.
  • Don't let two L0->L1 compactions run in parallel (only affected through experimental feature SuggestCompactRange)
rocksdb - RocksDB 3.11.1

Published by igorcanadi over 9 years ago

Just a single change to fix the Java linking (github issue #606)

rocksdb - RocksDB 3.11

Published by kradhakrishnan over 9 years ago

New Features

  • Added a new API Cache::SetCapacity(size_t capacity) to dynamically change the maximum configured capacity of the cache. If the new capacity is less than the existing cache usage, the implementation will try to lower the usage by evicting the necessary number of elements following a strict LRU policy.
  • Added an experimental API for handling flashcache devices (blacklists background threads from caching their reads) -- NewFlashcacheAwareEnv
  • If universal compaction is used and options.num_levels > 1, files are compacted in upper levels with smaller files based on options.target_file_size_base. The limitation of file size when using universal compaction is greatly mitigated by using more levels. You can set num_levels = 1 to make universal compaction behave as before. If you set num_levels > 1 and want to roll back to a previous version, you need to compact all files to a big file in level 0 (by setting target_file_size_base to be large and CompactRange(<cf_handle>, nullptr, nullptr, true, 0) and reopen the DB with the same version to rewrite the manifest, and then you can open it using previous releases.
  • More information about rocksdb background threads are available in Env::GetThreadList(), including the number of bytes read / written by a compaction job, mem-table size and current number of bytes written by a flush job and many more. Check include/rocksdb/thread_status.h for more detail.

Public API changes

  • TablePropertiesCollector::AddUserKey() is added to replace TablePropertiesCollector::Add(). AddUserKey() exposes key type, sequence number and file size up to now to users.
  • DBOptions::bytes_per_sync used to apply to both WAL and table files. As of 3.11 it applies only to table files. If you want to use this option to sync WAL in the background, please use wal_bytes_per_sync
rocksdb - RocksDB 3.10.2

Published by igorcanadi over 9 years ago

Bug fixes since 3.10.1:

  • Make sure RocksDB is compiled with fallocate support
  • Fix possible hang in DB::Write()
  • Fix a possibility of SIGSEGV in CompactRange()
rocksdb - RocksDB 3.10

Published by rven1 over 9 years ago

3.10.0 (4/3/2015)

New Features

  • GetThreadStatus() is now able to report detailed thread status, including:
    • Thread Operation including flush and compaction.
    • The stage of the current thread operation.
    • The elapsed time in micros since the current thread operation started.
      More information can be found in include/rocksdb/thread_status.h. In addition, when running db_bench with --thread_status_per_interval, db_bench will also report thread status periodically.
  • Changed the LRU caching algorithm so that referenced blocks (by iterators) are never evicted. This change made parameter removeScanCountLimit obsolete. Because of that NewLRUCache doesn't take three arguments anymore. table_cache_remove_scan_limit option is also removed
  • By default we now optimize the compilation for the compilation platform (using -march=native). If you want to build portable binary, use 'PORTABLE=1' before the make command.
  • We now allow level-compaction to place files in different paths by
    specifying them in db_paths along with the target_size.
    Lower numbered levels will be placed earlier in the db_paths and higher
    numbered levels will be placed later in the db_paths vector.
  • Potentially big performance improvements if you're using RocksDB with lots of column families (100-1000)
  • Added BlockBasedTableOptions.format_version option, which allows user to specify which version of block based table he wants. As a general guidline, newer versions have more features, but might not be readable by older versions of RocksDB.
  • Added new block based table format (version 2), which you can enable by setting BlockBasedTableOptions.format_version = 2. This format changes how we encode size information in compressed blocks and should help with memory allocations if you're using Zlib or BZip2 compressions.
  • MemEnv (env that stores data in memory) is now available in default library build. You can create it by calling NewMemEnv().
  • Add SliceTransform.SameResultWhenAppended() to help users determine it is safe to apply prefix bloom/hash.
  • Block based table now makes use of prefix bloom filter if it is a full fulter.
  • Block based table remembers whether a whole key or prefix based bloom filter is supported in SST files. Do a sanity check when reading the file with users' configuration.
  • Fixed a bug in ReadOnlyBackupEngine that deleted corrupted backups in some cases, even though the engine was ReadOnly
  • options.level_compaction_dynamic_level_bytes, an experimental feature to allow RocksDB to pick dynamic base of bytes for levels. With this feature turned on, we will automatically adjust max bytes for each level. The goal of this feature is to have lower bound on size amplification. For more details, see comments in options.h.
  • Added an abstract base class WriteBatchBase for write batches
  • Fixed a bug where we start deleting files of a dropped column families even if there are still live references to it

Public API changes

  • Deprecated skip_log_error_on_recovery and table_cache_remove_scan_count_limit options.
  • Logger method logv with log level parameter is now virtual

RocksJava

  • Added compression per level API.
  • MemEnv is now available in RocksJava via RocksMemEnv class.
  • lz4 compression is now included in rocksjava static library when running make rocksdbjavastatic.
  • Overflowing a size_t when setting rocksdb options now throws an IllegalArgumentException, which removes the necessity for a developer to catch these Exceptions explicitly.
rocksdb - RocksDB 3.9.1

Published by yhchiang almost 10 years ago

Public API changes

  • New API to create a checkpoint added. Given a directory name, creates a new
    database which is an image of the existing database.
    *New API LinkFile added to Env. If you implement your own Env class, an
    implementation of the API LinkFile will have to be provided.
  • MemTableRep takes MemTableAllocator instead of Arena

Improvements

  • RocksDBLite library now becomes smaller and will be compiled with -fno-exceptions flag.
Package Rankings
Top 1.19% on Repo1.maven.org
Top 4.85% on Spack.io
Top 3.59% on Proxy.golang.org
Top 37.05% on Pypi.org
Top 11.69% on Conda-forge.org
Badges
Extracted from project README
CircleCI Status